Package com.dropbox.core.v2.files
Class AlphaUploadBuilder
- java.lang.Object
- 
- com.dropbox.core.v2.DbxUploadStyleBuilder<FileMetadata,UploadError,UploadErrorException>
- 
- com.dropbox.core.v2.files.AlphaUploadBuilder
 
 
- 
 public class AlphaUploadBuilder extends DbxUploadStyleBuilder<FileMetadata,UploadError,UploadErrorException> The request builder returned byDbxUserFilesRequests.alphaUploadBuilder(java.lang.String).Use this class to set optional request parameters and complete the request. 
- 
- 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description AlphaUploadUploaderstart()Begins the upload request using this builder's request parameters and returns aDbxUploaderfor writing the request body.AlphaUploadBuilderwithAutorename(java.lang.Boolean autorename)Set value for optional field.AlphaUploadBuilderwithClientModified(java.util.Date clientModified)Set value for optional field.AlphaUploadBuilderwithContentHash(java.lang.String contentHash)Set value for optional field.AlphaUploadBuilderwithMode(WriteMode mode)Set value for optional field.AlphaUploadBuilderwithMute(java.lang.Boolean mute)Set value for optional field.AlphaUploadBuilderwithPropertyGroups(java.util.List<PropertyGroup> propertyGroups)Set value for optional field.AlphaUploadBuilderwithStrictConflict(java.lang.Boolean strictConflict)Set value for optional field.- 
Methods inherited from class com.dropbox.core.v2.DbxUploadStyleBuilderuploadAndFinish, uploadAndFinish, uploadAndFinish, uploadAndFinish
 
- 
 
- 
- 
- 
Method Detail- 
withModepublic AlphaUploadBuilder withMode(WriteMode mode) Set value for optional field.If left unset or set to null, defaults toWriteMode.ADD.- Parameters:
- mode- Selects what to do if the file already exists. Must not be- null. Defaults to- WriteMode.ADDwhen set to- null.
- Returns:
- this builder
- Throws:
- java.lang.IllegalArgumentException- If any argument does not meet its preconditions.
 
 - 
withAutorenamepublic AlphaUploadBuilder withAutorename(java.lang.Boolean autorename) Set value for optional field.If left unset or set to null, defaults tofalse.- Parameters:
- autorename- If there's a conflict, as determined by- CommitInfo.getMode(), have the Dropbox server try to autorename the file to avoid conflict. Defaults to- falsewhen set to- null.
- Returns:
- this builder
 
 - 
withClientModifiedpublic AlphaUploadBuilder withClientModified(java.util.Date clientModified) Set value for optional field.- Parameters:
- clientModified- The value to store as the- CommitInfo.getClientModified()timestamp. Dropbox automatically records the time at which the file was written to the Dropbox servers. It can also record an additional timestamp, provided by Dropbox desktop clients, mobile clients, and API apps of when the file was actually created or modified.
- Returns:
- this builder
 
 - 
withMutepublic AlphaUploadBuilder withMute(java.lang.Boolean mute) Set value for optional field.If left unset or set to null, defaults tofalse.- Parameters:
- mute- Normally, users are made aware of any file modifications in their Dropbox account via notifications in the client software. If- true, this tells the clients that this modification shouldn't result in a user notification. Defaults to- falsewhen set to- null.
- Returns:
- this builder
 
 - 
withPropertyGroupspublic AlphaUploadBuilder withPropertyGroups(java.util.List<PropertyGroup> propertyGroups) Set value for optional field.- Parameters:
- propertyGroups- List of custom properties to add to file. Must not contain a- nullitem.
- Returns:
- this builder
- Throws:
- java.lang.IllegalArgumentException- If any argument does not meet its preconditions.
 
 - 
withStrictConflictpublic AlphaUploadBuilder withStrictConflict(java.lang.Boolean strictConflict) Set value for optional field.If left unset or set to null, defaults tofalse.- Parameters:
- strictConflict- Be more strict about how each- WriteModedetects conflict. For example, always return a conflict error when- CommitInfo.getMode()=- WriteMode.getUpdateValue()and the given "rev" doesn't match the existing file's "rev", even if the existing file has been deleted. This also forces a conflict even when the target path refers to a file with identical contents. Defaults to- falsewhen set to- null.
- Returns:
- this builder
 
 - 
withContentHashpublic AlphaUploadBuilder withContentHash(java.lang.String contentHash) Set value for optional field.- Parameters:
- contentHash- A hash of the file content uploaded in this call. If provided and the uploaded content does not match this hash, an error will be returned. For more information see our Content hash page. Must have length of at least 64 and have length of at most 64.
- Returns:
- this builder
- Throws:
- java.lang.IllegalArgumentException- If any argument does not meet its preconditions.
 
 - 
startpublic AlphaUploadUploader start() throws UploadErrorException, DbxException Description copied from class:DbxUploadStyleBuilderBegins the upload request using this builder's request parameters and returns aDbxUploaderfor writing the request body. Callers can complete the request by writing the upload data to theOutputStreamreturned byDbxUploader.getOutputStream()and receiving the server response usingDbxUploader.finish(). SeeDbxUploadStyleBuilder.uploadAndFinish(java.io.InputStream)convenience method for a simpler way to complete the request.- Specified by:
- startin class- DbxUploadStyleBuilder<FileMetadata,UploadError,UploadErrorException>
- Returns:
- DbxUploaderused to upload data and complete the request
- Throws:
- DbxException- if an error occursing initializing the request
- UploadErrorException
 
 
- 
 
-