Class BoxGroupsManager
java.lang.Object
org.apache.camel.component.box.api.BoxGroupsManager
Provides operations to manage Box groups.
-
Constructor Summary
ConstructorsConstructorDescriptionBoxGroupsManager(com.box.sdk.BoxAPIConnection boxConnection) Create groups manager to manage the users of Box connection's authenticated user. -
Method Summary
Modifier and TypeMethodDescriptioncom.box.sdk.BoxGroupMembershipaddGroupMembership(String groupId, String userId, com.box.sdk.BoxGroupMembership.GroupRole role) Add a member to group with the specified role.com.box.sdk.BoxGroupcreateGroup(String name, String provenance, String externalSyncIdentifier, String description, String invitabilityLevel, String memberViewabilityLevel) Create a new group with a specified name and optional additional parameters.voiddeleteGroup(String groupId) Delete group.voiddeleteGroupMembership(String groupMembershipId) Delete group membership.Collection<com.box.sdk.BoxGroup> Get all the groups in the enterprise.com.box.sdk.BoxGroup.InfogetGroupInfo(String groupId) Get group information.com.box.sdk.BoxGroupMembership.InfogetGroupMembershipInfo(String groupMembershipId) Get group membership information.Collection<com.box.sdk.BoxGroupMembership.Info> getGroupMemberships(String groupId) Get information about all of the group memberships for this group.com.box.sdk.BoxGroupupdateGroupInfo(String groupId, com.box.sdk.BoxGroup.Info groupInfo) Update group information.com.box.sdk.BoxGroupMembershipupdateGroupMembershipInfo(String groupMembershipId, com.box.sdk.BoxGroupMembership.Info info) Update group membership information.
-
Constructor Details
-
BoxGroupsManager
public BoxGroupsManager(com.box.sdk.BoxAPIConnection boxConnection) Create groups manager to manage the users of Box connection's authenticated user.- Parameters:
boxConnection- - Box connection to authenticated user account.
-
-
Method Details
-
getAllGroups
Get all the groups in the enterprise.- Returns:
- Collection containing all the enterprise's groups.
-
createGroup
public com.box.sdk.BoxGroup createGroup(String name, String provenance, String externalSyncIdentifier, String description, String invitabilityLevel, String memberViewabilityLevel) Create a new group with a specified name and optional additional parameters. Optional parameters may be null.- Parameters:
name- - the name of the new group.provenance- - the provenance of the new group.externalSyncIdentifier- - the external_sync_identifier of the new group.description- - the description of the new group.invitabilityLevel- - the invitibility_level of the new group.memberViewabilityLevel- - the member_viewability_level of the new group.- Returns:
- The newly created group.
-
deleteGroup
Delete group.- Parameters:
groupId- - the id of group to delete.
-
getGroupInfo
Get group information.- Parameters:
groupId- - the id of group.- Returns:
- The group information.
-
updateGroupInfo
Update group information.- Parameters:
groupId- - the id of group to update.groupInfo- - the updated information- Returns:
- The updated group.
-
getGroupMemberships
Get information about all of the group memberships for this group.- Parameters:
groupId- - the id of group.- Returns:
- The group information.
-
addGroupMembership
public com.box.sdk.BoxGroupMembership addGroupMembership(String groupId, String userId, com.box.sdk.BoxGroupMembership.GroupRole role) Add a member to group with the specified role.- Parameters:
groupId- - the id of group.userId- - the id of user to be added to group.role- - the role of the user in this group. Can benullto assign the default role.- Returns:
- The group information.
-
deleteGroupMembership
Delete group membership.- Parameters:
groupMembershipId- - the id of group membership to delete.
-
getGroupMembershipInfo
Get group membership information.- Parameters:
groupMembershipId- - the id of group membership.- Returns:
- The group information.
-
updateGroupMembershipInfo
public com.box.sdk.BoxGroupMembership updateGroupMembershipInfo(String groupMembershipId, com.box.sdk.BoxGroupMembership.Info info) Update group membership information.- Parameters:
groupMembershipId- - the id of group membership to update.info- - the updated information.- Returns:
- The group information.
-