Package org.ametys.runtime.model
Class AbstractViewItemGroup
java.lang.Object
org.ametys.runtime.model.AbstractViewItemGroup
- All Implemented Interfaces:
ViewItem
,ViewItemAccessor
,ViewItemContainer
,ViewItemGroup
,Labelable
,ModifiableLabelable
- Direct Known Subclasses:
ModelViewItemGroup
,SimpleViewItemGroup
Abstract class for group of view items
-
Field Summary
Modifier and TypeFieldDescriptionThe view item group's childrenprotected I18nizableText
The description of the view item groupprotected I18nizableText
The label of the view item groupprotected String
The role of the view item groupFields inherited from interface org.ametys.runtime.model.ViewItemGroup
FIELDSET_ROLE, TAB_ROLE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addViewItem
(ViewItem item) Add a view item in the accessorvoid
clear()
Removes all items of this accessorvoid
Copy the current view item in the given one.boolean
boolean
Indicates whether some other object is "equal to" this one.Retrieves the description.getLabel()
Retrieves the label.getRole()
Retrieves the role.Retrieves all the view items of this accessorint
hashCode()
void
insertViewItem
(ViewItem item, int index) Insert a view item in the accessor at the given indexboolean
removeViewItem
(ViewItem item) Removes the given items of this accessorvoid
setDescription
(I18nizableText description) Set the description.void
setLabel
(I18nizableText label) Set the label.void
Set the role.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.ametys.runtime.util.ModifiableLabelable
setName
Methods inherited from interface org.ametys.runtime.model.ViewItem
createInstance, getParent, setParent, toJSON, toSAX
Methods inherited from interface org.ametys.runtime.model.ViewItemAccessor
addViewItems, getModelViewItem, getViewItem, hasModelViewItem, hasModelViewItem, hasModelViewItem
Methods inherited from interface org.ametys.runtime.model.ViewItemGroup
copyTo
-
Field Details
-
_role
The role of the view item group -
_label
The label of the view item group -
_description
The description of the view item group -
_children
The view item group's children
-
-
Constructor Details
-
AbstractViewItemGroup
public AbstractViewItemGroup()
-
-
Method Details
-
getLabel
Description copied from interface:Labelable
Retrieves the label. -
setLabel
Description copied from interface:ModifiableLabelable
Set the label.- Specified by:
setLabel
in interfaceModifiableLabelable
- Parameters:
label
- the label.
-
getDescription
Description copied from interface:Labelable
Retrieves the description.- Specified by:
getDescription
in interfaceLabelable
- Returns:
- the description.
-
setDescription
Description copied from interface:ModifiableLabelable
Set the description.- Specified by:
setDescription
in interfaceModifiableLabelable
- Parameters:
description
- the description.
-
getRole
Description copied from interface:ViewItemGroup
Retrieves the role.- Specified by:
getRole
in interfaceViewItemGroup
- Returns:
- the role.
-
setRole
Description copied from interface:ViewItemGroup
Set the role.- Specified by:
setRole
in interfaceViewItemGroup
- Parameters:
role
- the role.
-
getViewItems
Description copied from interface:ViewItemAccessor
Retrieves all the view items of this accessor- Specified by:
getViewItems
in interfaceViewItemAccessor
- Returns:
- the view items
-
addViewItem
Description copied from interface:ViewItemAccessor
Add a view item in the accessor- Specified by:
addViewItem
in interfaceViewItemAccessor
- Parameters:
item
- the item to add
-
insertViewItem
Description copied from interface:ViewItemAccessor
Insert a view item in the accessor at the given index- Specified by:
insertViewItem
in interfaceViewItemAccessor
- Parameters:
item
- the item to insertindex
- index at which the item has to be inserted
-
removeViewItem
Description copied from interface:ViewItemAccessor
Removes the given items of this accessor- Specified by:
removeViewItem
in interfaceViewItemAccessor
- Parameters:
item
- the item to remove- Returns:
true
if this accessor contained the given item,false
otherwise
-
clear
Description copied from interface:ViewItemAccessor
Removes all items of this accessor- Specified by:
clear
in interfaceViewItemAccessor
-
copyTo
Description copied from interface:ViewItem
Copy the current view item in the given one. If the view item is an accessor, its view items are not copied -
hashCode
-
equals
-
equals
Description copied from interface:ViewItem
Indicates whether some other object is "equal to" this one.
-