public final class JobError
extends java.lang.Object
DbxUserSharingRequests.unshareFolder(String,boolean)
or DbxUserSharingRequests.removeFolderMember(String,MemberSelector,boolean)
.
This class is an open tagged union. Tagged unions instances are always
associated to a specific tag. This means only one of the isAbc()
methods will return true
. You can use tag()
to determine the
tag associated with this instance.
Open unions may be extended in the future with additional tags. If a new
tag is introduced that this SDK does not recognized, the OTHER
value
will be used.
Modifier and Type | Class and Description |
---|---|
static class |
JobError.Tag
Discriminating tag type for
JobError . |
Modifier and Type | Field and Description |
---|---|
static JobError |
OTHER
Catch-all used for unknown tag values returned by the Dropbox servers.
|
public static final JobError OTHER
Receiving a catch-all value typically indicates this SDK version is not up to date. Consider updating your SDK version to handle the new tags.
public JobError.Tag tag()
This class is a tagged union. Tagged unions instances are always
associated to a specific tag. This means only one of the isXyz()
methods will return true
. Callers are recommended to use the tag
value in a switch
statement to properly handle the different
values for this JobError
.
If a tag returned by the server is unrecognized by this SDK, the
JobError.Tag.OTHER
value will be used.
public boolean isUnshareFolderError()
true
if this instance is tagged as JobError.Tag.UNSHARE_FOLDER_ERROR
, false
otherwise.public static JobError unshareFolderError(UnshareFolderError value)
JobError
that has its tag set to JobError.Tag.UNSHARE_FOLDER_ERROR
.
Error occurred while performing DbxUserSharingRequests.unshareFolder(String,boolean)
action.
value
- value to assign to this instance.JobError
with its tag set to JobError.Tag.UNSHARE_FOLDER_ERROR
.java.lang.IllegalArgumentException
- if value
is null
.public UnshareFolderError getUnshareFolderErrorValue()
DbxUserSharingRequests.unshareFolder(String,boolean)
action.
This instance must be tagged as JobError.Tag.UNSHARE_FOLDER_ERROR
.
UnshareFolderError
value associated with this
instance if isUnshareFolderError()
is true
.java.lang.IllegalStateException
- If isUnshareFolderError()
is false
.public boolean isRemoveFolderMemberError()
true
if this instance is tagged as JobError.Tag.REMOVE_FOLDER_MEMBER_ERROR
, false
otherwise.public static JobError removeFolderMemberError(RemoveFolderMemberError value)
JobError
that has its tag set to JobError.Tag.REMOVE_FOLDER_MEMBER_ERROR
.
Error occurred while performing DbxUserSharingRequests.removeFolderMember(String,MemberSelector,boolean)
action.
value
- value to assign to this instance.JobError
with its tag set to JobError.Tag.REMOVE_FOLDER_MEMBER_ERROR
.java.lang.IllegalArgumentException
- if value
is null
.public RemoveFolderMemberError getRemoveFolderMemberErrorValue()
DbxUserSharingRequests.removeFolderMember(String,MemberSelector,boolean)
action.
This instance must be tagged as JobError.Tag.REMOVE_FOLDER_MEMBER_ERROR
.
RemoveFolderMemberError
value associated with this
instance if isRemoveFolderMemberError()
is true
.java.lang.IllegalStateException
- If isRemoveFolderMemberError()
is
false
.public boolean isRelinquishFolderMembershipError()
true
if this instance has the tag JobError.Tag.RELINQUISH_FOLDER_MEMBERSHIP_ERROR
, false
otherwise.true
if this instance is tagged as JobError.Tag.RELINQUISH_FOLDER_MEMBERSHIP_ERROR
, false
otherwise.public static JobError relinquishFolderMembershipError(RelinquishFolderMembershipError value)
JobError
that has its tag set to JobError.Tag.RELINQUISH_FOLDER_MEMBERSHIP_ERROR
.
Error occurred while performing DbxUserSharingRequests.relinquishFolderMembership(String,boolean)
action.
value
- value to assign to this instance.JobError
with its tag set to JobError.Tag.RELINQUISH_FOLDER_MEMBERSHIP_ERROR
.java.lang.IllegalArgumentException
- if value
is null
.public RelinquishFolderMembershipError getRelinquishFolderMembershipErrorValue()
DbxUserSharingRequests.relinquishFolderMembership(String,boolean)
action.
This instance must be tagged as JobError.Tag.RELINQUISH_FOLDER_MEMBERSHIP_ERROR
.
RelinquishFolderMembershipError
value associated with
this instance if isRelinquishFolderMembershipError()
is true
.java.lang.IllegalStateException
- If isRelinquishFolderMembershipError()
is false
.public boolean isOther()
true
if this instance is tagged as JobError.Tag.OTHER
,
false
otherwise.public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String toStringMultiline()
The returned String may contain newlines.