Class SpaceWithSubSpacesAndComponents
- java.lang.Object
-
- org.silverpeas.core.admin.service.SpaceWithSubSpacesAndComponents
-
public class SpaceWithSubSpacesAndComponents extends Object
Representation of a Silverpeas's space and component structure more or less filtered.This representation is essentially used by services using caches in order to provide as fast as possible the data.
When this object is initialized from the root space (which does not exist physically in data),
getSubSpaces()must be used to start parsing the data.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSpaceWithSubSpacesAndComponents.ComponentInstanceSelectorThis class permits to select component instances from aSpaceWithSubSpacesAndComponentsrepresenting a current view according some rules.
-
Constructor Summary
Constructors Constructor Description SpaceWithSubSpacesAndComponents(SpaceInstLight space)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SpaceWithSubSpacesAndComponents.ComponentInstanceSelectorcomponentInstanceSelector()Gets an instance ofSpaceWithSubSpacesAndComponents.ComponentInstanceSelectorinitialize from the current view the current instance is representing.List<SilverpeasComponentInstance>getComponents()Gets the list of component of current space.SpaceInstLightgetSpace()Gets the data of current space.List<SpaceWithSubSpacesAndComponents>getSubSpaces()Gets the list of space just under the current space.
-
-
-
Constructor Detail
-
SpaceWithSubSpacesAndComponents
public SpaceWithSubSpacesAndComponents(SpaceInstLight space)
-
-
Method Detail
-
getSpace
public SpaceInstLight getSpace()
Gets the data of current space.The only way to check if the space is the root one (which does not exist physically into data) is to use
SpaceInstLight.isRoot()method.
Please not checking by usingSpaceInstLight.getId()method which could eventually throwing exception.- Returns:
- the
SpaceInstLightrepresenting the current space.
-
getSubSpaces
public List<SpaceWithSubSpacesAndComponents> getSubSpaces()
Gets the list of space just under the current space.- Returns:
- list of
SpaceWithSubSpacesAndComponentsinstances.
-
getComponents
public List<SilverpeasComponentInstance> getComponents()
Gets the list of component of current space.- Returns:
- list of
ComponentInstLightinstances.
-
componentInstanceSelector
public SpaceWithSubSpacesAndComponents.ComponentInstanceSelector componentInstanceSelector()
Gets an instance ofSpaceWithSubSpacesAndComponents.ComponentInstanceSelectorinitialize from the current view the current instance is representing.- Returns:
- a
SpaceWithSubSpacesAndComponents.ComponentInstanceSelectorinstance which MUST be parametrized by usingSpaceWithSubSpacesAndComponents.ComponentInstanceSelector.fromAllSpaces(),SpaceWithSubSpacesAndComponents.ComponentInstanceSelector.fromSpaces(Set)orSpaceWithSubSpacesAndComponents.ComponentInstanceSelector.fromSubSpacesOfSpaces(Set)before callingSpaceWithSubSpacesAndComponents.ComponentInstanceSelector.select().
-
-