public final class File extends GenericJson
This is the Java data model class that specifies how to parse/serialize into the JSON that is transmitted over HTTP when working with the Drive API. For a detailed explanation see: http://code.google.com/p/google-http-java-client/wiki/JSON
Modifier and Type | Class and Description |
---|---|
static class |
File.IndexableText
Indexable text attributes for the file (can only be written)
|
static class |
File.Labels
Labels for the file.
|
static class |
File.ParentsCollection
Model definition for FileParentsCollection.
|
GenericData.Flags
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
Constructor and Description |
---|
File() |
Modifier and Type | Method and Description |
---|---|
File |
clone() |
DateTime |
getCreatedDate()
Create time for this file (formatted ISO8601 timestamp).
|
String |
getDescription()
A short description of the file
|
String |
getDownloadUrl()
Short term download URL for the file.
|
String |
getEtag()
ETag of the file.
|
String |
getFileExtension()
The file extension used when downloading this file.
|
Long |
getFileSize()
The size of the file in bytes.
|
String |
getId()
The id of the file.
|
File.IndexableText |
getIndexableText()
Indexable text attributes for the file (can only be written)
|
String |
getKind()
The type of file.
|
File.Labels |
getLabels()
Labels for the file.
|
DateTime |
getLastViewedDate()
Last time this file was viewed by the user (formatted RFC 3339 timestamp).
|
String |
getMd5Checksum()
An MD5 checksum for the content of this file.
|
String |
getMimeType()
The mimetype of the file
|
DateTime |
getModifiedByMeDate()
Last time this file was modified by the user (formatted RFC 3339 timestamp).
|
DateTime |
getModifiedDate()
Last time this file was modified by anyone (formatted RFC 3339 timestamp).
|
List<File.ParentsCollection> |
getParentsCollection()
Collection of parent folders which contain this file.
|
String |
getSelfLink()
A link back to this file.
|
String |
getTitle()
The title of this file.
|
Permission |
getUserPermission()
The permissions for the authenticated user on this file.
|
File |
set(String fieldName,
Object value) |
File |
setCreatedDate(DateTime createdDate)
Create time for this file (formatted ISO8601 timestamp).
|
File |
setDescription(String description)
A short description of the file
|
File |
setDownloadUrl(String downloadUrl)
Short term download URL for the file.
|
File |
setEtag(String etag)
ETag of the file.
|
File |
setFileExtension(String fileExtension)
The file extension used when downloading this file.
|
File |
setFileSize(Long fileSize)
The size of the file in bytes.
|
File |
setId(String id)
The id of the file.
|
File |
setIndexableText(File.IndexableText indexableText)
Indexable text attributes for the file (can only be written)
|
File |
setKind(String kind)
The type of file.
|
File |
setLabels(File.Labels labels)
Labels for the file.
|
File |
setLastViewedDate(DateTime lastViewedDate)
Last time this file was viewed by the user (formatted RFC 3339 timestamp).
|
File |
setMd5Checksum(String md5Checksum)
An MD5 checksum for the content of this file.
|
File |
setMimeType(String mimeType)
The mimetype of the file
|
File |
setModifiedByMeDate(DateTime modifiedByMeDate)
Last time this file was modified by the user (formatted RFC 3339 timestamp).
|
File |
setModifiedDate(DateTime modifiedDate)
Last time this file was modified by anyone (formatted RFC 3339 timestamp).
|
File |
setParentsCollection(List<File.ParentsCollection> parentsCollection)
Collection of parent folders which contain this file.
|
File |
setSelfLink(String selfLink)
A link back to this file.
|
File |
setTitle(String title)
The title of this file.
|
File |
setUserPermission(Permission userPermission)
The permissions for the authenticated user on this file.
|
getFactory, setFactory, toPrettyString, toString
entrySet, get, getClassInfo, getUnknownKeys, put, putAll, remove, setUnknownKeys
clear, containsKey, containsValue, equals, hashCode, isEmpty, keySet, size, values
public DateTime getCreatedDate()
null
for nonepublic File setCreatedDate(DateTime createdDate)
createdDate
- createdDate or null
for nonepublic String getDescription()
null
for nonepublic File setDescription(String description)
description
- description or null
for nonepublic String getDownloadUrl()
null
for nonepublic File setDownloadUrl(String downloadUrl)
downloadUrl
- downloadUrl or null
for nonepublic String getEtag()
null
for nonepublic String getFileExtension()
null
for nonepublic File setFileExtension(String fileExtension)
fileExtension
- fileExtension or null
for nonepublic Long getFileSize()
null
for nonepublic File setFileSize(Long fileSize)
fileSize
- fileSize or null
for nonepublic String getId()
null
for nonepublic File.IndexableText getIndexableText()
null
for nonepublic File setIndexableText(File.IndexableText indexableText)
indexableText
- indexableText or null
for nonepublic String getKind()
null
for nonepublic File setKind(String kind)
kind
- kind or null
for nonepublic File.Labels getLabels()
null
for nonepublic File setLabels(File.Labels labels)
labels
- labels or null
for nonepublic DateTime getLastViewedDate()
null
for nonepublic File setLastViewedDate(DateTime lastViewedDate)
lastViewedDate
- lastViewedDate or null
for nonepublic String getMd5Checksum()
null
for nonepublic File setMd5Checksum(String md5Checksum)
md5Checksum
- md5Checksum or null
for nonepublic String getMimeType()
null
for nonepublic File setMimeType(String mimeType)
mimeType
- mimeType or null
for nonepublic DateTime getModifiedByMeDate()
null
for nonepublic File setModifiedByMeDate(DateTime modifiedByMeDate)
modifiedByMeDate
- modifiedByMeDate or null
for nonepublic DateTime getModifiedDate()
null
for nonepublic File setModifiedDate(DateTime modifiedDate)
modifiedDate
- modifiedDate or null
for nonepublic List<File.ParentsCollection> getParentsCollection()
null
for nonepublic File setParentsCollection(List<File.ParentsCollection> parentsCollection)
parentsCollection
- parentsCollection or null
for nonepublic String getSelfLink()
null
for nonepublic File setSelfLink(String selfLink)
selfLink
- selfLink or null
for nonepublic String getTitle()
null
for nonepublic File setTitle(String title)
title
- title or null
for nonepublic Permission getUserPermission()
null
for nonepublic File setUserPermission(Permission userPermission)
userPermission
- userPermission or null
for nonepublic File set(String fieldName, Object value)
set
in class GenericJson
public File clone()
clone
in class GenericJson