I have a class which is having static methods, So i am calling the static methods without creating object reference for it. like below:
public Class DateChooser extends VLayout implements com.smartgwt.client.widgets.events.HasDataChangedHandlers {
public static native void changeAutoChildDefaults(String autoChildName, Canvas defaults) /*-{
$wnd.isc.DateChooser.changeDefaults(autoChildName + "Defaults", defaults.@com.smartgwt.client.widgets.Canvas::getConfig()());
}-*/;
}
public class Myclass{
DateItem dateField;// Smart Gwt class
dateField = new DateItem("counterDateItem","");
DateChooser dateChooser = new DateChooser(); // Smart Gwt class
dateChooser.changeAutoChildDefaults("hideBtn", canvas); // calling static method
dateField.setDateChooser(dateChooser);
}
how can i eliminate creating the object for calling static methods in above case.