public class FileRequest
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
FileRequest.Builder
Builder for
FileRequest . |
Modifier and Type | Field and Description |
---|---|
protected java.util.Date |
created |
protected FileRequestDeadline |
deadline |
protected java.lang.String |
destination |
protected long |
fileCount |
protected java.lang.String |
id |
protected boolean |
isOpen |
protected java.lang.String |
title |
protected java.lang.String |
url |
Constructor and Description |
---|
FileRequest(java.lang.String id,
java.lang.String url,
java.lang.String title,
java.util.Date created,
boolean isOpen,
long fileCount)
A file request for
receiving files into the user's Dropbox account.
|
FileRequest(java.lang.String id,
java.lang.String url,
java.lang.String title,
java.util.Date created,
boolean isOpen,
long fileCount,
java.lang.String destination,
FileRequestDeadline deadline)
A file request for
receiving files into the user's Dropbox account.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
java.util.Date |
getCreated()
When this file request was created.
|
FileRequestDeadline |
getDeadline()
The deadline for this file request.
|
java.lang.String |
getDestination()
The path of the folder in the Dropbox where uploaded files will be sent.
|
long |
getFileCount()
The number of files this file request has received.
|
java.lang.String |
getId()
The ID of the file request.
|
boolean |
getIsOpen()
Whether or not the file request is open.
|
java.lang.String |
getTitle()
The title of the file request.
|
java.lang.String |
getUrl()
The URL of the file request.
|
int |
hashCode() |
static FileRequest.Builder |
newBuilder(java.lang.String id,
java.lang.String url,
java.lang.String title,
java.util.Date created,
boolean isOpen,
long fileCount)
Returns a new builder for creating an instance of this class.
|
java.lang.String |
toString() |
java.lang.String |
toStringMultiline()
Returns a String representation of this object formatted for easier
readability.
|
protected final java.lang.String id
protected final java.lang.String url
protected final java.lang.String title
protected final java.lang.String destination
protected final java.util.Date created
protected final FileRequestDeadline deadline
protected final boolean isOpen
protected final long fileCount
public FileRequest(java.lang.String id, java.lang.String url, java.lang.String title, java.util.Date created, boolean isOpen, long fileCount, java.lang.String destination, FileRequestDeadline deadline)
Use newBuilder
to create instances of this class without
specifying values for all optional fields.
id
- The ID of the file request. Must have length of at least 1,
match pattern "[-_0-9a-zA-Z]+
", and not be null
.url
- The URL of the file request. Must have length of at least 1
and not be null
.title
- The title of the file request. Must have length of at least
1 and not be null
.created
- When this file request was created. Must not be null
.isOpen
- Whether or not the file request is open. If the file
request is closed, it will not accept any more file submissions.fileCount
- The number of files this file request has received.destination
- The path of the folder in the Dropbox where uploaded
files will be sent. This can be null
if the destination was
removed. For apps with the app folder permission, this will be
relative to the app folder. Must match pattern "/(.|[\\r\\n])*
".deadline
- The deadline for this file request. Only set if the
request has a deadline.java.lang.IllegalArgumentException
- If any argument does not meet its
preconditions.public FileRequest(java.lang.String id, java.lang.String url, java.lang.String title, java.util.Date created, boolean isOpen, long fileCount)
The default values for unset fields will be used.
id
- The ID of the file request. Must have length of at least 1,
match pattern "[-_0-9a-zA-Z]+
", and not be null
.url
- The URL of the file request. Must have length of at least 1
and not be null
.title
- The title of the file request. Must have length of at least
1 and not be null
.created
- When this file request was created. Must not be null
.isOpen
- Whether or not the file request is open. If the file
request is closed, it will not accept any more file submissions.fileCount
- The number of files this file request has received.java.lang.IllegalArgumentException
- If any argument does not meet its
preconditions.public java.lang.String getId()
null
.public java.lang.String getUrl()
null
.public java.lang.String getTitle()
null
.public java.util.Date getCreated()
null
.public boolean getIsOpen()
public long getFileCount()
public java.lang.String getDestination()
null
if the destination was removed. For apps with
the app folder permission, this will be relative to the app folder.null
if not present.public FileRequestDeadline getDeadline()
null
if not present.public static FileRequest.Builder newBuilder(java.lang.String id, java.lang.String url, java.lang.String title, java.util.Date created, boolean isOpen, long fileCount)
id
- The ID of the file request. Must have length of at least 1,
match pattern "[-_0-9a-zA-Z]+
", and not be null
.url
- The URL of the file request. Must have length of at least 1
and not be null
.title
- The title of the file request. Must have length of at least
1 and not be null
.created
- When this file request was created. Must not be null
.isOpen
- Whether or not the file request is open. If the file
request is closed, it will not accept any more file submissions.fileCount
- The number of files this file request has received.java.lang.IllegalArgumentException
- If any argument does not meet its
preconditions.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.