com.atlassian.confluence.spaces
Interface SpaceGroupManager

All Known Implementing Classes:
DefaultSpaceGroupManager

public interface SpaceGroupManager


Method Summary
 SpaceGroup createSpaceGroup(java.lang.String key, java.lang.String name)
          Create a Space Group
 SpaceGroup createSpaceGroup(java.lang.String key, java.lang.String name, java.lang.String creatorName)
          Create a space Group
 SpaceGroup getSpaceGroup(long id)
          Retrieve a space by its ID.
 SpaceGroup getSpaceGroup(java.lang.String spaceGroupKey)
          Retrieve a spaceGroup by its key.
 java.util.List getSpaceGroups()
          Retrieves all SpaceGroups in the system
 java.util.Set<SpaceGroup> getSpaceGroupsForUser(java.lang.String username)
           
 void removeSpaceGroup(SpaceGroup spaceGroup, boolean removeSpaces)
          Removes the spaceGroup without removing the space.
 void saveSpaceGroup(SpaceGroup spaceGroup)
           
 

Method Detail

createSpaceGroup

SpaceGroup createSpaceGroup(java.lang.String key,
                            java.lang.String name)
Create a Space Group


createSpaceGroup

SpaceGroup createSpaceGroup(java.lang.String key,
                            java.lang.String name,
                            java.lang.String creatorName)
Create a space Group


saveSpaceGroup

void saveSpaceGroup(SpaceGroup spaceGroup)

removeSpaceGroup

void removeSpaceGroup(SpaceGroup spaceGroup,
                      boolean removeSpaces)
Removes the spaceGroup without removing the space. The contained spaces will be without a spaceGroup.


getSpaceGroup

SpaceGroup getSpaceGroup(long id)
Retrieve a space by its ID. The space can be of any type.

Parameters:
id - the ID of the space
Returns:
the space, or null if no space exists with that id.

getSpaceGroup

SpaceGroup getSpaceGroup(java.lang.String spaceGroupKey)
Retrieve a spaceGroup by its key.

Parameters:
spaceGroupKey - the key of the spaceGroup to retrieve
Returns:
the spaceGroup, or null if no spaceGroup exists with that key

getSpaceGroups

java.util.List getSpaceGroups()
Retrieves all SpaceGroups in the system

Returns:
List of SpaceGroup objects

getSpaceGroupsForUser

java.util.Set<SpaceGroup> getSpaceGroupsForUser(java.lang.String username)
Returns:
a set of space groups for the specified user, and empty set if none found.
Throws:
java.lang.IllegalArgumentException - if username is null


Copyright © 2003-2014 Atlassian. All Rights Reserved.