public class

DefaultRestSpaceManager

extends Object
implements RestSpaceManager
java.lang.Object
   ↳ com.atlassian.confluence.plugins.rest.manager.DefaultRestSpaceManager

Class Overview

Default implementation of the RestSpaceManager. The default maximum size for the SpaceEntityLists returned is 50.

Summary

Public Constructors
DefaultRestSpaceManager(SpaceManager spaceManager, PageManager pageManager, DefaultRestContentManager restContentManager, DateEntityHelper dateEntityHelper, SettingsManager settingsManager, EntityBuilderFactory entityBuilderFactory)
Public Methods
SpaceEntity expand(SpaceEntity spaceEntity)
Expands and returns the given SpaceEntity.
SpaceEntity getSpaceEntity(String spaceKey, boolean expand)
Gets the SpaceEntity for the given spaceKey and expands it if necessary.
SpaceEntity getSpaceEntity(Space space)
SpaceEntityList getSpaceEntityList(SpaceEntityListContext ctx)
Gets the SpaceEntityList for the given SpaceEntityListContext.
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.atlassian.confluence.plugins.rest.manager.RestSpaceManager

Public Constructors

public DefaultRestSpaceManager (SpaceManager spaceManager, PageManager pageManager, DefaultRestContentManager restContentManager, DateEntityHelper dateEntityHelper, SettingsManager settingsManager, EntityBuilderFactory entityBuilderFactory)

Public Methods

public SpaceEntity expand (SpaceEntity spaceEntity)

Expands and returns the given SpaceEntity.

Parameters
spaceEntity the space entity to expand
Returns
  • the expanded space entity

public SpaceEntity getSpaceEntity (String spaceKey, boolean expand)

Gets the SpaceEntity for the given spaceKey and expands it if necessary. It is responsible for doing any permission checking and conversion from Confluence's Space to a SpaceEntity. null is returned, if the current user is not permitted to view the space.

Parameters
spaceKey the space key of the space to retrieve
expand whether to expand the space entity

public SpaceEntity getSpaceEntity (Space space)

public SpaceEntityList getSpaceEntityList (SpaceEntityListContext ctx)

Gets the SpaceEntityList for the given SpaceEntityListContext. 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.

Parameters
ctx the context for which the space entity list is retrieved in