Class DbxUserSharingRequests
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddFileMember(String file, List<MemberSelector> members) Adds specified members to a file.addFileMemberBuilder(String file, List<MemberSelector> members) Adds specified members to a file.voidaddFolderMember(String sharedFolderId, List<AddMember> members) Allows an owner or editor (if the ACL update policy allows) of a shared folder to add another member.addFolderMemberBuilder(String sharedFolderId, List<AddMember> members) Allows an owner or editor (if the ACL update policy allows) of a shared folder to add another member.checkJobStatus(String asyncJobId) Returns the status of an asynchronous job.checkRemoveMemberJobStatus(String asyncJobId) Returns the status of an asynchronous job for sharing a folder.checkShareJobStatus(String asyncJobId) Returns the status of an asynchronous job for sharing a folder.createSharedLink(String path) Deprecated.Deprecated.Create a shared link with custom settings.createSharedLinkWithSettings(String path, SharedLinkSettings settings) Create a shared link with custom settings.getFileMetadata(String file) Returns shared file metadata.getFileMetadata(String file, List<FileAction> actions) Returns shared file metadata.getFileMetadataBatch(List<String> files) Returns shared file metadata.getFileMetadataBatch(List<String> files, List<FileAction> actions) Returns shared file metadata.getFolderMetadata(String sharedFolderId) Returns shared folder metadata by its folder ID.getFolderMetadata(String sharedFolderId, List<FolderAction> actions) Returns shared folder metadata by its folder ID.getSharedLinkFile(String url) Download the shared link's file from a user's Dropbox.Download the shared link's file from a user's Dropbox.Get the shared link's metadata.Get the shared link's metadata.Deprecated.getSharedLinks(String path) Deprecated.listFileMembers(String file) Use to obtain the members who have been invited to a file, both inherited and uninherited members.listFileMembersBatch(List<String> files) Get members of multiple files at once.listFileMembersBatch(List<String> files, long limit) Get members of multiple files at once.listFileMembersBuilder(String file) Use to obtain the members who have been invited to a file, both inherited and uninherited members.listFileMembersContinue(String cursor) Once a cursor has been retrieved fromlistFileMembers(String)orlistFileMembersBatch(List,long), use this to paginate through all shared file members.listFolderMembers(String sharedFolderId) Returns shared folder membership by its folder ID.listFolderMembersBuilder(String sharedFolderId) Returns shared folder membership by its folder ID.listFolderMembersContinue(String cursor) Once a cursor has been retrieved fromlistFolderMembers(String), use this to paginate through all shared folder members.Return the list of all shared folders the current user has access to.Return the list of all shared folders the current user has access to.listFoldersContinue(String cursor) Once a cursor has been retrieved fromlistFolders(com.dropbox.core.v2.sharing.ListFoldersArgs), use this to paginate through all shared folders.Return the list of all shared folders the current user can mount or unmount.Return the list of all shared folders the current user can mount or unmount.listMountableFoldersContinue(String cursor) Once a cursor has been retrieved fromlistMountableFolders(com.dropbox.core.v2.sharing.ListFoldersArgs), use this to paginate through all mountable shared folders.Returns a list of all files shared with current user.Returns a list of all files shared with current user.listReceivedFilesContinue(String cursor) Get more results with a cursor fromlistReceivedFiles(com.dropbox.core.v2.sharing.ListFilesArg).List shared links of this user.List shared links of this user.modifySharedLinkSettings(String url, SharedLinkSettings settings) Modify the shared link's settings.modifySharedLinkSettings(String url, SharedLinkSettings settings, boolean removeExpiration) Modify the shared link's settings.mountFolder(String sharedFolderId) The current user mounts the designated folder.relinquishAccess(String fileId) Removes all self-removable access from a file or folder for the current user.voidThe current user relinquishes their membership in the designated file.relinquishFolderMembership(String sharedFolderId) The current user relinquishes their membership in the designated shared folder and will no longer have access to the folder.relinquishFolderMembership(String sharedFolderId, boolean leaveACopy) The current user relinquishes their membership in the designated shared folder and will no longer have access to the folder.removeFileMember(String file, MemberSelector member) Deprecated.removeFileMember2(String file, MemberSelector member) Removes a specified member from the file.removeFolderMember(String sharedFolderId, MemberSelector member, boolean leaveACopy) Allows an owner or editor (if the ACL update policy allows) of a shared folder to remove another member.voidrevokeSharedLink(String url) Revoke a shared link.setAccessInheritance(String sharedFolderId) Change the inheritance policy of an existing Shared Folder.setAccessInheritance(String sharedFolderId, AccessInheritance accessInheritance) Change the inheritance policy of an existing Shared Folder.shareFolder(String path) Share a folder with collaborators.shareFolderBuilder(String path) Share a folder with collaborators.voidtransferFolder(String sharedFolderId, String toDropboxId) Transfer ownership of a shared folder to a member of the shared folder.voidunmountFolder(String sharedFolderId) The current user unmounts the designated folder.voidunshareFile(String file) Remove all members from this file.unshareFolder(String sharedFolderId) Allows a shared folder owner to unshare the folder.unshareFolder(String sharedFolderId, boolean leaveACopy) Allows a shared folder owner to unshare the folder.updateFileMember(String file, MemberSelector member, AccessLevel accessLevel) Changes a member's access on a shared file.updateFilePolicy(String file) Update the viewer info policy of a file.Update the viewer info policy of a file.updateFolderMember(String sharedFolderId, MemberSelector member, AccessLevel accessLevel) Allows an owner or editor of a shared folder to update another member's permissions.updateFolderPolicy(String sharedFolderId) Update the sharing policies for a shared folder.updateFolderPolicyBuilder(String sharedFolderId) Update the sharing policies for a shared folder.
-
Constructor Details
-
DbxUserSharingRequests
-
-
Method Details
-
addFileMember
public List<FileMemberActionResult> addFileMember(String file, List<MemberSelector> members) throws AddFileMemberErrorException, DbxException Adds specified members to a file.The default values for the optional request parameters will be used. See
AddFileMemberBuilderfor more details.- Parameters:
file- File to which to add members. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.members- Members to add. Note that even an email address is given, this may result in a user being directly added to the membership if that email is the user's main account email. Must not contain anullitem and not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.AddFileMemberErrorExceptionDbxException
-
addFileMemberBuilder
Adds specified members to a file.- Parameters:
file- File to which to add members. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.members- Members to add. Note that even an email address is given, this may result in a user being directly added to the membership if that email is the user's main account email. Must not contain anullitem and not benull.- Returns:
- Request builder for configuring request parameters and completing the request.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.
-
addFolderMember
public void addFolderMember(String sharedFolderId, List<AddMember> members) throws AddFolderMemberErrorException, DbxException Allows an owner or editor (if the ACL update policy allows) of a shared folder to add another member. For the new member to get access to all the functionality for this folder, you will need to callmountFolder(String)on their behalf.The default values for the optional request parameters will be used. See
AddFolderMemberBuilderfor more details.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.members- The intended list of members to add. Added members will receive invites to join the shared folder. Must not contain anullitem and not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.AddFolderMemberErrorExceptionDbxException
-
addFolderMemberBuilder
public AddFolderMemberBuilder addFolderMemberBuilder(String sharedFolderId, List<AddMember> members) Allows an owner or editor (if the ACL update policy allows) of a shared folder to add another member. For the new member to get access to all the functionality for this folder, you will need to callmountFolder(String)on their behalf.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.members- The intended list of members to add. Added members will receive invites to join the shared folder. Must not contain anullitem and not benull.- Returns:
- Request builder for configuring request parameters and completing the request.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.
-
checkJobStatus
Returns the status of an asynchronous job.- Parameters:
asyncJobId- Id of the asynchronous job. This is the value of a response returned from the method that launched the job. Must have length of at least 1 and not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.PollErrorExceptionDbxException
-
checkRemoveMemberJobStatus
public RemoveMemberJobStatus checkRemoveMemberJobStatus(String asyncJobId) throws PollErrorException, DbxException Returns the status of an asynchronous job for sharing a folder.- Parameters:
asyncJobId- Id of the asynchronous job. This is the value of a response returned from the method that launched the job. Must have length of at least 1 and not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.PollErrorExceptionDbxException
-
getFileMetadata
public SharedFileMetadata getFileMetadata(String file) throws GetFileMetadataErrorException, DbxException Returns shared file metadata.- Parameters:
file- The file to query. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.- Returns:
- Properties of the shared file.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.GetFileMetadataErrorExceptionDbxException
-
getFileMetadata
public SharedFileMetadata getFileMetadata(String file, List<FileAction> actions) throws GetFileMetadataErrorException, DbxException Returns shared file metadata.- Parameters:
file- The file to query. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.actions- A list of `FileAction`s corresponding to `FilePermission`s that should appear in the response'sSharedFileMetadata.getPermissions()field describing the actions the authenticated user can perform on the file. Must not contain anullitem.- Returns:
- Properties of the shared file.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.GetFileMetadataErrorExceptionDbxException
-
getFileMetadataBatch
public List<GetFileMetadataBatchResult> getFileMetadataBatch(List<String> files) throws SharingUserErrorException, DbxException Returns shared file metadata.- Parameters:
files- The files to query. Must contain at most 100 items, not contain anullitem, and not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.SharingUserErrorExceptionDbxException
-
getFileMetadataBatch
public List<GetFileMetadataBatchResult> getFileMetadataBatch(List<String> files, List<FileAction> actions) throws SharingUserErrorException, DbxException Returns shared file metadata.- Parameters:
files- The files to query. Must contain at most 100 items, not contain anullitem, and not benull.actions- A list of `FileAction`s corresponding to `FilePermission`s that should appear in the response'sSharedFileMetadata.getPermissions()field describing the actions the authenticated user can perform on the file. Must not contain anullitem.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.SharingUserErrorExceptionDbxException
-
getFolderMetadata
public SharedFolderMetadata getFolderMetadata(String sharedFolderId) throws SharedFolderAccessErrorException, DbxException Returns shared folder metadata by its folder ID.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.- Returns:
- The metadata which includes basic information about the shared folder.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.SharedFolderAccessErrorExceptionDbxException
-
getFolderMetadata
public SharedFolderMetadata getFolderMetadata(String sharedFolderId, List<FolderAction> actions) throws SharedFolderAccessErrorException, DbxException Returns shared folder metadata by its folder ID.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.actions- A list of `FolderAction`s corresponding to `FolderPermission`s that should appear in the response'sSharedFolderMetadata.getPermissions()field describing the actions the authenticated user can perform on the folder. Must not contain anullitem.- Returns:
- The metadata which includes basic information about the shared folder.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.SharedFolderAccessErrorExceptionDbxException
-
listFileMembers
public SharedFileMembers listFileMembers(String file) throws ListFileMembersErrorException, DbxException Use to obtain the members who have been invited to a file, both inherited and uninherited members.The default values for the optional request parameters will be used. See
ListFileMembersBuilderfor more details.- Parameters:
file- The file for which you want to see members. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.- Returns:
- Shared file user, group, and invitee membership. Used for the
results of
listFileMembers(String)andlistFileMembersContinue(String), and used as part of the results forlistFileMembersBatch(List,long). - Throws:
IllegalArgumentException- If any argument does not meet its preconditions.ListFileMembersErrorExceptionDbxException
-
listFileMembersBuilder
Use to obtain the members who have been invited to a file, both inherited and uninherited members.- Parameters:
file- The file for which you want to see members. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.- Returns:
- Request builder for configuring request parameters and completing the request.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.
-
listFileMembersBatch
public List<ListFileMembersBatchResult> listFileMembersBatch(List<String> files) throws SharingUserErrorException, DbxException Get members of multiple files at once. The arguments to this route are more limited, and the limit on query result size per file is more strict. To customize the results more, use the individual file endpoint. Inherited users and groups are not included in the result, and permissions are not returned for this endpoint.The
limitrequest parameter will default to1000L(seelistFileMembersBatch(List,long)).- Parameters:
files- Files for which to return members. Must contain at most 100 items, not contain anullitem, and not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.SharingUserErrorExceptionDbxException
-
listFileMembersBatch
public List<ListFileMembersBatchResult> listFileMembersBatch(List<String> files, long limit) throws SharingUserErrorException, DbxException Get members of multiple files at once. The arguments to this route are more limited, and the limit on query result size per file is more strict. To customize the results more, use the individual file endpoint. Inherited users and groups are not included in the result, and permissions are not returned for this endpoint.- Parameters:
files- Files for which to return members. Must contain at most 100 items, not contain anullitem, and not benull.limit- Number of members to return max per query. Defaults to 1000 if no limit is specified. Must be less than or equal to 3000.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.SharingUserErrorExceptionDbxException
-
listFileMembersContinue
public SharedFileMembers listFileMembersContinue(String cursor) throws ListFileMembersContinueErrorException, DbxException Once a cursor has been retrieved fromlistFileMembers(String)orlistFileMembersBatch(List,long), use this to paginate through all shared file members.- Parameters:
cursor- The cursor returned by your last call tolistFileMembers(String),listFileMembersContinue(String), orlistFileMembersBatch(List,long). Must not benull.- Returns:
- Shared file user, group, and invitee membership. Used for the
results of
listFileMembers(String)andlistFileMembersContinue(String), and used as part of the results forlistFileMembersBatch(List,long). - Throws:
IllegalArgumentException- If any argument does not meet its preconditions.ListFileMembersContinueErrorExceptionDbxException
-
listFolderMembers
public SharedFolderMembers listFolderMembers(String sharedFolderId) throws SharedFolderAccessErrorException, DbxException Returns shared folder membership by its folder ID.The default values for the optional request parameters will be used. See
ListFolderMembersBuilderfor more details.- Parameters:
sharedFolderId- The ID for the shared folder. When path is provided, the folder ID will be extracted from the path instead. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.- Returns:
- Shared folder user and group membership.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.SharedFolderAccessErrorExceptionDbxException
-
listFolderMembersBuilder
Returns shared folder membership by its folder ID.- Parameters:
sharedFolderId- The ID for the shared folder. When path is provided, the folder ID will be extracted from the path instead. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.- Returns:
- Request builder for configuring request parameters and completing the request.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.
-
listFolderMembersContinue
public SharedFolderMembers listFolderMembersContinue(String cursor) throws ListFolderMembersContinueErrorException, DbxException Once a cursor has been retrieved fromlistFolderMembers(String), use this to paginate through all shared folder members.- Parameters:
cursor- The cursor returned by your last call tolistFolderMembers(String)orlistFolderMembersContinue(String). Must not benull.- Returns:
- Shared folder user and group membership.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.ListFolderMembersContinueErrorExceptionDbxException
-
listFolders
Return the list of all shared folders the current user has access to.The default values for the optional request parameters will be used. See
ListFoldersBuilderfor more details.- Returns:
- Result for
listFolders(com.dropbox.core.v2.sharing.ListFoldersArgs)orlistMountableFolders(com.dropbox.core.v2.sharing.ListFoldersArgs), depending on which endpoint was requested. Unmounted shared folders can be identified by the absence ofSharedFolderMetadata.getPathLower(). - Throws:
DbxApiExceptionDbxException
-
listFoldersBuilder
Return the list of all shared folders the current user has access to.- Returns:
- Request builder for configuring request parameters and completing the request.
-
listFoldersContinue
public ListFoldersResult listFoldersContinue(String cursor) throws ListFoldersContinueErrorException, DbxException Once a cursor has been retrieved fromlistFolders(com.dropbox.core.v2.sharing.ListFoldersArgs), use this to paginate through all shared folders. The cursor must come from a previous call tolistFolders(com.dropbox.core.v2.sharing.ListFoldersArgs)orlistFoldersContinue(String).- Parameters:
cursor- The cursor returned by the previous API call specified in the endpoint description. Must not benull.- Returns:
- Result for
listFolders(com.dropbox.core.v2.sharing.ListFoldersArgs)orlistMountableFolders(com.dropbox.core.v2.sharing.ListFoldersArgs), depending on which endpoint was requested. Unmounted shared folders can be identified by the absence ofSharedFolderMetadata.getPathLower(). - Throws:
IllegalArgumentException- If any argument does not meet its preconditions.ListFoldersContinueErrorExceptionDbxException
-
listMountableFolders
Return the list of all shared folders the current user can mount or unmount.The default values for the optional request parameters will be used. See
ListMountableFoldersBuilderfor more details.- Returns:
- Result for
listFolders(com.dropbox.core.v2.sharing.ListFoldersArgs)orlistMountableFolders(com.dropbox.core.v2.sharing.ListFoldersArgs), depending on which endpoint was requested. Unmounted shared folders can be identified by the absence ofSharedFolderMetadata.getPathLower(). - Throws:
DbxApiExceptionDbxException
-
listMountableFoldersBuilder
Return the list of all shared folders the current user can mount or unmount.- Returns:
- Request builder for configuring request parameters and completing the request.
-
listMountableFoldersContinue
public ListFoldersResult listMountableFoldersContinue(String cursor) throws ListFoldersContinueErrorException, DbxException Once a cursor has been retrieved fromlistMountableFolders(com.dropbox.core.v2.sharing.ListFoldersArgs), use this to paginate through all mountable shared folders. The cursor must come from a previous call tolistMountableFolders(com.dropbox.core.v2.sharing.ListFoldersArgs)orlistMountableFoldersContinue(String).- Parameters:
cursor- The cursor returned by the previous API call specified in the endpoint description. Must not benull.- Returns:
- Result for
listFolders(com.dropbox.core.v2.sharing.ListFoldersArgs)orlistMountableFolders(com.dropbox.core.v2.sharing.ListFoldersArgs), depending on which endpoint was requested. Unmounted shared folders can be identified by the absence ofSharedFolderMetadata.getPathLower(). - Throws:
IllegalArgumentException- If any argument does not meet its preconditions.ListFoldersContinueErrorExceptionDbxException
-
listReceivedFiles
Returns a list of all files shared with current user.The default values for the optional request parameters will be used. See
ListReceivedFilesBuilderfor more details.- Returns:
- Success results for
listReceivedFiles(com.dropbox.core.v2.sharing.ListFilesArg). - Throws:
SharingUserErrorExceptionDbxException
-
listReceivedFilesBuilder
Returns a list of all files shared with current user.- Returns:
- Request builder for configuring request parameters and completing the request.
-
listReceivedFilesContinue
public ListFilesResult listReceivedFilesContinue(String cursor) throws ListFilesContinueErrorException, DbxException Get more results with a cursor fromlistReceivedFiles(com.dropbox.core.v2.sharing.ListFilesArg).- Parameters:
cursor- Cursor inListFilesResult.getCursor(). Must not benull.- Returns:
- Success results for
listReceivedFiles(com.dropbox.core.v2.sharing.ListFilesArg). - Throws:
IllegalArgumentException- If any argument does not meet its preconditions.ListFilesContinueErrorExceptionDbxException
-
mountFolder
public SharedFolderMetadata mountFolder(String sharedFolderId) throws MountFolderErrorException, DbxException The current user mounts the designated folder. Mount a shared folder for a user after they have been added as a member. Once mounted, the shared folder will appear in their Dropbox.- Parameters:
sharedFolderId- The ID of the shared folder to mount. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.- Returns:
- The metadata which includes basic information about the shared folder.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.MountFolderErrorExceptionDbxException
-
relinquishAccess
public RelinquishAccessResult relinquishAccess(String fileId) throws RelinquishAccessErrorException, DbxException Removes all self-removable access from a file or folder for the current user. Best-effort and idempotent: attempts to drop link-visitor associations and explicit ACL membership.- Parameters:
fileId- The id for the file or folder. Must not benull.- Returns:
- Returns an empty response for the relinquish_access endpoint.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.RelinquishAccessErrorExceptionDbxException
-
relinquishFileMembership
public void relinquishFileMembership(String file) throws RelinquishFileMembershipErrorException, DbxException The current user relinquishes their membership in the designated file.- Parameters:
file- The path or id for the file. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.RelinquishFileMembershipErrorExceptionDbxException
-
relinquishFolderMembership
public LaunchEmptyResult relinquishFolderMembership(String sharedFolderId) throws RelinquishFolderMembershipErrorException, DbxException The current user relinquishes their membership in the designated shared folder and will no longer have access to the folder. A folder owner cannot relinquish membership in their own folder. This will run synchronously if leave_a_copy is false, and asynchronously if leave_a_copy is true.The
leaveACopyrequest parameter will default tofalse(seerelinquishFolderMembership(String,boolean)).- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.- Returns:
- Result returned by methods that may either launch an asynchronous job or complete synchronously. Upon synchronous completion of the job, no additional information is returned.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.RelinquishFolderMembershipErrorExceptionDbxException
-
relinquishFolderMembership
public LaunchEmptyResult relinquishFolderMembership(String sharedFolderId, boolean leaveACopy) throws RelinquishFolderMembershipErrorException, DbxException The current user relinquishes their membership in the designated shared folder and will no longer have access to the folder. A folder owner cannot relinquish membership in their own folder. This will run synchronously if leave_a_copy is false, and asynchronously if leave_a_copy is true.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.leaveACopy- Keep a copy of the folder's contents upon relinquishing membership. This must be set to false when the folder is within a team folder or another shared folder.- Returns:
- Result returned by methods that may either launch an asynchronous job or complete synchronously. Upon synchronous completion of the job, no additional information is returned.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.RelinquishFolderMembershipErrorExceptionDbxException
-
removeFileMember
@Deprecated public FileMemberActionIndividualResult removeFileMember(String file, MemberSelector member) throws RemoveFileMemberErrorException, DbxException Deprecated.Identical to remove_file_member_2 but with less information returned.- Parameters:
file- File from which to remove members. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.member- Member to remove from this file. Note that even if an email is specified, it may result in the removal of a user (not an invitee) if the user's main account corresponds to that email address. Must not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.RemoveFileMemberErrorExceptionDbxException
-
removeFileMember2
public FileMemberRemoveActionResult removeFileMember2(String file, MemberSelector member) throws RemoveFileMemberErrorException, DbxException Removes a specified member from the file.- Parameters:
file- File from which to remove members. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.member- Member to remove from this file. Note that even if an email is specified, it may result in the removal of a user (not an invitee) if the user's main account corresponds to that email address. Must not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.RemoveFileMemberErrorExceptionDbxException
-
removeFolderMember
public LaunchResultBase removeFolderMember(String sharedFolderId, MemberSelector member, boolean leaveACopy) throws RemoveFolderMemberErrorException, DbxException Allows an owner or editor (if the ACL update policy allows) of a shared folder to remove another member.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.member- The member to remove from the folder. Must not benull.leaveACopy- If true, the removed user will keep their copy of the folder after it's unshared, assuming it was mounted. Otherwise, it will be removed from their Dropbox. This must be set to false when removing a group, or when the folder is within a team folder or another shared folder.- Returns:
- Result returned by methods that launch an asynchronous job. A
method who may either launch an asynchronous job, or complete the
request synchronously, can use this union by extending it, and adding
a 'complete' field with the type of the synchronous response. See
LaunchEmptyResultfor an example. - Throws:
IllegalArgumentException- If any argument does not meet its preconditions.RemoveFolderMemberErrorExceptionDbxException
-
setAccessInheritance
public ShareFolderLaunch setAccessInheritance(String sharedFolderId) throws SetAccessInheritanceErrorException, DbxException Change the inheritance policy of an existing Shared Folder. Only permitted for shared folders in a shared team root. If aShareFolderLaunch.getAsyncJobIdValue()is returned, you'll need to callcheckShareJobStatus(String)until the action completes to get the metadata for the folder.The
accessInheritancerequest parameter will default toAccessInheritance.INHERIT(seesetAccessInheritance(String,AccessInheritance)).- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.SetAccessInheritanceErrorExceptionDbxException
-
setAccessInheritance
public ShareFolderLaunch setAccessInheritance(String sharedFolderId, AccessInheritance accessInheritance) throws SetAccessInheritanceErrorException, DbxException Change the inheritance policy of an existing Shared Folder. Only permitted for shared folders in a shared team root. If aShareFolderLaunch.getAsyncJobIdValue()is returned, you'll need to callcheckShareJobStatus(String)until the action completes to get the metadata for the folder.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.accessInheritance- The access inheritance settings for the folder. Must not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.SetAccessInheritanceErrorExceptionDbxException
-
transferFolder
public void transferFolder(String sharedFolderId, String toDropboxId) throws TransferFolderErrorException, DbxException Transfer ownership of a shared folder to a member of the shared folder. User must haveAccessLevel.OWNERaccess to the shared folder to perform a transfer.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.toDropboxId- A account or team member ID to transfer ownership to. Must have length of at least 1 and not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.TransferFolderErrorExceptionDbxException
-
unmountFolder
The current user unmounts the designated folder. They can re-mount the folder at a later time usingmountFolder(String).- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.UnmountFolderErrorExceptionDbxException
-
updateFileMember
public MemberAccessLevelResult updateFileMember(String file, MemberSelector member, AccessLevel accessLevel) throws FileMemberActionErrorException, DbxException Changes a member's access on a shared file.- Parameters:
file- File for which we are changing a member's access. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.member- The member whose access we are changing. Must not benull.accessLevel- The new access level for the member. Must not benull.- Returns:
- Contains information about a member's access level to content after an operation.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.FileMemberActionErrorExceptionDbxException
-
updateFilePolicy
public SharedFileMetadata updateFilePolicy(String file) throws UpdateFilePolicyErrorException, DbxException Update the viewer info policy of a file.- Parameters:
file- File that we are changing the policy for. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.- Returns:
- Properties of the shared file.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.UpdateFilePolicyErrorExceptionDbxException
-
updateFilePolicyBuilder
Update the viewer info policy of a file.- Parameters:
file- File that we are changing the policy for. Must have length of at least 1, match pattern "((/|id:).*|nspath:[0-9]+:.*)|ns:[0-9]+(/.*)?", and not benull.- Returns:
- Request builder for configuring request parameters and completing the request.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.
-
updateFolderMember
public MemberAccessLevelResult updateFolderMember(String sharedFolderId, MemberSelector member, AccessLevel accessLevel) throws UpdateFolderMemberErrorException, DbxException Allows an owner or editor of a shared folder to update another member's permissions.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.member- The member of the shared folder to update. Only theMemberSelector.getDropboxIdValue()may be set at this time. Must not benull.accessLevel- The new access level forUpdateFolderMemberArg.getMember().AccessLevel.OWNERis disallowed. Must not benull.- Returns:
- Contains information about a member's access level to content after an operation.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.UpdateFolderMemberErrorExceptionDbxException
-
updateFolderPolicy
public SharedFolderMetadata updateFolderPolicy(String sharedFolderId) throws UpdateFolderPolicyErrorException, DbxException Update the sharing policies for a shared folder. User must haveAccessLevel.OWNERaccess to the shared folder to update its policies.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.- Returns:
- The metadata which includes basic information about the shared folder.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.UpdateFolderPolicyErrorExceptionDbxException
-
updateFolderPolicyBuilder
Update the sharing policies for a shared folder. User must haveAccessLevel.OWNERaccess to the shared folder to update its policies.- Parameters:
sharedFolderId- The ID for the shared folder. Must match pattern "[-_0-9a-zA-Z:]+" and not benull.- Returns:
- Request builder for configuring request parameters and completing the request.
- Throws:
IllegalArgumentException- If any argument does not meet its preconditions.
-