Class DefaultRestSpaceManager
- java.lang.Object
-
- com.atlassian.confluence.plugins.rest.manager.DefaultRestSpaceManager
-
- All Implemented Interfaces:
RestSpaceManager
public class DefaultRestSpaceManager extends Object implements RestSpaceManager
Default implementation of theRestSpaceManager.The default maximum size for the
SpaceEntityLists returned is 50.
-
-
Constructor Summary
Constructors Constructor Description DefaultRestSpaceManager(SpaceManager spaceManager, PageManager pageManager, DefaultRestContentManager restContentManager, EntityBuilderFactory entityBuilderFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SpaceEntityexpand(SpaceEntity spaceEntity)Expands and returns the givenSpaceEntity.SpaceEntitygetSpaceEntity(Space space)SpaceEntitygetSpaceEntity(String spaceKey, boolean expand)Gets theSpaceEntityfor the given spaceKey and expands it if necessary.SpaceEntityListgetSpaceEntityList(SpaceEntityListContext ctx)Gets theSpaceEntityListfor the givenSpaceEntityListContext.
-
-
-
Constructor Detail
-
DefaultRestSpaceManager
public DefaultRestSpaceManager(SpaceManager spaceManager, PageManager pageManager, DefaultRestContentManager restContentManager, EntityBuilderFactory entityBuilderFactory)
- Since:
- 7.0.
-
-
Method Detail
-
expand
public SpaceEntity expand(SpaceEntity spaceEntity)
Description copied from interface:RestSpaceManagerExpands and returns the givenSpaceEntity.- Specified by:
expandin interfaceRestSpaceManager- Parameters:
spaceEntity- the space entity to expand- Returns:
- the expanded space entity
-
getSpaceEntity
public SpaceEntity getSpaceEntity(Space space)
-
getSpaceEntity
public SpaceEntity getSpaceEntity(String spaceKey, boolean expand)
Description copied from interface:RestSpaceManagerGets theSpaceEntityfor the given spaceKey and expands it if necessary.It is responsible for doing any permission checking and conversion from Confluence's
Spaceto aSpaceEntity.nullis returned, if the current user is not permitted to view the space.- Specified by:
getSpaceEntityin interfaceRestSpaceManager- Parameters:
spaceKey- the space key of the space to retrieveexpand- whether to expand the space entity
-
getSpaceEntityList
public SpaceEntityList getSpaceEntityList(SpaceEntityListContext ctx)
Description copied from interface:RestSpaceManagerGets theSpaceEntityListfor the givenSpaceEntityListContext.It is up to the implementation to decide on default behaviour when values for in the context are not specified. The context passed in however, must not be null.
- Specified by:
getSpaceEntityListin interfaceRestSpaceManager- Parameters:
ctx- the context for which the space entity list is retrieved in
-
-