Class UploadSessionFinishError
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 ClassesModifier and TypeClassDescriptionstatic enumDiscriminating tag type forUploadSessionFinishError. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final UploadSessionFinishErrorUploading data not allowed when finishing concurrent upload session.static final UploadSessionFinishErrorNot all pieces of data were uploaded before trying to finish the session.static final UploadSessionFinishErrorConcurrent upload sessions need to be closed before finishing.static final UploadSessionFinishErrorThe content received by the Dropbox server in this call does not match the provided content hash.static final UploadSessionFinishErrorThe file is required to be encrypted, which is not supported in our public API.static final UploadSessionFinishErrorCatch-all used for unknown tag values returned by the Dropbox servers.static final UploadSessionFinishErrorThe request payload must be at most 150 MiB.static final UploadSessionFinishErrorField is deprecated.static final UploadSessionFinishErrorThere are too many write operations happening in the user's Dropbox. -
Method Summary
Modifier and TypeMethodDescriptionbooleanThe session arguments are incorrect; the value explains the reason.Unable to save the uploaded contents to a file.The supplied property group is invalid.inthashCode()booleanReturnstrueif this instance has the tagUploadSessionFinishError.Tag.CONCURRENT_SESSION_DATA_NOT_ALLOWED,falseotherwise.booleanReturnstrueif this instance has the tagUploadSessionFinishError.Tag.CONCURRENT_SESSION_MISSING_DATA,falseotherwise.booleanReturnstrueif this instance has the tagUploadSessionFinishError.Tag.CONCURRENT_SESSION_NOT_CLOSED,falseotherwise.booleanReturnstrueif this instance has the tagUploadSessionFinishError.Tag.CONTENT_HASH_MISMATCH,falseotherwise.booleanReturnstrueif this instance has the tagUploadSessionFinishError.Tag.ENCRYPTION_NOT_SUPPORTED,falseotherwise.booleanReturnstrueif this instance has the tagUploadSessionFinishError.Tag.LOOKUP_FAILED,falseotherwise.booleanisOther()booleanisPath()booleanReturnstrueif this instance has the tagUploadSessionFinishError.Tag.PAYLOAD_TOO_LARGE,falseotherwise.booleanReturnstrueif this instance has the tagUploadSessionFinishError.Tag.PROPERTIES_ERROR,falseotherwise.booleanReturnstrueif this instance has the tagUploadSessionFinishError.Tag.TOO_MANY_SHARED_FOLDER_TARGETS,falseotherwise.booleanReturnstrueif this instance has the tagUploadSessionFinishError.Tag.TOO_MANY_WRITE_OPERATIONS,falseotherwise.static UploadSessionFinishErrorReturns an instance ofUploadSessionFinishErrorthat has its tag set toUploadSessionFinishError.Tag.LOOKUP_FAILED.static UploadSessionFinishErrorpath(WriteError value) Returns an instance ofUploadSessionFinishErrorthat has its tag set toUploadSessionFinishError.Tag.PATH.static UploadSessionFinishErrorReturns an instance ofUploadSessionFinishErrorthat has its tag set toUploadSessionFinishError.Tag.PROPERTIES_ERROR.tag()Returns the tag for this instance.toString()Returns a String representation of this object formatted for easier readability.
-
Field Details
-
TOO_MANY_SHARED_FOLDER_TARGETS
Field is deprecated. The batch request commits files into too many different shared folders. Please limit your batch request to files contained in a single shared folder. -
TOO_MANY_WRITE_OPERATIONS
There are too many write operations happening in the user's Dropbox. You should retry uploading this file. -
CONCURRENT_SESSION_DATA_NOT_ALLOWED
Uploading data not allowed when finishing concurrent upload session. -
CONCURRENT_SESSION_NOT_CLOSED
Concurrent upload sessions need to be closed before finishing. -
CONCURRENT_SESSION_MISSING_DATA
Not all pieces of data were uploaded before trying to finish the session. -
PAYLOAD_TOO_LARGE
The request payload must be at most 150 MiB. -
CONTENT_HASH_MISMATCH
The content received by the Dropbox server in this call does not match the provided content hash. -
ENCRYPTION_NOT_SUPPORTED
The file is required to be encrypted, which is not supported in our public API. -
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 thisUploadSessionFinishError.If a tag returned by the server is unrecognized by this SDK, the
UploadSessionFinishError.Tag.OTHERvalue will be used.- Returns:
- the tag for this instance.
-
isLookupFailed
public boolean isLookupFailed()Returnstrueif this instance has the tagUploadSessionFinishError.Tag.LOOKUP_FAILED,falseotherwise.- Returns:
trueif this instance is tagged asUploadSessionFinishError.Tag.LOOKUP_FAILED,falseotherwise.
-
lookupFailed
Returns an instance ofUploadSessionFinishErrorthat has its tag set toUploadSessionFinishError.Tag.LOOKUP_FAILED.The session arguments are incorrect; the value explains the reason.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
UploadSessionFinishErrorwith its tag set toUploadSessionFinishError.Tag.LOOKUP_FAILED. - Throws:
IllegalArgumentException- ifvalueisnull.
-
getLookupFailedValue
The session arguments are incorrect; the value explains the reason.This instance must be tagged as
UploadSessionFinishError.Tag.LOOKUP_FAILED.- Returns:
- The
UploadSessionLookupErrorvalue associated with this instance ifisLookupFailed()istrue. - Throws:
IllegalStateException- IfisLookupFailed()isfalse.
-
isPath
public boolean isPath()- Returns:
trueif this instance is tagged asUploadSessionFinishError.Tag.PATH,falseotherwise.
-
path
Returns an instance ofUploadSessionFinishErrorthat has its tag set toUploadSessionFinishError.Tag.PATH.Unable to save the uploaded contents to a file. Data has already been appended to the upload session. Please retry with empty data body and updated offset.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
UploadSessionFinishErrorwith its tag set toUploadSessionFinishError.Tag.PATH. - Throws:
IllegalArgumentException- ifvalueisnull.
-
getPathValue
Unable to save the uploaded contents to a file. Data has already been appended to the upload session. Please retry with empty data body and updated offset.This instance must be tagged as
UploadSessionFinishError.Tag.PATH.- Returns:
- The
WriteErrorvalue associated with this instance ifisPath()istrue. - Throws:
IllegalStateException- IfisPath()isfalse.
-
isPropertiesError
public boolean isPropertiesError()Returnstrueif this instance has the tagUploadSessionFinishError.Tag.PROPERTIES_ERROR,falseotherwise.- Returns:
trueif this instance is tagged asUploadSessionFinishError.Tag.PROPERTIES_ERROR,falseotherwise.
-
propertiesError
Returns an instance ofUploadSessionFinishErrorthat has its tag set toUploadSessionFinishError.Tag.PROPERTIES_ERROR.The supplied property group is invalid. The file has uploaded without property groups.
- Parameters:
value- value to assign to this instance.- Returns:
- Instance of
UploadSessionFinishErrorwith its tag set toUploadSessionFinishError.Tag.PROPERTIES_ERROR. - Throws:
IllegalArgumentException- ifvalueisnull.
-
getPropertiesErrorValue
The supplied property group is invalid. The file has uploaded without property groups.This instance must be tagged as
UploadSessionFinishError.Tag.PROPERTIES_ERROR.- Returns:
- The
InvalidPropertyGroupErrorvalue associated with this instance ifisPropertiesError()istrue. - Throws:
IllegalStateException- IfisPropertiesError()isfalse.
-
isTooManyWriteOperations
public boolean isTooManyWriteOperations()Returnstrueif this instance has the tagUploadSessionFinishError.Tag.TOO_MANY_WRITE_OPERATIONS,falseotherwise.- Returns:
trueif this instance is tagged asUploadSessionFinishError.Tag.TOO_MANY_WRITE_OPERATIONS,falseotherwise.
-
isConcurrentSessionDataNotAllowed
public boolean isConcurrentSessionDataNotAllowed()Returnstrueif this instance has the tagUploadSessionFinishError.Tag.CONCURRENT_SESSION_DATA_NOT_ALLOWED,falseotherwise.- Returns:
trueif this instance is tagged asUploadSessionFinishError.Tag.CONCURRENT_SESSION_DATA_NOT_ALLOWED,falseotherwise.
-
isConcurrentSessionNotClosed
public boolean isConcurrentSessionNotClosed()Returnstrueif this instance has the tagUploadSessionFinishError.Tag.CONCURRENT_SESSION_NOT_CLOSED,falseotherwise.- Returns:
trueif this instance is tagged asUploadSessionFinishError.Tag.CONCURRENT_SESSION_NOT_CLOSED,falseotherwise.
-
isConcurrentSessionMissingData
public boolean isConcurrentSessionMissingData()Returnstrueif this instance has the tagUploadSessionFinishError.Tag.CONCURRENT_SESSION_MISSING_DATA,falseotherwise.- Returns:
trueif this instance is tagged asUploadSessionFinishError.Tag.CONCURRENT_SESSION_MISSING_DATA,falseotherwise.
-
isPayloadTooLarge
public boolean isPayloadTooLarge()Returnstrueif this instance has the tagUploadSessionFinishError.Tag.PAYLOAD_TOO_LARGE,falseotherwise.- Returns:
trueif this instance is tagged asUploadSessionFinishError.Tag.PAYLOAD_TOO_LARGE,falseotherwise.
-
isContentHashMismatch
public boolean isContentHashMismatch()Returnstrueif this instance has the tagUploadSessionFinishError.Tag.CONTENT_HASH_MISMATCH,falseotherwise.- Returns:
trueif this instance is tagged asUploadSessionFinishError.Tag.CONTENT_HASH_MISMATCH,falseotherwise.
-
isEncryptionNotSupported
public boolean isEncryptionNotSupported()Returnstrueif this instance has the tagUploadSessionFinishError.Tag.ENCRYPTION_NOT_SUPPORTED,falseotherwise.- Returns:
trueif this instance is tagged asUploadSessionFinishError.Tag.ENCRYPTION_NOT_SUPPORTED,falseotherwise.
-
isOther
public boolean isOther()- Returns:
trueif this instance is tagged asUploadSessionFinishError.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
-