Class UpdatePropertiesError
- java.lang.Object
-
- com.dropbox.core.v2.fileproperties.UpdatePropertiesError
-
public final class UpdatePropertiesError extends java.lang.ObjectThis class is a tagged union. Tagged unions instances are always associated to a specific tag. This means only one of theisAbc()methods will returntrue. You can usetag()to determine the tag associated with this instance.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classUpdatePropertiesError.SerializerFor internal use only.static classUpdatePropertiesError.TagDiscriminating tag type forUpdatePropertiesError.
-
Field Summary
Fields Modifier and Type Field Description static UpdatePropertiesErrorDOES_NOT_FIT_TEMPLATEOne or more of the supplied property fields does not conform to the template specifications.static UpdatePropertiesErrorDUPLICATE_PROPERTY_GROUPSThere are 2 or more property groups referring to the same templates in the input.static UpdatePropertiesErrorOTHERCatch-all used for unknown tag values returned by the Dropbox servers.static UpdatePropertiesErrorPROPERTY_FIELD_TOO_LARGEOne or more of the supplied property field values is too large.static UpdatePropertiesErrorRESTRICTED_CONTENTYou do not have permission to modify this template.static UpdatePropertiesErrorUNSUPPORTED_FOLDERThis folder cannot be tagged.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)LookupErrorgetPathValue()This instance must be tagged asUpdatePropertiesError.Tag.PATH.LookUpPropertiesErrorgetPropertyGroupLookupValue()This instance must be tagged asUpdatePropertiesError.Tag.PROPERTY_GROUP_LOOKUP.java.lang.StringgetTemplateNotFoundValue()Template does not exist for the given identifier.inthashCode()booleanisDoesNotFitTemplate()Returnstrueif this instance has the tagUpdatePropertiesError.Tag.DOES_NOT_FIT_TEMPLATE,falseotherwise.booleanisDuplicatePropertyGroups()Returnstrueif this instance has the tagUpdatePropertiesError.Tag.DUPLICATE_PROPERTY_GROUPS,falseotherwise.booleanisOther()booleanisPath()booleanisPropertyFieldTooLarge()Returnstrueif this instance has the tagUpdatePropertiesError.Tag.PROPERTY_FIELD_TOO_LARGE,falseotherwise.booleanisPropertyGroupLookup()Returnstrueif this instance has the tagUpdatePropertiesError.Tag.PROPERTY_GROUP_LOOKUP,falseotherwise.booleanisRestrictedContent()Returnstrueif this instance has the tagUpdatePropertiesError.Tag.RESTRICTED_CONTENT,falseotherwise.booleanisTemplateNotFound()Returnstrueif this instance has the tagUpdatePropertiesError.Tag.TEMPLATE_NOT_FOUND,falseotherwise.booleanisUnsupportedFolder()Returnstrueif this instance has the tagUpdatePropertiesError.Tag.UNSUPPORTED_FOLDER,falseotherwise.static UpdatePropertiesErrorpath(LookupError value)Returns an instance ofUpdatePropertiesErrorthat has its tag set toUpdatePropertiesError.Tag.PATH.static UpdatePropertiesErrorpropertyGroupLookup(LookUpPropertiesError value)Returns an instance ofUpdatePropertiesErrorthat has its tag set toUpdatePropertiesError.Tag.PROPERTY_GROUP_LOOKUP.UpdatePropertiesError.Tagtag()Returns the tag for this instance.static UpdatePropertiesErrortemplateNotFound(java.lang.String value)Returns an instance ofUpdatePropertiesErrorthat has its tag set toUpdatePropertiesError.Tag.TEMPLATE_NOT_FOUND.java.lang.StringtoString()java.lang.StringtoStringMultiline()Returns a String representation of this object formatted for easier readability.
-
-
-
Field Detail
-
RESTRICTED_CONTENT
public static final UpdatePropertiesError RESTRICTED_CONTENT
You do not have permission to modify this template.
-
OTHER
public static final UpdatePropertiesError 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.
-
UNSUPPORTED_FOLDER
public static final UpdatePropertiesError UNSUPPORTED_FOLDER
This folder cannot be tagged. Tagging folders is not supported for team-owned templates.
-
PROPERTY_FIELD_TOO_LARGE
public static final UpdatePropertiesError PROPERTY_FIELD_TOO_LARGE
One or more of the supplied property field values is too large.
-
DOES_NOT_FIT_TEMPLATE
public static final UpdatePropertiesError DOES_NOT_FIT_TEMPLATE
One or more of the supplied property fields does not conform to the template specifications.
-
DUPLICATE_PROPERTY_GROUPS
public static final UpdatePropertiesError DUPLICATE_PROPERTY_GROUPS
There are 2 or more property groups referring to the same templates in the input.
-
-
Method Detail
-
tag
public UpdatePropertiesError.Tag 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 thisUpdatePropertiesError.- Returns:
- the tag for this instance.
-
isTemplateNotFound
public boolean isTemplateNotFound()
Returnstrueif this instance has the tagUpdatePropertiesError.Tag.TEMPLATE_NOT_FOUND,falseotherwise.- Returns:
trueif this instance is tagged asUpdatePropertiesError.Tag.TEMPLATE_NOT_FOUND,falseotherwise.
-
templateNotFound
public static UpdatePropertiesError templateNotFound(java.lang.String value)
Returns an instance ofUpdatePropertiesErrorthat has its tag set toUpdatePropertiesError.Tag.TEMPLATE_NOT_FOUND.Template does not exist for the given identifier.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
UpdatePropertiesErrorwith its tag set toUpdatePropertiesError.Tag.TEMPLATE_NOT_FOUND. - Throws:
java.lang.IllegalArgumentException- ifvalueis shorter than 1, does not match pattern "(/|ptid:).*", or isnull.
-
getTemplateNotFoundValue
public java.lang.String getTemplateNotFoundValue()
Template does not exist for the given identifier.This instance must be tagged as
UpdatePropertiesError.Tag.TEMPLATE_NOT_FOUND.- Returns:
- The
Stringvalue associated with this instance ifisTemplateNotFound()istrue. - Throws:
java.lang.IllegalStateException- IfisTemplateNotFound()isfalse.
-
isRestrictedContent
public boolean isRestrictedContent()
Returnstrueif this instance has the tagUpdatePropertiesError.Tag.RESTRICTED_CONTENT,falseotherwise.- Returns:
trueif this instance is tagged asUpdatePropertiesError.Tag.RESTRICTED_CONTENT,falseotherwise.
-
isOther
public boolean isOther()
- Returns:
trueif this instance is tagged asUpdatePropertiesError.Tag.OTHER,falseotherwise.
-
isPath
public boolean isPath()
- Returns:
trueif this instance is tagged asUpdatePropertiesError.Tag.PATH,falseotherwise.
-
path
public static UpdatePropertiesError path(LookupError value)
Returns an instance ofUpdatePropertiesErrorthat has its tag set toUpdatePropertiesError.Tag.PATH.None
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
UpdatePropertiesErrorwith its tag set toUpdatePropertiesError.Tag.PATH. - Throws:
java.lang.IllegalArgumentException- ifvalueisnull.
-
getPathValue
public LookupError getPathValue()
This instance must be tagged asUpdatePropertiesError.Tag.PATH.- Returns:
- The
LookupErrorvalue associated with this instance ifisPath()istrue. - Throws:
java.lang.IllegalStateException- IfisPath()isfalse.
-
isUnsupportedFolder
public boolean isUnsupportedFolder()
Returnstrueif this instance has the tagUpdatePropertiesError.Tag.UNSUPPORTED_FOLDER,falseotherwise.- Returns:
trueif this instance is tagged asUpdatePropertiesError.Tag.UNSUPPORTED_FOLDER,falseotherwise.
-
isPropertyFieldTooLarge
public boolean isPropertyFieldTooLarge()
Returnstrueif this instance has the tagUpdatePropertiesError.Tag.PROPERTY_FIELD_TOO_LARGE,falseotherwise.- Returns:
trueif this instance is tagged asUpdatePropertiesError.Tag.PROPERTY_FIELD_TOO_LARGE,falseotherwise.
-
isDoesNotFitTemplate
public boolean isDoesNotFitTemplate()
Returnstrueif this instance has the tagUpdatePropertiesError.Tag.DOES_NOT_FIT_TEMPLATE,falseotherwise.- Returns:
trueif this instance is tagged asUpdatePropertiesError.Tag.DOES_NOT_FIT_TEMPLATE,falseotherwise.
-
isDuplicatePropertyGroups
public boolean isDuplicatePropertyGroups()
Returnstrueif this instance has the tagUpdatePropertiesError.Tag.DUPLICATE_PROPERTY_GROUPS,falseotherwise.- Returns:
trueif this instance is tagged asUpdatePropertiesError.Tag.DUPLICATE_PROPERTY_GROUPS,falseotherwise.
-
isPropertyGroupLookup
public boolean isPropertyGroupLookup()
Returnstrueif this instance has the tagUpdatePropertiesError.Tag.PROPERTY_GROUP_LOOKUP,falseotherwise.- Returns:
trueif this instance is tagged asUpdatePropertiesError.Tag.PROPERTY_GROUP_LOOKUP,falseotherwise.
-
propertyGroupLookup
public static UpdatePropertiesError propertyGroupLookup(LookUpPropertiesError value)
Returns an instance ofUpdatePropertiesErrorthat has its tag set toUpdatePropertiesError.Tag.PROPERTY_GROUP_LOOKUP.None
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
UpdatePropertiesErrorwith its tag set toUpdatePropertiesError.Tag.PROPERTY_GROUP_LOOKUP. - Throws:
java.lang.IllegalArgumentException- ifvalueisnull.
-
getPropertyGroupLookupValue
public LookUpPropertiesError getPropertyGroupLookupValue()
This instance must be tagged asUpdatePropertiesError.Tag.PROPERTY_GROUP_LOOKUP.- Returns:
- The
LookUpPropertiesErrorvalue associated with this instance ifisPropertyGroupLookup()istrue. - Throws:
java.lang.IllegalStateException- IfisPropertyGroupLookup()isfalse.
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
toStringMultiline
public java.lang.String 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
-
-