public class AbstractOrderedLayout<T extends com.vaadin.ui.CssLayout> extends AbstractComponent<T> implements OrderedContainer, Component.BelongToFrame, Component.HasCaption, Component.HasIcon, LayoutClickNotifier, ShortcutNotifier
Component.Alignment, Component.BelongToFrame, Component.Disposable, Component.Editable, Component.Focusable, Component.HasCaption, Component.HasDescription, Component.HasIcon, Component.HasXmlDescriptor, Component.Wrapper
LayoutClickNotifier.LayoutClickEvent
HasContextHelp.ContextHelpIconClickEvent
Modifier and Type | Field and Description |
---|---|
protected com.vaadin.shared.Registration |
layoutClickRegistration |
protected java.util.List<Component> |
ownComponents |
protected java.util.Map<ShortcutAction,com.vaadin.event.ShortcutListener> |
shortcuts |
alignment, applicationContext, component, contextHelpIconClickHandler, contextHelpIconClickListener, descriptionAsHtml, element, frame, htmlSanitizerEnabled, icon, ICON_STYLE, id, parent
AUTO_SIZE, AUTO_SIZE_PX, FULL_SIZE
Constructor and Description |
---|
AbstractOrderedLayout() |
Modifier and Type | Method and Description |
---|---|
void |
add(Component childComponent)
Adds a component to this container.
|
void |
add(Component childComponent,
int index) |
io.jmix.core.common.event.Subscription |
addLayoutClickListener(java.util.function.Consumer<LayoutClickNotifier.LayoutClickEvent> listener)
Adds a listener that is fired when user clicks inside the layout at any place.
|
void |
addShortcutAction(ShortcutAction action) |
void |
attached()
Notifies all listeners that component has been attached.
|
void |
detached()
Notifies all listeners that component has been detached.
|
protected Component |
findChildComponent(ComponentContainer layout,
com.vaadin.ui.Component clickedComponent) |
Component |
getComponent(int index)
Returns the component at the given position.
|
Component |
getComponent(java.lang.String id)
Gets a component belonging to the whole components tree below this container.
|
java.util.Collection<Component> |
getComponents()
Gets all components belonging to the whole components tree below this container.
|
java.lang.String |
getDescription() |
Component |
getOwnComponent(java.lang.String id)
Gets component directly owned by this container.
|
java.util.Collection<Component> |
getOwnComponents()
Gets all components directly owned by this container.
|
java.util.stream.Stream<Component> |
getOwnComponentsStream()
Gets stream of all components directly owned by this container.
|
int |
indexOf(Component component) |
protected void |
internalRemoveLayoutClickListener(java.util.function.Consumer<LayoutClickNotifier.LayoutClickEvent> listener) |
void |
remove(Component childComponent)
Removes a component from this container.
|
void |
removeAll()
Removes all components from this container.
|
void |
removeShortcutAction(ShortcutAction action) |
void |
setDescription(java.lang.String description)
Sets the component's description.
|
void |
setFrame(Frame frame) |
addAttachListener, addDetachListener, addStyleName, assignDebugId, getAlignment, getCaption, getComponent, getComposition, getContextHelpIconClickHandler, getContextHelpText, getDebugId, getEventHub, getFrame, getHeight, getHeightSizeUnit, getHtmlSanitizer, getIcon, getIconName, getIconResource, getId, getParent, getStyleName, getUiComponentProperties, getUiProperties, getWidth, getWidthSizeUnit, getXmlDescriptor, hasSubscriptions, hasValidationError, isAttached, isCaptionAsHtml, isContextHelpTextHtmlEnabled, isDescriptionAsHtml, isEnabled, isEnabledRecursive, isHtmlSanitizerEnabled, isResponsive, isVisible, isVisibleRecursive, onContextHelpIconClick, publish, removeStyleName, sanitize, setAlignment, setApplicationContext, setCaption, setCaptionAsHtml, setContextHelpIconClickHandler, setContextHelpText, setContextHelpTextHtmlEnabled, setDebugId, setDescriptionAsHtml, setEnabled, setHeight, setHtmlSanitizerEnabled, setIcon, setIconFromSet, setId, setParent, setResponsive, setStyleName, setValidationError, setVisible, setWidth, setXmlDescriptor, unsubscribe, unwrap, unwrapComposition, unwrapCompositionOrNull, unwrapOrNull, withUnwrapped, withUnwrappedComposition
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getComponentNN
add, remove
addStyleName, getAlignment, getHeight, getHeightSizeUnit, getId, getParent, getStyleName, getWidth, getWidthSizeUnit, isEnabled, isEnabledRecursive, isResponsive, isVisible, isVisibleRecursive, removeStyleName, setAlignment, setEnabled, setHeight, setHeightAuto, setHeightFull, setId, setParent, setResponsive, setSizeAuto, setSizeFull, setStyleName, setVisible, setWidth, setWidthAuto, setWidthFull, unwrap, unwrapComposition, unwrapCompositionOrNull, unwrapOrNull, withUnwrapped, withUnwrappedComposition
focusFirstComponent, getComponentNN
getFrame
getCaption, setCaption
getIcon, setIcon, setIconFromSet
protected java.util.List<Component> ownComponents
protected com.vaadin.shared.Registration layoutClickRegistration
protected java.util.Map<ShortcutAction,com.vaadin.event.ShortcutListener> shortcuts
public void add(Component childComponent)
ComponentContainer
add
in interface ComponentContainer
childComponent
- a component to addpublic void add(Component childComponent, int index)
add
in interface OrderedContainer
public int indexOf(Component component)
indexOf
in interface OrderedContainer
@Nullable public Component getComponent(int index)
OrderedContainer
getComponent
in interface OrderedContainer
index
- component indexpublic void remove(Component childComponent)
ComponentContainer
remove
in interface ComponentContainer
childComponent
- a component to removepublic void removeAll()
ComponentContainer
removeAll
in interface ComponentContainer
public void setFrame(@Nullable Frame frame)
setFrame
in interface Component.BelongToFrame
setFrame
in class AbstractComponent<T extends com.vaadin.ui.CssLayout>
@Nullable public Component getOwnComponent(java.lang.String id)
HasComponents
getOwnComponent
in interface HasComponents
@Nullable public Component getComponent(java.lang.String id)
HasComponents
getComponent
in interface HasComponents
public java.util.Collection<Component> getOwnComponents()
HasComponents
getOwnComponents
in interface HasComponents
public java.util.stream.Stream<Component> getOwnComponentsStream()
HasComponents
getOwnComponentsStream
in interface HasComponents
public java.util.Collection<Component> getComponents()
HasComponents
getComponents
in interface HasComponents
@Nullable public java.lang.String getDescription()
getDescription
in interface Component.HasDescription
getDescription
in class AbstractComponent<T extends com.vaadin.ui.CssLayout>
public void setDescription(@Nullable java.lang.String description)
Component.HasDescription
setDescription
in interface Component.HasDescription
setDescription
in class AbstractComponent<T extends com.vaadin.ui.CssLayout>
description
- the new description to setpublic io.jmix.core.common.event.Subscription addLayoutClickListener(java.util.function.Consumer<LayoutClickNotifier.LayoutClickEvent> listener)
LayoutClickNotifier
addLayoutClickListener
in interface LayoutClickNotifier
listener
- a listener to add@Nullable protected Component findChildComponent(ComponentContainer layout, com.vaadin.ui.Component clickedComponent)
protected void internalRemoveLayoutClickListener(java.util.function.Consumer<LayoutClickNotifier.LayoutClickEvent> listener)
public void addShortcutAction(ShortcutAction action)
addShortcutAction
in interface ShortcutNotifier
public void removeShortcutAction(ShortcutAction action)
removeShortcutAction
in interface ShortcutNotifier
public void attached()
AttachNotifier
attached
in interface AttachNotifier
attached
in class AbstractComponent<T extends com.vaadin.ui.CssLayout>
public void detached()
AttachNotifier
detached
in interface AttachNotifier
detached
in class AbstractComponent<T extends com.vaadin.ui.CssLayout>