Class Info |
|---|
public final class About extends GenericJson User information class, including the user name, storage quota, maximum size of a file that can be uploaded by the user, and whether the user needs to update the security policy. |
Type | Class Name and Description |
|---|---|
static final class | Declaration of the About.StorageQuota class, including the storage quota and usage. All fields are measured in bytes. |
Qualifier and Type | Method Name and Description |
|---|---|
Boolean | Checks whether a user needs to update the security policy. |
setNeedUpdate(boolean needUpdate) Sets whether a user needs to update the security policy. | |
String | Obtains the URL of the web page for updating the security policy. |
setUpdateUrl(String updateUrl) Sets the URL of the web page for updating the security policy. | |
String | Obtains the resource type. |
setCategory(String category) Sets the resource type. | |
Long | Obtains the maximum size of a file that can be uploaded, in bytes. |
setMaxFileUploadSize(Long maxFileUploadSize) Sets the maximum size of a file that can be uploaded, in bytes. | |
| Obtains a user's storage quota and usage, in bytes. | |
setStorageQuota(StorageQuota storageQuota) Sets a user's storage quota and usage, in bytes. | |
getUser() Obtains information about the user who has signed in. | |
| Sets information about the user who has signed in. | |
Long | Obtains the maximum thumbnail size, in bytes. |
setMaxThumbnailSize(Long maxThumbnailSize) Sets the maximum thumbnail size, in bytes. | |
set(String fieldName, Object value) Sets a custom attribute and its value. | |
clone() Clones an About object. |
Method |
|---|
public Boolean isNeedUpdate() Checks whether a user needs to update the security policy. |
Returns
Type | Description |
|---|---|
Boolean | Whether a user needs to update the security policy. The needUpdate field is optional, and the Drive.About.Get API may not return this field. |
Method |
|---|
public About setNeedUpdate(boolean needUpdate) Sets whether a user needs to update the security policy. |
Parameters
Name | Description |
|---|---|
needUpdate | Indicates whether to update the security policy for the user. true if the user needs to update the security policy; false otherwise. |
Returns
Type | Description |
|---|---|
About | An About object. |
Method |
|---|
public String getUpdateUrl() Obtains the URL of the web page for updating the security policy. |
Returns
Type | Description |
|---|---|
String | URL of the web page for updating the security policy. |
Method |
|---|
public About setUpdateUrl(String updateUrl) Sets the URL of the web page for updating the security policy. |
Parameters
Name | Description |
|---|---|
updateUrl | URL of the web page for updating the security policy. When the value of needUpdate is true, a URL is returned to the app. In this case, the app needs to call a browser to open the user authorization page. |
Returns
Type | Description |
|---|---|
About | An About object. |
Method |
|---|
public String getCategory() Obtains the resource type. |
Returns
Type | Description |
|---|---|
String | Resource type. |
Method |
|---|
public About setCategory(String category) Sets the resource type. |
Parameters
Name | Description |
|---|---|
category | Resource type, for example, drive#about. |
Returns
Type | Description |
|---|---|
About | An About object. |
Method |
|---|
public Long getMaxFileUploadSize() Obtains the maximum size of a file that can be uploaded, in bytes. |
Returns
Type | Description |
|---|---|
Long | Maximum size of a file that can be uploaded. |
Method |
|---|
public About setMaxFileUploadSize(Long maxFileUploadSize) Sets the maximum size of a file that can be uploaded, in bytes. |
Parameters
Name | Description |
|---|---|
maxFileUploadSize | Maximum size of a file that can be uploaded. |
Returns
Type | Description |
|---|---|
About | An About object. |
Method |
|---|
public About.StorageQuota getStorageQuota() Obtains a user's storage quota and usage, in bytes. |
Returns
Type | Description |
|---|---|
About.StorageQuota | An About.StorageQuota object. |
Method |
|---|
public About setStorageQuota(StorageQuota storageQuota) Sets a user's storage quota and usage, in bytes. |
Parameters
Name | Description |
|---|---|
storageQuota | Storage quota and usage of a user. |
Returns
Type | Description |
|---|---|
About | An About object. |
Method |
|---|
public User getUser() Obtains information about the user who has signed in. |
Returns
Type | Description |
|---|---|
User | A User object. |
Method |
|---|
public About setUser(User user) Sets information about the user who has signed in. |
Parameters
Name | Description |
|---|---|
user | Information about the user who has signed in. |
Returns
Type | Description |
|---|---|
About | An About object. |
Method |
|---|
public Long getMaxThumbnailSize() Obtains the maximum thumbnail size. |
Returns
Type | Description |
|---|---|
Long | Maximum thumbnail size, in bytes. |
Method |
|---|
public About setMaxThumbnailSize(Long maxThumbnailSize) Sets the maximum thumbnail size. |
Parameters
Name | Description |
|---|---|
maxThumbnailSize | Maximum thumbnail size to be set, in bytes. |
Returns
Type | Description |
|---|---|
About | An About object. |