M
- a model class that will be used for template data propagationpublic abstract class AbstractTemplate<M extends TemplateModel> extends Component
Modifier | Constructor and Description |
---|---|
protected |
AbstractTemplate() |
protected |
AbstractTemplate(StateNode stateNode) |
Modifier and Type | Method and Description |
---|---|
protected M |
getModel()
Returns the model of this template.
|
protected Class<? extends M> |
getModelType()
Gets the type of the template model to use with with this template.
|
ModelType |
getModelType(Type type)
Get the
ModelType for given class. |
protected StateNode |
getStateNode()
Gets the state node for current template.
|
protected void |
initModel(Set<String> twoWayBindingPaths) |
boolean |
isSupportedClass(Class<?> type)
Check if the given Class
type is found in the Model. |
addListener, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getLocale, getParent, getTranslation, getTranslation, getUI, hasListener, isTemplateMapped, isVisible, onAttach, onDetach, onEnabledStateChanged, set, setElement, setId, setVisible
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addAttachListener
addDetachListener
protected AbstractTemplate()
protected AbstractTemplate(StateNode stateNode)
protected M getModel()
The type of the model will be the type that this method returns in the instance it is invoked on - meaning that you should override this method and return your own model type.
protected Class<? extends M> getModelType()
null
protected StateNode getStateNode()
public boolean isSupportedClass(Class<?> type)
type
is found in the Model.type
- Class to check support forpublic ModelType getModelType(Type type)
ModelType
for given class.type
- Type to get the ModelType forCopyright © 2020. All rights reserved.