Class Group
- java.lang.Object
-
- org.ametys.core.ui.ribbonconfiguration.Group
-
-
Field Summary
Fields Modifier and Type Field Description protected String
_controlsOrder
When overriding, defines the controls position in the original groupprotected String
_dialogBoxLauncher
The control to call when dialog box launcher is clicked (we exactly call the method in the param 'dialog-box-launcher')protected org.slf4j.Logger
_groupLogger
The loggerprotected String
_icon
The icon of the group (in collapsed state)protected String
_iconGlyph
The icon glyph of the group (in collapsed state)protected I18nizableText
_label
The label of the groupprotected RibbonElementsInjectionHelper<Element>
_largeOverrideHelper
Helper for controls injectionprotected GroupSize
_largeSize
The large version of the groupprotected RibbonElementsInjectionHelper<Element>
_mediumOverrideHelper
Helper for controls injectionprotected GroupSize
_mediumSize
The medium version of the groupprotected String
_order
When overriding, defines the group position inside the tabprotected Boolean
_override
True to override an existing group instead of defining a new oneprotected int
_priority
The priority of the group (for resize purposes)protected RibbonElementsInjectionHelper<Element>
_smallOverrideHelper
Helper for controls injectionprotected GroupSize
_smallSize
The short version of the group
-
Constructor Summary
Constructors Constructor Description Group(Group ribbonGroup)
Create an empty group by copying another group's parametersGroup(Configuration groupConfiguration, RibbonManager ribbonManager, org.slf4j.Logger logger)
Creates a groupGroup(org.slf4j.Logger logger)
Creates an empty group
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
_configureLabelAndIcon(Configuration groupConfiguration)
Configure one group labelprotected void
_configureSize(Configuration groupConfiguration, RibbonManager ribbonManager)
Configure the different size of the groupGroupSize
getLargeGroupSize()
Retrieve the large group size from this groupGroupSize
getMediumGroupSize()
Retrieve the medium group size from this groupString
getOrder()
Return the order of the groupGroupSize
getSmallGroupSize()
Retrieve the small group size from this groupvoid
injectGroup(Group group)
Inject a group's controls into this groupboolean
isEmpty()
Return true if the group does not have any controlsboolean
isOverride()
Return true if the group overrides another groupvoid
toSAX(ContentHandler handler)
Sax the the configuration of the group.String
toString()
-
-
-
Field Detail
-
_label
protected I18nizableText _label
The label of the group
-
_iconGlyph
protected String _iconGlyph
The icon glyph of the group (in collapsed state)
-
_priority
protected int _priority
The priority of the group (for resize purposes)
-
_dialogBoxLauncher
protected String _dialogBoxLauncher
The control to call when dialog box launcher is clicked (we exactly call the method in the param 'dialog-box-launcher')
-
_largeSize
protected GroupSize _largeSize
The large version of the group
-
_mediumSize
protected GroupSize _mediumSize
The medium version of the group
-
_smallSize
protected GroupSize _smallSize
The short version of the group
-
_override
protected Boolean _override
True to override an existing group instead of defining a new one
-
_controlsOrder
protected String _controlsOrder
When overriding, defines the controls position in the original group
-
_largeOverrideHelper
protected RibbonElementsInjectionHelper<Element> _largeOverrideHelper
Helper for controls injection
-
_mediumOverrideHelper
protected RibbonElementsInjectionHelper<Element> _mediumOverrideHelper
Helper for controls injection
-
_smallOverrideHelper
protected RibbonElementsInjectionHelper<Element> _smallOverrideHelper
Helper for controls injection
-
_groupLogger
protected org.slf4j.Logger _groupLogger
The logger
-
-
Constructor Detail
-
Group
public Group(Configuration groupConfiguration, RibbonManager ribbonManager, org.slf4j.Logger logger) throws ConfigurationException
Creates a group- Parameters:
groupConfiguration
- The configuration of the groupribbonManager
- The ribbon managerlogger
- The logger- Throws:
ConfigurationException
- if an error occurs in the configuration
-
Group
public Group(org.slf4j.Logger logger)
Creates an empty group- Parameters:
logger
- The logger
-
-
Method Detail
-
_configureLabelAndIcon
protected void _configureLabelAndIcon(Configuration groupConfiguration) throws ConfigurationException
Configure one group label- Parameters:
groupConfiguration
- One group configuration- Throws:
ConfigurationException
- if an error occurred
-
_configureSize
protected void _configureSize(Configuration groupConfiguration, RibbonManager ribbonManager) throws ConfigurationException
Configure the different size of the group- Parameters:
groupConfiguration
- One group configurationribbonManager
- The ribbon manager- Throws:
ConfigurationException
- if an error occurred
-
isEmpty
public boolean isEmpty()
Return true if the group does not have any controls- Returns:
- True if empty
-
getLargeGroupSize
public GroupSize getLargeGroupSize()
Retrieve the large group size from this group- Returns:
- The large group size. Can be null
-
getMediumGroupSize
public GroupSize getMediumGroupSize()
Retrieve the medium group size from this group- Returns:
- The medium group size. Can be null
-
getSmallGroupSize
public GroupSize getSmallGroupSize()
Retrieve the small group size from this group- Returns:
- The small group size. Can be null
-
isOverride
public boolean isOverride()
Return true if the group overrides another group- Returns:
- True if overrides
-
injectGroup
public void injectGroup(Group group)
Inject a group's controls into this group- Parameters:
group
- The group to inject
-
toSAX
public void toSAX(ContentHandler handler) throws SAXException
Sax the the configuration of the group.- Parameters:
handler
- The content handler where to sax- Throws:
SAXException
- if an error occurs
-
-