Package org.ametys.runtime.model
Interface ModelItemAccessor
- All Known Subinterfaces:
ContentElementDefinition,ContentType,Model,ModelItemContainer,ModifiableUserDirectory,Service,SiteType,SynchronizableContentsCollectionModel
- All Known Implementing Classes:
AbstractContentProperty,AttachmentsService,AutomaticContentType,CalendarSearchService,CatalogModel,CompositeDefinition,ConfigManager,ContentAttributeDefinition,ContentRestrictedCompositeDefinition,ContentRestrictedRepeaterDefinition,DefaultContentElementDefinition,DefaultContentType,DefaultSiteType,DefaultSynchronizableContentsCollectionModel,ExplorerFolderService,FilteredContentsService,FilteredPagesService,FormService,HTMLContentType,JdbcUserDirectory,LinkDirectoryService,ModelItemGroup,ODFContentType,OrgUnitAncestorProperty,ParentContentSystemProperty,ParentProgramsProperty,ParentSubProgramsProperty,ProgramSkillsProperty,ProjectWorkspaceSiteType,RepeaterDefinition,SearchPagesService,SearchService,ServerDirectoryService,SitemapService,SkinParametersModel,StaticService,SyndicationService,ViewParametersModel
public interface ModelItemAccessor
Interface for objects that can access to some model items
-
Method Summary
Modifier and TypeMethodDescriptiondefault ModelItemRetrieves the child model item with the given namedefault ModelItemgetModelItem(String itemPath) Retrieves the model item at given pathCollection<? extends ModelItem>Retrieves all the model items of this accessordefault booleanhasModelItem(String itemPath) Checks if there is an item defined with the given path
-
Method Details
-
getChild
Retrieves the child model item with the given name- Parameters:
childName- name of the model item child to retrieve- Returns:
- the child with the given name, or
nullif no child is found
-
getModelItem
Retrieves the model item at given path- Parameters:
itemPath- the item path- Returns:
- the model item.
- Throws:
UndefinedItemPathException- if there is no item defined at the given path
-
hasModelItem
Checks if there is an item defined with the given path- Parameters:
itemPath- path of the item- Returns:
trueif there is an item,falseotherwise
-
getModelItems
Collection<? extends ModelItem> getModelItems()Retrieves all the model items of this accessor- Returns:
- the model items
-