Class MemberAddV2Result
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.
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final MemberAddV2ResultCatch-all used for unknown tag values returned by the Dropbox servers. -
Method Summary
Modifier and TypeMethodDescriptionstatic MemberAddV2ResultduplicateExternalMemberId(String value) Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.DUPLICATE_EXTERNAL_MEMBER_ID.static MemberAddV2ResultReturns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.DUPLICATE_MEMBER_PERSISTENT_ID.booleanstatic MemberAddV2ResultfreeTeamMemberLimitReached(String value) Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.FREE_TEAM_MEMBER_LIMIT_REACHED.A user with the given external member ID already exists on the team (including in recoverable state).A user with the given persistent ID already exists on the team (including in recoverable state).Team is already full.Persistent ID is only available to teams with persistent ID SAML configuration.Describes a user that was successfully added to the team.Team is already full.User is already on this team.User is already paired.User creation has failed.User migration has failed.User is already on another team.inthashCode()booleanReturnstrueif this instance has the tagMemberAddV2Result.Tag.DUPLICATE_EXTERNAL_MEMBER_ID,falseotherwise.booleanReturnstrueif this instance has the tagMemberAddV2Result.Tag.DUPLICATE_MEMBER_PERSISTENT_ID,falseotherwise.booleanReturnstrueif this instance has the tagMemberAddV2Result.Tag.FREE_TEAM_MEMBER_LIMIT_REACHED,falseotherwise.booleanisOther()booleanReturnstrueif this instance has the tagMemberAddV2Result.Tag.PERSISTENT_ID_DISABLED,falseotherwise.booleanbooleanReturnstrueif this instance has the tagMemberAddV2Result.Tag.TEAM_LICENSE_LIMIT,falseotherwise.booleanReturnstrueif this instance has the tagMemberAddV2Result.Tag.USER_ALREADY_ON_TEAM,falseotherwise.booleanReturnstrueif this instance has the tagMemberAddV2Result.Tag.USER_ALREADY_PAIRED,falseotherwise.booleanReturnstrueif this instance has the tagMemberAddV2Result.Tag.USER_CREATION_FAILED,falseotherwise.booleanReturnstrueif this instance has the tagMemberAddV2Result.Tag.USER_MIGRATION_FAILED,falseotherwise.booleanReturnstrueif this instance has the tagMemberAddV2Result.Tag.USER_ON_ANOTHER_TEAM,falseotherwise.static MemberAddV2ResultpersistentIdDisabled(String value) Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.PERSISTENT_ID_DISABLED.static MemberAddV2Resultsuccess(TeamMemberInfoV2 value) Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.SUCCESS.tag()Returns the tag for this instance.static MemberAddV2ResultteamLicenseLimit(String value) Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.TEAM_LICENSE_LIMIT.toString()Returns a String representation of this object formatted for easier readability.static MemberAddV2ResultuserAlreadyOnTeam(String value) Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.USER_ALREADY_ON_TEAM.static MemberAddV2ResultuserAlreadyPaired(String value) Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.USER_ALREADY_PAIRED.static MemberAddV2ResultuserCreationFailed(String value) Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.USER_CREATION_FAILED.static MemberAddV2ResultuserMigrationFailed(String value) Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.USER_MIGRATION_FAILED.static MemberAddV2ResultuserOnAnotherTeam(String value) Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.USER_ON_ANOTHER_TEAM.
-
Field Details
-
OTHER
Catch-all used for unknown tag values returned by the Dropbox servers.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.
-
-
Method Details
-
tag
Returns the tag for this instance.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 returntrue. Callers are recommended to use the tag value in aswitchstatement to properly handle the different values for thisMemberAddV2Result.If a tag returned by the server is unrecognized by this SDK, the
MemberAddV2Result.Tag.OTHERvalue will be used.- Returns:
- the tag for this instance.
-
isTeamLicenseLimit
public boolean isTeamLicenseLimit()Returnstrueif this instance has the tagMemberAddV2Result.Tag.TEAM_LICENSE_LIMIT,falseotherwise.- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.TEAM_LICENSE_LIMIT,falseotherwise.
-
teamLicenseLimit
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.TEAM_LICENSE_LIMIT.Team is already full. The organization has no available licenses.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.TEAM_LICENSE_LIMIT. - Throws:
IllegalArgumentException- ifvalueis longer than 255, does not match pattern "^['#&A-Za-z0-9._%+-]+@[A-Za-z0-9-][A-Za-z0-9.-]*\\.[A-Za-z]{2,15}$", or isnull.
-
getTeamLicenseLimitValue
Team is already full. The organization has no available licenses.This instance must be tagged as
MemberAddV2Result.Tag.TEAM_LICENSE_LIMIT.- Returns:
- The
Stringvalue associated with this instance ifisTeamLicenseLimit()istrue. - Throws:
IllegalStateException- IfisTeamLicenseLimit()isfalse.
-
isFreeTeamMemberLimitReached
public boolean isFreeTeamMemberLimitReached()Returnstrueif this instance has the tagMemberAddV2Result.Tag.FREE_TEAM_MEMBER_LIMIT_REACHED,falseotherwise.- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.FREE_TEAM_MEMBER_LIMIT_REACHED,falseotherwise.
-
freeTeamMemberLimitReached
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.FREE_TEAM_MEMBER_LIMIT_REACHED.Team is already full. The free team member limit has been reached.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.FREE_TEAM_MEMBER_LIMIT_REACHED. - Throws:
IllegalArgumentException- ifvalueis longer than 255, does not match pattern "^['#&A-Za-z0-9._%+-]+@[A-Za-z0-9-][A-Za-z0-9.-]*\\.[A-Za-z]{2,15}$", or isnull.
-
getFreeTeamMemberLimitReachedValue
Team is already full. The free team member limit has been reached.This instance must be tagged as
MemberAddV2Result.Tag.FREE_TEAM_MEMBER_LIMIT_REACHED.- Returns:
- The
Stringvalue associated with this instance ifisFreeTeamMemberLimitReached()istrue. - Throws:
IllegalStateException- IfisFreeTeamMemberLimitReached()isfalse.
-
isUserAlreadyOnTeam
public boolean isUserAlreadyOnTeam()Returnstrueif this instance has the tagMemberAddV2Result.Tag.USER_ALREADY_ON_TEAM,falseotherwise.- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.USER_ALREADY_ON_TEAM,falseotherwise.
-
userAlreadyOnTeam
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.USER_ALREADY_ON_TEAM.User is already on this team. The provided email address is associated with a user who is already a member of (including in recoverable state) or invited to the team.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.USER_ALREADY_ON_TEAM. - Throws:
IllegalArgumentException- ifvalueis longer than 255, does not match pattern "^['#&A-Za-z0-9._%+-]+@[A-Za-z0-9-][A-Za-z0-9.-]*\\.[A-Za-z]{2,15}$", or isnull.
-
getUserAlreadyOnTeamValue
User is already on this team. The provided email address is associated with a user who is already a member of (including in recoverable state) or invited to the team.This instance must be tagged as
MemberAddV2Result.Tag.USER_ALREADY_ON_TEAM.- Returns:
- The
Stringvalue associated with this instance ifisUserAlreadyOnTeam()istrue. - Throws:
IllegalStateException- IfisUserAlreadyOnTeam()isfalse.
-
isUserOnAnotherTeam
public boolean isUserOnAnotherTeam()Returnstrueif this instance has the tagMemberAddV2Result.Tag.USER_ON_ANOTHER_TEAM,falseotherwise.- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.USER_ON_ANOTHER_TEAM,falseotherwise.
-
userOnAnotherTeam
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.USER_ON_ANOTHER_TEAM.User is already on another team. The provided email address is associated with a user that is already a member or invited to another team.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.USER_ON_ANOTHER_TEAM. - Throws:
IllegalArgumentException- ifvalueis longer than 255, does not match pattern "^['#&A-Za-z0-9._%+-]+@[A-Za-z0-9-][A-Za-z0-9.-]*\\.[A-Za-z]{2,15}$", or isnull.
-
getUserOnAnotherTeamValue
User is already on another team. The provided email address is associated with a user that is already a member or invited to another team.This instance must be tagged as
MemberAddV2Result.Tag.USER_ON_ANOTHER_TEAM.- Returns:
- The
Stringvalue associated with this instance ifisUserOnAnotherTeam()istrue. - Throws:
IllegalStateException- IfisUserOnAnotherTeam()isfalse.
-
isUserAlreadyPaired
public boolean isUserAlreadyPaired()Returnstrueif this instance has the tagMemberAddV2Result.Tag.USER_ALREADY_PAIRED,falseotherwise.- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.USER_ALREADY_PAIRED,falseotherwise.
-
userAlreadyPaired
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.USER_ALREADY_PAIRED.User is already paired.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.USER_ALREADY_PAIRED. - Throws:
IllegalArgumentException- ifvalueis longer than 255, does not match pattern "^['#&A-Za-z0-9._%+-]+@[A-Za-z0-9-][A-Za-z0-9.-]*\\.[A-Za-z]{2,15}$", or isnull.
-
getUserAlreadyPairedValue
User is already paired.This instance must be tagged as
MemberAddV2Result.Tag.USER_ALREADY_PAIRED.- Returns:
- The
Stringvalue associated with this instance ifisUserAlreadyPaired()istrue. - Throws:
IllegalStateException- IfisUserAlreadyPaired()isfalse.
-
isUserMigrationFailed
public boolean isUserMigrationFailed()Returnstrueif this instance has the tagMemberAddV2Result.Tag.USER_MIGRATION_FAILED,falseotherwise.- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.USER_MIGRATION_FAILED,falseotherwise.
-
userMigrationFailed
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.USER_MIGRATION_FAILED.User migration has failed.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.USER_MIGRATION_FAILED. - Throws:
IllegalArgumentException- ifvalueis longer than 255, does not match pattern "^['#&A-Za-z0-9._%+-]+@[A-Za-z0-9-][A-Za-z0-9.-]*\\.[A-Za-z]{2,15}$", or isnull.
-
getUserMigrationFailedValue
User migration has failed.This instance must be tagged as
MemberAddV2Result.Tag.USER_MIGRATION_FAILED.- Returns:
- The
Stringvalue associated with this instance ifisUserMigrationFailed()istrue. - Throws:
IllegalStateException- IfisUserMigrationFailed()isfalse.
-
isDuplicateExternalMemberId
public boolean isDuplicateExternalMemberId()Returnstrueif this instance has the tagMemberAddV2Result.Tag.DUPLICATE_EXTERNAL_MEMBER_ID,falseotherwise.- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.DUPLICATE_EXTERNAL_MEMBER_ID,falseotherwise.
-
duplicateExternalMemberId
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.DUPLICATE_EXTERNAL_MEMBER_ID.A user with the given external member ID already exists on the team (including in recoverable state).
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.DUPLICATE_EXTERNAL_MEMBER_ID. - Throws:
IllegalArgumentException- ifvalueis longer than 255, does not match pattern "^['#&A-Za-z0-9._%+-]+@[A-Za-z0-9-][A-Za-z0-9.-]*\\.[A-Za-z]{2,15}$", or isnull.
-
getDuplicateExternalMemberIdValue
A user with the given external member ID already exists on the team (including in recoverable state).This instance must be tagged as
MemberAddV2Result.Tag.DUPLICATE_EXTERNAL_MEMBER_ID.- Returns:
- The
Stringvalue associated with this instance ifisDuplicateExternalMemberId()istrue. - Throws:
IllegalStateException- IfisDuplicateExternalMemberId()isfalse.
-
isDuplicateMemberPersistentId
public boolean isDuplicateMemberPersistentId()Returnstrueif this instance has the tagMemberAddV2Result.Tag.DUPLICATE_MEMBER_PERSISTENT_ID,falseotherwise.- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.DUPLICATE_MEMBER_PERSISTENT_ID,falseotherwise.
-
duplicateMemberPersistentId
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.DUPLICATE_MEMBER_PERSISTENT_ID.A user with the given persistent ID already exists on the team (including in recoverable state).
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.DUPLICATE_MEMBER_PERSISTENT_ID. - Throws:
IllegalArgumentException- ifvalueis longer than 255, does not match pattern "^['#&A-Za-z0-9._%+-]+@[A-Za-z0-9-][A-Za-z0-9.-]*\\.[A-Za-z]{2,15}$", or isnull.
-
getDuplicateMemberPersistentIdValue
A user with the given persistent ID already exists on the team (including in recoverable state).This instance must be tagged as
MemberAddV2Result.Tag.DUPLICATE_MEMBER_PERSISTENT_ID.- Returns:
- The
Stringvalue associated with this instance ifisDuplicateMemberPersistentId()istrue. - Throws:
IllegalStateException- IfisDuplicateMemberPersistentId()isfalse.
-
isPersistentIdDisabled
public boolean isPersistentIdDisabled()Returnstrueif this instance has the tagMemberAddV2Result.Tag.PERSISTENT_ID_DISABLED,falseotherwise.- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.PERSISTENT_ID_DISABLED,falseotherwise.
-
persistentIdDisabled
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.PERSISTENT_ID_DISABLED.Persistent ID is only available to teams with persistent ID SAML configuration. Please contact Dropbox for more information.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.PERSISTENT_ID_DISABLED. - Throws:
IllegalArgumentException- ifvalueis longer than 255, does not match pattern "^['#&A-Za-z0-9._%+-]+@[A-Za-z0-9-][A-Za-z0-9.-]*\\.[A-Za-z]{2,15}$", or isnull.
-
getPersistentIdDisabledValue
Persistent ID is only available to teams with persistent ID SAML configuration. Please contact Dropbox for more information.This instance must be tagged as
MemberAddV2Result.Tag.PERSISTENT_ID_DISABLED.- Returns:
- The
Stringvalue associated with this instance ifisPersistentIdDisabled()istrue. - Throws:
IllegalStateException- IfisPersistentIdDisabled()isfalse.
-
isUserCreationFailed
public boolean isUserCreationFailed()Returnstrueif this instance has the tagMemberAddV2Result.Tag.USER_CREATION_FAILED,falseotherwise.- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.USER_CREATION_FAILED,falseotherwise.
-
userCreationFailed
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.USER_CREATION_FAILED.User creation has failed.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.USER_CREATION_FAILED. - Throws:
IllegalArgumentException- ifvalueis longer than 255, does not match pattern "^['#&A-Za-z0-9._%+-]+@[A-Za-z0-9-][A-Za-z0-9.-]*\\.[A-Za-z]{2,15}$", or isnull.
-
getUserCreationFailedValue
User creation has failed.This instance must be tagged as
MemberAddV2Result.Tag.USER_CREATION_FAILED.- Returns:
- The
Stringvalue associated with this instance ifisUserCreationFailed()istrue. - Throws:
IllegalStateException- IfisUserCreationFailed()isfalse.
-
isSuccess
public boolean isSuccess()- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.SUCCESS,falseotherwise.
-
success
Returns an instance ofMemberAddV2Resultthat has its tag set toMemberAddV2Result.Tag.SUCCESS.Describes a user that was successfully added to the team.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
MemberAddV2Resultwith its tag set toMemberAddV2Result.Tag.SUCCESS. - Throws:
IllegalArgumentException- ifvalueisnull.
-
getSuccessValue
Describes a user that was successfully added to the team.This instance must be tagged as
MemberAddV2Result.Tag.SUCCESS.- Returns:
- The
TeamMemberInfoV2value associated with this instance ifisSuccess()istrue. - Throws:
IllegalStateException- IfisSuccess()isfalse.
-
isOther
public boolean isOther()- Returns:
trueif this instance is tagged asMemberAddV2Result.Tag.OTHER,falseotherwise.
-
hashCode
public int hashCode() -
equals
-
toString
-
toStringMultiline
Returns a String representation of this object formatted for easier readability.The returned String may contain newlines.
- Returns:
- Formatted, multiline String representation of this object
-