Package org.ametys.runtime.model
Class SimpleViewItemGroup
java.lang.Object
org.ametys.runtime.model.AbstractViewItemGroup
org.ametys.runtime.model.SimpleViewItemGroup
- All Implemented Interfaces:
ViewItem,ViewItemAccessor,ViewItemContainer,ViewItemGroup,Labelable,ModifiableLabelable
Simple group of view items
-
Field Summary
Fields inherited from class org.ametys.runtime.model.AbstractViewItemGroup
_children, _description, _label, _roleFields inherited from interface org.ametys.runtime.model.ViewItemGroup
FIELDSET_ROLE, TAB_ROLE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCopy the current view item in the given one.Create an instance ofViewItembooleangetName()Get the name.Retrieves the parent of the view iteminthashCode()voidincludeView(View viewToInclude, View referenceView) Include the given view to the group.voidSet the name.voidsetParent(ViewItemAccessor parent) Sets the parent of the view itemtoJSON(DefinitionContext context) Converts the view item in a JSON mapvoidtoSAX(ContentHandler contentHandler, DefinitionContext context) Generates SAX events for the view itemtoString()Methods inherited from class org.ametys.runtime.model.AbstractViewItemGroup
addViewItem, clear, equals, getDescription, getLabel, getRole, getViewItems, insertViewItem, removeViewItem, setDescription, setLabel, setRoleMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.ametys.runtime.model.ViewItemAccessor
addViewItems, getModelViewItem, getViewItem, hasModelViewItem, hasModelViewItem, hasModelViewItemMethods inherited from interface org.ametys.runtime.model.ViewItemGroup
copyTo
-
Constructor Details
-
SimpleViewItemGroup
public SimpleViewItemGroup()
-
-
Method Details
-
getName
Description copied from interface:LabelableGet the name.- Returns:
- the name.
-
setName
Description copied from interface:ModifiableLabelableSet the name.- Parameters:
name- the name.
-
getParent
Description copied from interface:ViewItemRetrieves the parent of the view item- Returns:
- the parent group
-
setParent
Description copied from interface:ViewItemSets the parent of the view item- Parameters:
parent- the parent to set
-
toJSON
Description copied from interface:ViewItemConverts the view item in a JSON map- Parameters:
context- the context of the definitions referenced in this view item and/or its children- Returns:
- The view item as a JSON map
- Throws:
ProcessingException- If an error occurs when converting the view item
-
toSAX
Description copied from interface:ViewItemGenerates SAX events for the view item- Parameters:
contentHandler- theContentHandlerthat will receive the SAX eventscontext- the context of the definitions included in the view item- Throws:
SAXException- if an error occurs during the SAX events generation
-
includeView
Include the given view to the group. Add the items of the view to include if they are not already present in the group or the reference view- Parameters:
viewToInclude- the view to includereferenceView- the reference view
-
copyTo
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- Specified by:
copyToin interfaceViewItem- Overrides:
copyToin classAbstractViewItemGroup- Parameters:
item- the copy
-
createInstance
Description copied from interface:ViewItemCreate an instance ofViewItem- Returns:
- the created instance
-
hashCode
- Overrides:
hashCodein classAbstractViewItemGroup
-
equals
- Overrides:
equalsin classAbstractViewItemGroup
-
toString
-