target.apidocs.com.google.api.services.drive.model.Drive.html Maven / Gradle / Ivy
Drive (Google Drive API v2-rev20240809-2.0.0)
com.google.api.services.drive.model
Class Drive
- java.lang.Object
-
- java.util.AbstractMap<String,Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.json.GenericJson
-
- com.google.api.services.drive.model.Drive
-
public final class Drive
extends com.google.api.client.json.GenericJson
Representation of a shared drive. Some resource methods (such as `drives.update`) require a
`driveId`. Use the `drives.list` method to retrieve the ID for a shared drive.
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 Google Drive API. For a detailed explanation see:
https://developers.google.com/api-client-library/java/google-http-java-client/json
- Author:
- Google, Inc.
-
-
Nested Class Summary
Nested Classes
Modifier and Type
Class and Description
static class
Drive.BackgroundImageFile
An image file and cropping parameters from which a background image for this shared drive is set.
static class
Drive.Capabilities
Output only.
static class
Drive.Restrictions
A set of restrictions that apply to this shared drive or items inside this shared drive.
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
com.google.api.client.util.GenericData.Flags
-
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
-
Constructor Summary
Constructors
Constructor and Description
Drive()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
Drive
clone()
Drive.BackgroundImageFile
getBackgroundImageFile()
An image file and cropping parameters from which a background image for this shared drive is
set.
String
getBackgroundImageLink()
Output only.
Drive.Capabilities
getCapabilities()
Output only.
String
getColorRgb()
The color of this shared drive as an RGB hex string.
com.google.api.client.util.DateTime
getCreatedDate()
The time at which the shared drive was created (RFC 3339 date-time).
Boolean
getHidden()
Whether the shared drive is hidden from default view.
String
getId()
Output only.
String
getKind()
Output only.
String
getName()
The name of this shared drive.
String
getOrgUnitId()
Output only.
Drive.Restrictions
getRestrictions()
A set of restrictions that apply to this shared drive or items inside this shared drive.
String
getThemeId()
The ID of the theme from which the background image and color will be set.
Drive
set(String fieldName,
Object value)
Drive
setBackgroundImageFile(Drive.BackgroundImageFile backgroundImageFile)
An image file and cropping parameters from which a background image for this shared drive is
set.
Drive
setBackgroundImageLink(String backgroundImageLink)
Output only.
Drive
setCapabilities(Drive.Capabilities capabilities)
Output only.
Drive
setColorRgb(String colorRgb)
The color of this shared drive as an RGB hex string.
Drive
setCreatedDate(com.google.api.client.util.DateTime createdDate)
The time at which the shared drive was created (RFC 3339 date-time).
Drive
setHidden(Boolean hidden)
Whether the shared drive is hidden from default view.
Drive
setId(String id)
Output only.
Drive
setKind(String kind)
Output only.
Drive
setName(String name)
The name of this shared drive.
Drive
setOrgUnitId(String orgUnitId)
Output only.
Drive
setRestrictions(Drive.Restrictions restrictions)
A set of restrictions that apply to this shared drive or items inside this shared drive.
Drive
setThemeId(String themeId)
The ID of the theme from which the background image and color will be set.
-
Methods inherited from class com.google.api.client.json.GenericJson
getFactory, setFactory, toPrettyString, toString
-
Methods inherited from class com.google.api.client.util.GenericData
entrySet, equals, get, getClassInfo, getUnknownKeys, hashCode, put, putAll, remove, setUnknownKeys
-
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, isEmpty, keySet, size, values
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
-
Method Detail
-
getBackgroundImageFile
public Drive.BackgroundImageFile getBackgroundImageFile()
An image file and cropping parameters from which a background image for this shared drive is
set. This is a write only field; it can only be set on `drive.drives.update` requests that
don't set `themeId`. When specified, all fields of the `backgroundImageFile` must be set.
- Returns:
- value or
null
for none
-
setBackgroundImageFile
public Drive setBackgroundImageFile(Drive.BackgroundImageFile backgroundImageFile)
An image file and cropping parameters from which a background image for this shared drive is
set. This is a write only field; it can only be set on `drive.drives.update` requests that
don't set `themeId`. When specified, all fields of the `backgroundImageFile` must be set.
- Parameters:
backgroundImageFile
- backgroundImageFile or null
for none
-
getBackgroundImageLink
public String getBackgroundImageLink()
Output only. A short-lived link to this shared drive's background image.
- Returns:
- value or
null
for none
-
setBackgroundImageLink
public Drive setBackgroundImageLink(String backgroundImageLink)
Output only. A short-lived link to this shared drive's background image.
- Parameters:
backgroundImageLink
- backgroundImageLink or null
for none
-
getCapabilities
public Drive.Capabilities getCapabilities()
Output only. Capabilities the current user has on this shared drive.
- Returns:
- value or
null
for none
-
setCapabilities
public Drive setCapabilities(Drive.Capabilities capabilities)
Output only. Capabilities the current user has on this shared drive.
- Parameters:
capabilities
- capabilities or null
for none
-
getColorRgb
public String getColorRgb()
The color of this shared drive as an RGB hex string. It can only be set on a
`drive.drives.update` request that does not set `themeId`.
- Returns:
- value or
null
for none
-
setColorRgb
public Drive setColorRgb(String colorRgb)
The color of this shared drive as an RGB hex string. It can only be set on a
`drive.drives.update` request that does not set `themeId`.
- Parameters:
colorRgb
- colorRgb or null
for none
-
getCreatedDate
public com.google.api.client.util.DateTime getCreatedDate()
The time at which the shared drive was created (RFC 3339 date-time).
- Returns:
- value or
null
for none
-
setCreatedDate
public Drive setCreatedDate(com.google.api.client.util.DateTime createdDate)
The time at which the shared drive was created (RFC 3339 date-time).
- Parameters:
createdDate
- createdDate or null
for none
-
getHidden
public Boolean getHidden()
Whether the shared drive is hidden from default view.
- Returns:
- value or
null
for none
-
setHidden
public Drive setHidden(Boolean hidden)
Whether the shared drive is hidden from default view.
- Parameters:
hidden
- hidden or null
for none
-
getId
public String getId()
Output only. The ID of this shared drive which is also the ID of the top level folder of this
shared drive.
- Returns:
- value or
null
for none
-
setId
public Drive setId(String id)
Output only. The ID of this shared drive which is also the ID of the top level folder of this
shared drive.
- Parameters:
id
- id or null
for none
-
getKind
public String getKind()
Output only. This is always `drive#drive`
- Returns:
- value or
null
for none
-
setKind
public Drive setKind(String kind)
Output only. This is always `drive#drive`
- Parameters:
kind
- kind or null
for none
-
getName
public String getName()
The name of this shared drive.
- Returns:
- value or
null
for none
-
setName
public Drive setName(String name)
The name of this shared drive.
- Parameters:
name
- name or null
for none
-
getOrgUnitId
public String getOrgUnitId()
Output only. The organizational unit of this shared drive. This field is only populated on
`drives.list` responses when the `useDomainAdminAccess` parameter is set to `true`.
- Returns:
- value or
null
for none
-
setOrgUnitId
public Drive setOrgUnitId(String orgUnitId)
Output only. The organizational unit of this shared drive. This field is only populated on
`drives.list` responses when the `useDomainAdminAccess` parameter is set to `true`.
- Parameters:
orgUnitId
- orgUnitId or null
for none
-
getRestrictions
public Drive.Restrictions getRestrictions()
A set of restrictions that apply to this shared drive or items inside this shared drive.
- Returns:
- value or
null
for none
-
setRestrictions
public Drive setRestrictions(Drive.Restrictions restrictions)
A set of restrictions that apply to this shared drive or items inside this shared drive.
- Parameters:
restrictions
- restrictions or null
for none
-
getThemeId
public String getThemeId()
The ID of the theme from which the background image and color will be set. The set of possible
`driveThemes` can be retrieved from a `drive.about.get` response. When not specified on a
`drive.drives.insert` request, a random theme is chosen from which the background image and
color are set. This is a write-only field; it can only be set on requests that don't set
`colorRgb` or `backgroundImageFile`.
- Returns:
- value or
null
for none
-
setThemeId
public Drive setThemeId(String themeId)
The ID of the theme from which the background image and color will be set. The set of possible
`driveThemes` can be retrieved from a `drive.about.get` response. When not specified on a
`drive.drives.insert` request, a random theme is chosen from which the background image and
color are set. This is a write-only field; it can only be set on requests that don't set
`colorRgb` or `backgroundImageFile`.
- Parameters:
themeId
- themeId or null
for none
-
set
public Drive set(String fieldName,
Object value)
- Overrides:
set
in class com.google.api.client.json.GenericJson
-
clone
public Drive clone()
- Overrides:
clone
in class com.google.api.client.json.GenericJson
Copyright © 2011–2024 Google. All rights reserved.