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
public abstract class AbstractViewItemGroup extends Object implements ViewItemGroup
Abstract class for group of view items
-
-
Field Summary
Fields Modifier and Type Field Description protected List<ViewItem>_childrenThe view item group's childrenprotected I18nizableText_descriptionThe description of the view item groupprotected I18nizableText_labelThe label of the view item groupprotected String_roleThe role of the view item group-
Fields inherited from interface org.ametys.runtime.model.ViewItemGroup
FIELDSET_ROLE, TAB_ROLE
-
-
Constructor Summary
Constructors Constructor Description AbstractViewItemGroup()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddViewItem(ViewItem item)Add a view item in the accessorvoidclear()Removes all items of this accessorvoidcopyTo(ViewItem item)Copy the current view item in the given one.booleanequals(Object obj)booleanequals(Object obj, boolean checkDetails)Indicates whether some other object is "equal to" this one.I18nizableTextgetDescription()Retrieves the description.I18nizableTextgetLabel()Retrieves the label.StringgetRole()Retrieves the role.List<ViewItem>getViewItems()Retrieves all the view items of this accessorinthashCode()voidinsertViewItem(ViewItem item, int index)Insert a view item in the accessor at the given indexbooleanremoveViewItem(ViewItem item)Removes the given items of this accessorvoidsetDescription(I18nizableText description)Set the description.voidsetLabel(I18nizableText label)Set the label.voidsetRole(String role)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, toJSON, toSAX
-
Methods inherited from interface org.ametys.runtime.model.ViewItemAccessor
addViewItems, getModelViewItem, hasModelViewItem, hasModelViewItem, hasModelViewItem
-
Methods inherited from interface org.ametys.runtime.model.ViewItemGroup
copyTo
-
-
-
-
Field Detail
-
_label
protected I18nizableText _label
The label of the view item group
-
_description
protected I18nizableText _description
The description of the view item group
-
-
Constructor Detail
-
AbstractViewItemGroup
public AbstractViewItemGroup()
-
-
Method Detail
-
getLabel
public I18nizableText getLabel()
Description copied from interface:LabelableRetrieves the label.
-
setLabel
public void setLabel(I18nizableText label)
Description copied from interface:ModifiableLabelableSet the label.- Specified by:
setLabelin interfaceModifiableLabelable- Parameters:
label- the label.
-
getDescription
public I18nizableText getDescription()
Description copied from interface:LabelableRetrieves the description.- Specified by:
getDescriptionin interfaceLabelable- Returns:
- the description.
-
setDescription
public void setDescription(I18nizableText description)
Description copied from interface:ModifiableLabelableSet the description.- Specified by:
setDescriptionin interfaceModifiableLabelable- Parameters:
description- the description.
-
getRole
public String getRole()
Description copied from interface:ViewItemGroupRetrieves the role.- Specified by:
getRolein interfaceViewItemGroup- Returns:
- the role.
-
setRole
public void setRole(String role)
Description copied from interface:ViewItemGroupSet the role.- Specified by:
setRolein interfaceViewItemGroup- Parameters:
role- the role.
-
getViewItems
public List<ViewItem> getViewItems()
Description copied from interface:ViewItemAccessorRetrieves all the view items of this accessor- Specified by:
getViewItemsin interfaceViewItemAccessor- Returns:
- the view items
-
addViewItem
public void addViewItem(ViewItem item)
Description copied from interface:ViewItemAccessorAdd a view item in the accessor- Specified by:
addViewItemin interfaceViewItemAccessor- Parameters:
item- the item to add
-
insertViewItem
public void insertViewItem(ViewItem item, int index)
Description copied from interface:ViewItemAccessorInsert a view item in the accessor at the given index- Specified by:
insertViewItemin interfaceViewItemAccessor- Parameters:
item- the item to insertindex- index at which the item has to be inserted
-
removeViewItem
public boolean removeViewItem(ViewItem item)
Description copied from interface:ViewItemAccessorRemoves the given items of this accessor- Specified by:
removeViewItemin interfaceViewItemAccessor- Parameters:
item- the item to remove- Returns:
trueif this accessor contained the given item,falseotherwise
-
clear
public void clear()
Description copied from interface:ViewItemAccessorRemoves all items of this accessor- Specified by:
clearin interfaceViewItemAccessor
-
copyTo
public void copyTo(ViewItem item)
Description copied from interface:ViewItemCopy the current view item in the given one. If the view item is an accessor, its view items are not copied
-
-