IWithSharingBehavior

Interface

Sharing behavior for Item-Backed Entities

Methods

Method Returns Notes
Promise<void>

Set the access level for the item

Promise<void>

Share the item with the specified group

Promise<void>

Share the item with multiple groups

Promise<IGroup[]>

Get the list of groups that the item is shared to. Limited to Groups that the user has access to

Promise<void>

Unshare the item with the specified group

Promise<void>

Unshare the item with the specified group

setAccess

Interface Method

Set the access level for the item

Parameters

Parameter Type Default Notes
access Required AccessLevel

Returns

Promise<void>

shareWithGroup

Interface Method

Share the item with the specified group

  • shareWithGroup(groupId: string) : Promise<void>

Parameters

Parameter Type Default Notes
groupId Required string

Returns

Promise<void>

shareWithGroups

Interface Method

Share the item with multiple groups

  • shareWithGroups(groupIds: string[]) : Promise<void>

Parameters

Parameter Type Default Notes
groupIds Required string[]

Returns

Promise<void>

sharedWith

Interface Method

Get the list of groups that the item is shared to. Limited to Groups that the user has access to

  • sharedWith() : Promise<IGroup[]>

Returns

Promise<IGroup[]>

unshareWithGroup

Interface Method

Unshare the item with the specified group

  • unshareWithGroup(groupId: string) : Promise<void>

Parameters

Parameter Type Default Notes
groupId Required string

Returns

Promise<void>

unshareWithGroups

Interface Method

Unshare the item with the specified group

  • unshareWithGroups(groupIds: string[]) : Promise<void>

Parameters

Parameter Type Default Notes
groupIds Required string[]

Returns

Promise<void>

Interface defined in common/src/core/behaviors/IWithSharingBehavior.ts:7