Class AbstractCompositeComponent
java.lang.Object
org.teamapps.ux.component.AbstractCompositeComponent
- All Implemented Interfaces:
ClientObject,Component
A base class that can be used by application developers in order to create their own components that consist of a composition of
other components.
Example: A VerticalLayout containing toolbar with three buttons and a table, interacting in a certain manner.
Using this superclass, the composite component is a Component but not a VerticalLayout (see example above).
In particular, this means that this component can be used in the same way as any other component, including being added as child to other components.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionCreates a ui reference to a client object.getId()abstract Componentbooleanbooleanvoidrender()voidsetAttribute(String selector, String attributeName, String value) voidsetCssStyle(String selector, String propertyName, String value) voidUsed internally for setting the component's container.voidsetVisible(boolean visible) voidtoggleCssClass(String selector, String className, boolean enabled) voidunrender()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.teamapps.ux.component.ClientObject
handleUiEvent, handleUiQueryMethods inherited from interface org.teamapps.ux.component.Component
setAriaLabel, setAttribute, setCssStyle, setHtmlTitle, setMargin, setMaxHeight, setMaxWidth, setMinHeight, setMinWidth, setShadow, toggleCssClass
-
Constructor Details
-
AbstractCompositeComponent
public AbstractCompositeComponent()
-
-
Method Details
-
getMainComponent
- Returns:
- the top-level component of this composite component
-
getId
- Specified by:
getIdin interfaceClientObject
-
render
public void render()- Specified by:
renderin interfaceClientObject
-
unrender
public void unrender()- Specified by:
unrenderin interfaceClientObject
-
isRendered
public boolean isRendered()- Specified by:
isRenderedin interfaceClientObject
-
createUiReference
Description copied from interface:ClientObjectCreates a ui reference to a client object. Ui references are just a simple way to reference objects on the client side.- Specified by:
createUiReferencein interfaceClientObject
-
setParent
-
getParent
-
isVisible
-
setVisible
public void setVisible(boolean visible) - Specified by:
setVisiblein interfaceComponent
-
toggleCssClass
- Specified by:
toggleCssClassin interfaceComponent
-
setCssStyle
- Specified by:
setCssStylein interfaceComponent
-
setAttribute
- Specified by:
setAttributein interfaceComponent
-