public class AbstractFrame extends java.lang.Object implements Frame, Frame.Wrapper, Component.Wrapper, Component.OrderedContainer
Frame.MessageMode, Frame.MessageType, Frame.NotificationType, Frame.Wrapper
ExpandingLayout.ExpandDirection
Component.ActionOwner, Component.ActionsHolder, Component.Alignment, Component.BelongToFrame, Component.Buffered, Component.ChildEditableController, Component.Collapsable, Component.Container, Component.ContextHelpIconClickEvent, Component.Disposable, Component.Editable, Component.EditableChangeEvent, Component.EditableChangeListener, Component.EditableChangeNotifier, Component.ExpandedStateChangeEvent, Component.ExpandedStateChangeListener, Component.Focusable, Component.HasBorder, Component.HasButtonsPanel, Component.HasCaption, Component.HasContextHelp, Component.HasFormatter, Component.HasIcon, Component.HasInputPrompt, Component.HasNamedComponents, Component.HasOptionsStyleProvider, Component.HasPresentations, Component.HasRowsCount, Component.HasSettings, Component.HasValue, Component.HasXmlDescriptor, Component.LayoutClickEvent, Component.LayoutClickListener, Component.LayoutClickNotifier, Component.Margin, Component.MouseEventDetails, Component.OptionsStyleProvider, Component.OrderedContainer, Component.OuterMargin, Component.SecuredActionsHolder, Component.ShortcutAction, Component.ShortcutNotifier, Component.ShortcutTriggeredEvent, Component.Spacing, Component.UiPermissionAware, Component.Validatable, Component.ValueChangeEvent, Component.ValueChangeListener
AUTO_SIZE, AUTO_SIZE_PX, UNITS_PERCENTAGE, UNITS_PIXELS
Constructor and Description |
---|
AbstractFrame() |
Modifier and Type | Method and Description |
---|---|
void |
add(Component component) |
void |
add(Component childComponent,
int index) |
void |
addAction(Action action)
Add an action to the component
|
void |
addAction(Action action,
int index)
Add an action to the component with index.
|
void |
addStyleName(java.lang.String styleName)
Adds one or more style names to this component.
|
void |
expand(Component component) |
void |
expand(Component component,
java.lang.String height,
java.lang.String width) |
Action |
getAction(java.lang.String id) |
java.util.Collection<Action> |
getActions() |
Component.Alignment |
getAlignment() |
java.lang.String |
getCaption() |
<T> T |
getCompanion() |
java.lang.Object |
getComponent() |
Component |
getComponent(int index)
Returns the component at the given position.
|
Component |
getComponent(java.lang.String id)
Get component belonging to the whole components tree below this container.
|
java.util.Collection<Component> |
getComponents()
Get all components belonging to the whole components tree below this container
|
java.lang.Object |
getComposition() |
FrameContext |
getContext() |
java.lang.String |
getDebugId() |
java.lang.String |
getDescription() |
DialogParams |
getDialogParams()
Deprecated.
Use
WindowManager.OpenType or Window.getDialogOptions() from screen controller |
DsContext |
getDsContext() |
ExpandingLayout.ExpandDirection |
getExpandDirection() |
Frame |
getFrame() |
float |
getHeight()
Get component height in
Component.getHeightUnits() |
int |
getHeightUnits()
Height units:
Component.UNITS_PIXELS , Component.UNITS_PERCENTAGE |
java.lang.String |
getIcon()
Get icon source: "font-icon:ADD", "icons/myicon.png", "theme://createIcon", etc.
|
java.lang.String |
getId()
Component ID as defined in
id attribute |
MarginInfo |
getMargin() |
java.lang.String |
getMessagesPack() |
Component |
getOwnComponent(java.lang.String id)
Get component directly owned by this container.
|
java.util.Collection<Component> |
getOwnComponents()
Get all components directly owned by this container
|
Component |
getParent() |
Component |
getRegisteredComponent(java.lang.String id)
INTERNAL.
|
boolean |
getSpacing() |
java.lang.String |
getStyleName()
Styles implementation is client-type-specific.
|
java.util.List<org.springframework.context.ApplicationListener> |
getUiEventListeners()
INTERNAL.
|
float |
getWidth()
Get component width in
Component.getWidthUnits() |
int |
getWidthUnits()
Width units:
Component.UNITS_PIXELS , Component.UNITS_PERCENTAGE |
Frame |
getWrappedFrame() |
int |
indexOf(Component component) |
void |
init(java.util.Map<java.lang.String,java.lang.Object> params)
Called by the framework after creation of all components and before showing the screen.
|
boolean |
isEnabled()
Are the component and its parent enabled?
|
boolean |
isEnabledItself()
Is the component enabled regardless of the parent?
|
boolean |
isExpanded(Component component) |
boolean |
isResponsive()
Is the component responsive?
|
boolean |
isValid()
Check validity by invoking validators on all components which support them.
|
boolean |
isVisible()
Are the component and its parent visible?
|
boolean |
isVisibleItself()
Is the component visible regardless of the parent?
|
AbstractEditor |
openEditor(Entity item,
WindowManager.OpenType openType)
Open an edit screen for entity instance.
|
AbstractEditor |
openEditor(Entity item,
WindowManager.OpenType openType,
java.util.Map<java.lang.String,java.lang.Object> params)
Open an edit screen for entity instance.
|
AbstractEditor |
openEditor(Entity item,
WindowManager.OpenType openType,
java.util.Map<java.lang.String,java.lang.Object> params,
Datasource parentDs)
Open an edit screen for entity instance.
|
AbstractEditor |
openEditor(java.lang.String windowAlias,
Entity item,
WindowManager.OpenType openType)
Open an edit screen.
|
AbstractEditor |
openEditor(java.lang.String windowAlias,
Entity item,
WindowManager.OpenType openType,
Datasource parentDs)
Open an edit screen.
|
AbstractEditor |
openEditor(java.lang.String windowAlias,
Entity item,
WindowManager.OpenType openType,
java.util.Map<java.lang.String,java.lang.Object> params)
Open an edit screen.
|
AbstractEditor |
openEditor(java.lang.String windowAlias,
Entity item,
WindowManager.OpenType openType,
java.util.Map<java.lang.String,java.lang.Object> params,
Datasource parentDs)
Open an edit screen.
|
AbstractFrame |
openFrame(Component parent,
java.lang.String windowAlias)
Load a frame registered in
screens.xml and optionally show it inside a parent component of this frame. |
AbstractFrame |
openFrame(Component parent,
java.lang.String windowAlias,
java.util.Map<java.lang.String,java.lang.Object> params)
Load a frame registered in
screens.xml and optionally show it inside a parent component of this frame. |
AbstractLookup |
openLookup(java.lang.Class<? extends Entity> entityClass,
Window.Lookup.Handler handler,
WindowManager.OpenType openType)
Open a lookup screen.
|
AbstractLookup |
openLookup(java.lang.Class<? extends Entity> entityClass,
Window.Lookup.Handler handler,
WindowManager.OpenType openType,
java.util.Map<java.lang.String,java.lang.Object> params)
Open a lookup screen.
|
AbstractLookup |
openLookup(java.lang.String windowAlias,
Window.Lookup.Handler handler,
WindowManager.OpenType openType)
Open a lookup screen.
|
AbstractLookup |
openLookup(java.lang.String windowAlias,
Window.Lookup.Handler handler,
WindowManager.OpenType openType,
java.util.Map<java.lang.String,java.lang.Object> params)
Open a lookup screen.
|
AbstractWindow |
openWindow(java.lang.String windowAlias,
WindowManager.OpenType openType)
Open a simple screen.
|
AbstractWindow |
openWindow(java.lang.String windowAlias,
WindowManager.OpenType openType,
java.util.Map<java.lang.String,java.lang.Object> params)
Open a simple screen.
|
void |
registerComponent(Component component)
INTERNAL.
|
void |
remove(Component component) |
void |
removeAction(Action action)
Remove the action from the component
|
void |
removeAction(java.lang.String id)
Remove the action by its ID.
|
void |
removeAll() |
void |
removeAllActions()
Remove all actions from the component
|
void |
removeStyleName(java.lang.String styleName)
Removes one or more style names from component.
|
void |
requestFocus()
Set focus to this component
|
void |
resetExpanded() |
void |
setAlignment(Component.Alignment alignment) |
void |
setCaption(java.lang.String caption) |
void |
setCompanion(java.lang.Object companion)
INTERNAL.
|
void |
setContext(FrameContext ctx)
INTERNAL.
|
void |
setDebugId(java.lang.String id)
INTERNAL.
|
void |
setDescription(java.lang.String description) |
void |
setDsContext(DsContext dsContext)
INTERNAL.
|
void |
setEnabled(boolean enabled)
Set component enabled state
|
void |
setFrame(Frame frame) |
void |
setHeight(java.lang.String height)
Set component height in
Component.getHeightUnits() |
void |
setIcon(java.lang.String icon)
Set an icon by its source: "font-icon:ADD", "icons/myicon.png", "theme://createIcon", etc.
|
void |
setIconFromSet(Icons.Icon icon)
Set an icon from an icon set.
|
void |
setId(java.lang.String id)
Set component ID
|
void |
setMargin(MarginInfo marginInfo) |
void |
setMessagesPack(java.lang.String name)
Set message pack for this frame.
|
void |
setParent(Component parent)
INTERNAL.
Component.Container.add(Component) is normally used for adding components
to a parent and the used method will call this method implicitly. |
void |
setResponsive(boolean responsive)
Set component to be responsive by width and height.
|
void |
setSpacing(boolean enabled) |
void |
setStyleName(java.lang.String styleName)
Sets one or more style names of the component, replacing any
previous styles.
|
void |
setUiEventListeners(java.util.List<org.springframework.context.ApplicationListener> uiEventListeners)
INTERNAL.
|
void |
setVisible(boolean visible)
Set component visibility
|
void |
setWidth(java.lang.String width)
Set component width in
Component.getWidthUnits() |
void |
setWrappedFrame(Frame frame)
INTERNAL.
|
void |
showMessageDialog(java.lang.String title,
java.lang.String message,
Frame.MessageType messageType)
Show message dialog with title and message.
|
void |
showNotification(java.lang.String caption)
Show notification with
Frame.NotificationType.HUMANIZED . |
void |
showNotification(java.lang.String caption,
Frame.NotificationType type)
Show notification.
|
void |
showNotification(java.lang.String caption,
java.lang.String description,
Frame.NotificationType type)
Show notification with caption and description.
|
void |
showOptionDialog(java.lang.String title,
java.lang.String message,
Frame.MessageType messageType,
Action[] actions)
Show options dialog with title and message.
|
void |
showOptionDialog(java.lang.String title,
java.lang.String message,
Frame.MessageType messageType,
java.util.List<Action> actions)
Show options dialog with title and message.
|
void |
showValidationErrors(ValidationErrors errors)
Show validation errors alert.
|
void |
showWebPage(java.lang.String url,
java.util.Map<java.lang.String,java.lang.Object> params)
Open a web page in browser.
|
void |
unregisterComponent(Component component)
INTERNAL.
|
<X> X |
unwrap(java.lang.Class<X> internalComponentClass)
Get client specific component instance.
|
<X> X |
unwrapComposition(java.lang.Class<X> internalCompositionClass)
Get the outmost external container of client specific component instance.
|
void |
validate()
Check validity by invoking validators on all components which support them.
|
boolean |
validate(java.util.List<Component.Validatable> fields)
Check validity by invoking validators on specified components which support them
and show validation result notification.
|
boolean |
validateAll()
Check validity by invoking validators on all components which support them
and show validation result notification.
|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getComponentNN
getComponentNN
setHeightAuto, setHeightFull, setSizeAuto, setSizeFull, setWidthAuto, setWidthFull
setMargin, setMargin
getActionNN
public void setWrappedFrame(Frame frame)
public Frame getWrappedFrame()
getWrappedFrame
in interface Frame.Wrapper
public void init(java.util.Map<java.lang.String,java.lang.Object> params)
params
- parameters passed from caller's code, usually from
openWindow(String, com.haulmont.cuba.gui.WindowManager.OpenType)
and similar methods, or set in
screens.xml
for this registered screenpublic java.lang.String getId()
Component
id
attributepublic void setId(java.lang.String id)
Component
public Component getParent()
public void setParent(Component parent)
Component
Component.Container.add(Component)
is normally used for adding components
to a parent and the used method will call this method implicitly.public java.lang.String getDebugId()
getDebugId
in interface Component
public void setDebugId(java.lang.String id)
Component
setDebugId
in interface Component
public boolean isEnabled()
Component
public void setEnabled(boolean enabled)
Component
setEnabled
in interface Component
public boolean isVisible()
Component
public void setVisible(boolean visible)
Component
setVisible
in interface Component
public boolean isVisibleItself()
Component
isVisibleItself
in interface Component
public boolean isEnabledItself()
Component
isEnabledItself
in interface Component
public void requestFocus()
Component
requestFocus
in interface Component
public float getHeight()
Component
Component.getHeightUnits()
public int getHeightUnits()
Component
Component.UNITS_PIXELS
, Component.UNITS_PERCENTAGE
getHeightUnits
in interface Component
public void setHeight(java.lang.String height)
Component
Component.getHeightUnits()
public float getWidth()
Component
Component.getWidthUnits()
public int getWidthUnits()
Component
Component.UNITS_PIXELS
, Component.UNITS_PERCENTAGE
getWidthUnits
in interface Component
public void setWidth(java.lang.String width)
Component
Component.getWidthUnits()
public Component.Alignment getAlignment()
getAlignment
in interface Component
public void setAlignment(Component.Alignment alignment)
setAlignment
in interface Component
public java.lang.String getCaption()
getCaption
in interface Component.HasCaption
public boolean isResponsive()
Component
isResponsive
in interface Component
public void setResponsive(boolean responsive)
Component
setResponsive
in interface Component
public void setCaption(java.lang.String caption)
setCaption
in interface Component.HasCaption
public java.lang.String getDescription()
getDescription
in interface Component.HasCaption
public void setDescription(java.lang.String description)
setDescription
in interface Component.HasCaption
public java.lang.String getIcon()
Component.HasIcon
getIcon
in interface Component.HasIcon
public void setIcon(java.lang.String icon)
Component.HasIcon
setIcon
in interface Component.HasIcon
public void setIconFromSet(Icons.Icon icon)
Component.HasIcon
setIconFromSet
in interface Component.HasIcon
public void add(Component component)
add
in interface Component.Container
public void remove(Component component)
remove
in interface Component.Container
public void removeAll()
removeAll
in interface Component.Container
public Component getOwnComponent(java.lang.String id)
Component.Container
getOwnComponent
in interface Component.Container
@Nullable public Component getComponent(java.lang.String id)
Component.Container
getComponent
in interface Component.Container
public java.util.Collection<Component> getOwnComponents()
Component.Container
getOwnComponents
in interface Component.Container
public java.util.Collection<Component> getComponents()
Component.Container
getComponents
in interface Component.Container
public java.lang.Object getComponent()
getComponent
in interface Component.Wrapper
public java.lang.Object getComposition()
getComposition
in interface Component.Wrapper
public void expand(Component component, java.lang.String height, java.lang.String width)
expand
in interface ExpandingLayout
public void expand(Component component)
expand
in interface ExpandingLayout
public void resetExpanded()
resetExpanded
in interface ExpandingLayout
public boolean isExpanded(Component component)
isExpanded
in interface ExpandingLayout
public ExpandingLayout.ExpandDirection getExpandDirection()
getExpandDirection
in interface ExpandingLayout
public FrameContext getContext()
getContext
in interface Frame
public void setContext(FrameContext ctx)
Frame
setContext
in interface Frame
public DsContext getDsContext()
getDsContext
in interface Frame
DsContext
of the current frame or windowpublic void setDsContext(DsContext dsContext)
Frame
setDsContext
in interface Frame
public java.lang.String getMessagesPack()
getMessagesPack
in interface Frame
public void setMessagesPack(java.lang.String name)
Frame
setMessagesPack
in interface Frame
name
- message pack namepublic void registerComponent(Component component)
Frame
registerComponent
in interface Frame
public void unregisterComponent(Component component)
Frame
unregisterComponent
in interface Frame
@Nullable public Component getRegisteredComponent(java.lang.String id)
Frame
getRegisteredComponent
in interface Frame
public boolean isValid()
Frame
public void validate() throws ValidationException
Frame
validate
in interface Frame
ValidationException
- if some components are currently in invalid statepublic boolean validate(java.util.List<Component.Validatable> fields)
Frame
public boolean validateAll()
Frame
validateAll
in interface Frame
public void showValidationErrors(ValidationErrors errors)
errors
- the list of validation errors. Caller fills it by errors found during the default validation.@Deprecated public DialogParams getDialogParams()
WindowManager.OpenType
or Window.getDialogOptions()
from screen controllergetDialogParams
in interface Frame
DialogParams
that will be used for opening next window in modal mode.
init()
method of a screen, which is being opened in WindowManager.OpenType#DIALOG
mode, affects the current
screen itself.public void add(Component childComponent, int index)
add
in interface Component.OrderedContainer
public int indexOf(Component component)
indexOf
in interface Component.OrderedContainer
@Nullable public Component getComponent(int index)
Component.OrderedContainer
getComponent
in interface Component.OrderedContainer
index
- component index@Nullable public <T> T getCompanion()
public void setCompanion(java.lang.Object companion)
@Nullable public java.util.List<org.springframework.context.ApplicationListener> getUiEventListeners()
public void setUiEventListeners(java.util.List<org.springframework.context.ApplicationListener> uiEventListeners)
public AbstractWindow openWindow(java.lang.String windowAlias, WindowManager.OpenType openType, java.util.Map<java.lang.String,java.lang.Object> params)
Frame
openWindow
in interface Frame
windowAlias
- screen ID as defined in screens.xml
openType
- how to open the screenparams
- parameters to pass to init()
method of the screen's controllerpublic AbstractWindow openWindow(java.lang.String windowAlias, WindowManager.OpenType openType)
Frame
openWindow
in interface Frame
windowAlias
- screen ID as defined in screens.xml
openType
- how to open the screenpublic AbstractEditor openEditor(Entity item, WindowManager.OpenType openType)
Frame
openEditor
in interface Frame
item
- entity to editopenType
- how to open the screenpublic AbstractEditor openEditor(Entity item, WindowManager.OpenType openType, java.util.Map<java.lang.String,java.lang.Object> params)
Frame
openEditor
in interface Frame
item
- entity to editopenType
- how to open the screenparams
- parameters to pass to init()
method of the screen's controllerpublic AbstractEditor openEditor(Entity item, WindowManager.OpenType openType, java.util.Map<java.lang.String,java.lang.Object> params, Datasource parentDs)
Frame
openEditor
in interface Frame
item
- entity to editopenType
- how to open the screenparams
- parameters to pass to init()
method of the screen's controllerparentDs
- if this parameter is not null, the editor will commit edited instance into this
datasource instead of directly to databasepublic AbstractEditor openEditor(java.lang.String windowAlias, Entity item, WindowManager.OpenType openType, java.util.Map<java.lang.String,java.lang.Object> params, Datasource parentDs)
Frame
openEditor
in interface Frame
windowAlias
- screen ID as defined in screens.xml
item
- entity to editopenType
- how to open the screenparams
- parameters to pass to init()
method of the screen's controllerparentDs
- if this parameter is not null, the editor will commit edited instance into this
datasource instead of directly to databasepublic AbstractEditor openEditor(java.lang.String windowAlias, Entity item, WindowManager.OpenType openType, java.util.Map<java.lang.String,java.lang.Object> params)
Frame
openEditor
in interface Frame
windowAlias
- screen ID as defined in screens.xml
item
- entity to editopenType
- how to open the screenparams
- parameters to pass to init()
method of the screen's controllerpublic AbstractEditor openEditor(java.lang.String windowAlias, Entity item, WindowManager.OpenType openType, Datasource parentDs)
Frame
openEditor
in interface Frame
windowAlias
- screen ID as defined in screens.xml
item
- entity to editopenType
- how to open the screenparentDs
- if this parameter is not null, the editor will commit edited instance into this
datasource instead of directly to databasepublic AbstractEditor openEditor(java.lang.String windowAlias, Entity item, WindowManager.OpenType openType)
Frame
openEditor
in interface Frame
windowAlias
- screen ID as defined in screens.xml
item
- entity to editopenType
- how to open the screenpublic AbstractLookup openLookup(java.lang.Class<? extends Entity> entityClass, Window.Lookup.Handler handler, WindowManager.OpenType openType)
Frame
openLookup
in interface Frame
entityClass
- required class of entityhandler
- is invoked when selection confirmed and the lookup screen closesopenType
- how to open the screenpublic AbstractLookup openLookup(java.lang.Class<? extends Entity> entityClass, Window.Lookup.Handler handler, WindowManager.OpenType openType, java.util.Map<java.lang.String,java.lang.Object> params)
Frame
openLookup
in interface Frame
entityClass
- required class of entityhandler
- is invoked when selection confirmed and the lookup screen closesopenType
- how to open the screenparams
- parameters to pass to init()
method of the screen's controllerpublic AbstractLookup openLookup(java.lang.String windowAlias, Window.Lookup.Handler handler, WindowManager.OpenType openType, java.util.Map<java.lang.String,java.lang.Object> params)
Frame
openLookup
in interface Frame
windowAlias
- screen ID as defined in screens.xml
handler
- is invoked when selection confirmed and the lookup screen closesopenType
- how to open the screenparams
- parameters to pass to init()
method of the screen's controllerpublic AbstractLookup openLookup(java.lang.String windowAlias, Window.Lookup.Handler handler, WindowManager.OpenType openType)
Frame
openLookup
in interface Frame
windowAlias
- screen ID as defined in screens.xml
handler
- is invoked when selection confirmed and the lookup screen closesopenType
- how to open the screenpublic AbstractFrame openFrame(@Nullable Component parent, java.lang.String windowAlias)
screens.xml
and optionally show it inside a parent component of this frame.public AbstractFrame openFrame(@Nullable Component parent, java.lang.String windowAlias, java.util.Map<java.lang.String,java.lang.Object> params)
screens.xml
and optionally show it inside a parent component of this frame.openFrame
in interface Frame
parent
- if specified, all parent's subcomponents will be removed and the frame will be addedwindowAlias
- frame ID as defined in screens.xml
params
- parameters to be passed into the frame's controller init
methodpublic void showMessageDialog(java.lang.String title, java.lang.String message, Frame.MessageType messageType)
Frame
\n
).showMessageDialog
in interface Frame
title
- dialog titlemessage
- textmessageType
- defines how to display the dialog.
Don't forget to escape data from the database in case of *_HTML
types!public void showOptionDialog(java.lang.String title, java.lang.String message, Frame.MessageType messageType, Action[] actions)
Frame
\n
).showOptionDialog
in interface Frame
title
- dialog titlemessage
- textmessageType
- defines how to display the dialog.
Don't forget to escape data from the database in case of *_HTML
types!actions
- array of actions that represent options. For standard options consider use of
DialogAction
instances.public void showOptionDialog(java.lang.String title, java.lang.String message, Frame.MessageType messageType, java.util.List<Action> actions)
Frame
\n
).showOptionDialog
in interface Frame
title
- dialog titlemessage
- textmessageType
- defines how to display the dialog.
Don't forget to escape data from the database in case of *_HTML
types!actions
- list of actions that represent options. For standard options consider use of
DialogAction
instances.public void showNotification(java.lang.String caption)
Frame
showNotification
in interface Frame
caption
- notification textpublic void showNotification(java.lang.String caption, Frame.NotificationType type)
Frame
\n
) for non HTML type.showNotification
in interface Frame
caption
- notification texttype
- defines how to display the notification.
Don't forget to escape data from the database in case of *_HTML
types!public void showNotification(java.lang.String caption, java.lang.String description, Frame.NotificationType type)
Frame
\n
) for non HTML type.showNotification
in interface Frame
caption
- notification textdescription
- notification descriptiontype
- defines how to display the notification.
Don't forget to escape data from the database in case of *_HTML
types!public void showWebPage(java.lang.String url, @Nullable java.util.Map<java.lang.String,java.lang.Object> params)
Frame
showWebPage
in interface Frame
url
- URL of the pageparams
- optional parameters.
target
- String value used as the target name in a
window.open call in the client. This means that special values such as
"_blank", "_self", "_top", "_parent" have special meaning. If not specified, "_blank" is used. width
- Integer value specifying the width of the browser window in pixelsheight
- Integer value specifying the height of the browser window in pixelsborder
- String value specifying the border style of the window of the browser window.
Possible values are "DEFAULT", "MINIMAL", "NONE".Desktop client doesn't support any parameters and just ignores them.
public Frame getFrame()
getFrame
in interface Component.BelongToFrame
public void setFrame(Frame frame)
setFrame
in interface Component.BelongToFrame
public java.lang.String getStyleName()
Component
getStyleName
in interface Component
public void setStyleName(java.lang.String styleName)
Component
setStyleName
in interface Component
styleName
- one or more style names separated by space.public void addStyleName(java.lang.String styleName)
Component
addStyleName
in interface Component
styleName
- one or more style names separated by space.public void removeStyleName(java.lang.String styleName)
Component
removeStyleName
in interface Component
styleName
- one or more style names separated by space.public <X> X unwrap(java.lang.Class<X> internalComponentClass)
Component
com.vaadin.ui.TextField vTextField = textField.unwrap(com.vaadin.ui.TextField.class);
public <X> X unwrapComposition(java.lang.Class<X> internalCompositionClass)
Component
com.vaadin.ui.Layout vLayout = table.unwrapComposition(com.vaadin.ui.Layout.class);
unwrapComposition
in interface Component
X
- type of internal classinternalCompositionClass
- class of underlying composition implementation based on Vaadin or Swingpublic void setSpacing(boolean enabled)
setSpacing
in interface Component.Spacing
public boolean getSpacing()
getSpacing
in interface Component.Spacing
public void setMargin(MarginInfo marginInfo)
setMargin
in interface Component.Margin
public MarginInfo getMargin()
getMargin
in interface Component.Margin
public void addAction(Action action)
Component.ActionsHolder
addAction
in interface Component.ActionsHolder
public void addAction(Action action, int index)
Component.ActionsHolder
addAction
in interface Component.ActionsHolder
public void removeAction(@Nullable Action action)
Component.ActionsHolder
removeAction
in interface Component.ActionsHolder
public void removeAction(@Nullable java.lang.String id)
Component.ActionsHolder
removeAction
in interface Component.ActionsHolder
public void removeAllActions()
Component.ActionsHolder
removeAllActions
in interface Component.ActionsHolder
public java.util.Collection<Action> getActions()
getActions
in interface Component.ActionsHolder
@Nullable public Action getAction(java.lang.String id)
getAction
in interface Component.ActionsHolder