#set( $symbol_pound = '#' )
#set( $symbol_dollar = '$' )
#set( $symbol_escape = '\' )
package ${package};
import com.vaadin.annotations.AutoGenerated;
import com.vaadin.ui.AbsoluteLayout;
import com.vaadin.ui.CustomComponent;
/**
*
* This class is responsible for widget's layout and is automatically updated by
* Vaadin Visual Designer. It is intended to be used as anonymous class in main
* logic class of the widget - this allows to separate logic from ${artifactId}'s
* layout.
*
* Do not add any not-gui-related logic here.
*
*/
public abstract class SampleWidgetComponent extends CustomComponent {
@AutoGenerated
private AbsoluteLayout mainLayout;
/**
* The constructor should first build the main layout, set the composition
* root and then do any custom initialization.
*
* The constructor will not be automatically regenerated by the visual
* editor.
*/
public SampleWidgetComponent() {
buildMainLayout();
setCompositionRoot(mainLayout);
loadData();
}
@AutoGenerated
private void buildMainLayout() {
// the main layout and components will be created here
mainLayout = new AbsoluteLayout();
}
/**
* Method called in constructor after layout is created. Implementation
* should configure and describe behavior of ${artifactId}'s components .
*
* Please note: in order to access class fields from anonymous implementation, you have to add
* getters or set those fields modifier as 'protected'.
*/
protected abstract void loadData();
}