public class Storage.Objects.Get extends StorageRequest<StorageObject>
com.google.api.client.util.GenericData.Flags| Modifier | Constructor and Description |
|---|---|
protected |
Get(java.lang.String bucket,
java.lang.String object__)
Retrieves an object or its metadata.
|
| Modifier and Type | Method and Description |
|---|---|
com.google.api.client.http.GenericUrl |
buildHttpRequestUrl() |
com.google.api.client.http.HttpRequest |
buildHttpRequestUsingHead() |
com.google.api.client.http.HttpResponse |
executeMedia() |
void |
executeMediaAndDownloadTo(java.io.OutputStream outputStream) |
java.io.InputStream |
executeMediaAsInputStream() |
com.google.api.client.http.HttpResponse |
executeUsingHead() |
java.lang.String |
getBucket()
Name of the bucket in which the object resides.
|
java.lang.Long |
getGeneration()
If present, selects a specific revision of this object (as opposed to the latest version, the
default).
|
java.lang.Long |
getIfGenerationMatch()
Makes the operation conditional on whether the object's current generation matches the given value.
|
java.lang.Long |
getIfGenerationNotMatch()
Makes the operation conditional on whether the object's current generation does not match the given
value.
|
java.lang.Long |
getIfMetagenerationMatch()
Makes the operation conditional on whether the object's current metageneration matches the given
value.
|
java.lang.Long |
getIfMetagenerationNotMatch()
Makes the operation conditional on whether the object's current metageneration does not match the
given value.
|
java.lang.String |
getObject()
Name of the object.
|
java.lang.String |
getProjection()
Set of properties to return.
|
java.lang.String |
getProvisionalUserProject()
The project to be billed for this request if the target bucket is requester-pays bucket.
|
java.lang.String |
getUserProject()
The project to be billed for this request.
|
Storage.Objects.Get |
set(java.lang.String parameterName,
java.lang.Object value) |
Storage.Objects.Get |
setAlt(java.lang.String alt)
Data format for the response.
|
Storage.Objects.Get |
setBucket(java.lang.String bucket)
Name of the bucket in which the object resides.
|
Storage.Objects.Get |
setFields(java.lang.String fields)
Selector specifying which fields to include in a partial response.
|
Storage.Objects.Get |
setGeneration(java.lang.Long generation)
If present, selects a specific revision of this object (as opposed to the latest version,
the default).
|
Storage.Objects.Get |
setIfGenerationMatch(java.lang.Long ifGenerationMatch)
Makes the operation conditional on whether the object's current generation matches the
given value.
|
Storage.Objects.Get |
setIfGenerationNotMatch(java.lang.Long ifGenerationNotMatch)
Makes the operation conditional on whether the object's current generation does not match
the given value.
|
Storage.Objects.Get |
setIfMetagenerationMatch(java.lang.Long ifMetagenerationMatch)
Makes the operation conditional on whether the object's current metageneration matches the
given value.
|
Storage.Objects.Get |
setIfMetagenerationNotMatch(java.lang.Long ifMetagenerationNotMatch)
Makes the operation conditional on whether the object's current metageneration does not
match the given value.
|
Storage.Objects.Get |
setKey(java.lang.String key)
API key.
|
Storage.Objects.Get |
setOauthToken(java.lang.String oauthToken)
OAuth 2.0 token for the current user.
|
Storage.Objects.Get |
setObject(java.lang.String object__)
Name of the object.
|
Storage.Objects.Get |
setPrettyPrint(java.lang.Boolean prettyPrint)
Returns response with indentations and line breaks.
|
Storage.Objects.Get |
setProjection(java.lang.String projection)
Set of properties to return.
|
Storage.Objects.Get |
setProvisionalUserProject(java.lang.String provisionalUserProject)
The project to be billed for this request if the target bucket is requester-pays bucket.
|
Storage.Objects.Get |
setQuotaUser(java.lang.String quotaUser)
An opaque string that represents a user for quota purposes.
|
Storage.Objects.Get |
setUserIp(java.lang.String userIp)
Deprecated.
|
Storage.Objects.Get |
setUserProject(java.lang.String userProject)
The project to be billed for this request.
|
getAbstractGoogleClient, getAlt, getFields, getKey, getOauthToken, getPrettyPrint, getQuotaUser, getUserIp, setDisableGZipContent, setRequestHeadersgetJsonContent, newExceptionOnError, queuebuildHttpRequest, checkRequiredParameter, execute, executeAndDownloadTo, executeAsInputStream, executeUnparsed, getDisableGZipContent, getHttpContent, getLastResponseHeaders, getLastStatusCode, getLastStatusMessage, getMediaHttpDownloader, getMediaHttpUploader, getRequestHeaders, getRequestMethod, getResponseClass, getUriTemplate, initializeMediaDownload, initializeMediaUpload, queueclone, entrySet, get, getClassInfo, getUnknownKeys, put, putAll, remove, setUnknownKeysclear, containsKey, containsValue, equals, hashCode, isEmpty, keySet, size, toString, valuesprotected Get(java.lang.String bucket,
java.lang.String object__)
AbstractGoogleClientRequest.execute() method to invoke the remote operation. Storage.initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest) must be
called to initialize this instance immediately after invoking the constructor.
bucket - Name of the bucket in which the object resides.object__ - Name of the object. For information about how to URL encode object names to be path safe, see
Encoding URI Path Parts.public void executeMediaAndDownloadTo(java.io.OutputStream outputStream)
throws java.io.IOException
executeMediaAndDownloadTo in class com.google.api.client.googleapis.services.AbstractGoogleClientRequest<StorageObject>java.io.IOExceptionpublic java.io.InputStream executeMediaAsInputStream()
throws java.io.IOException
executeMediaAsInputStream in class com.google.api.client.googleapis.services.AbstractGoogleClientRequest<StorageObject>java.io.IOExceptionpublic com.google.api.client.http.HttpResponse executeMedia()
throws java.io.IOException
executeMedia in class com.google.api.client.googleapis.services.AbstractGoogleClientRequest<StorageObject>java.io.IOExceptionpublic com.google.api.client.http.GenericUrl buildHttpRequestUrl()
buildHttpRequestUrl in class com.google.api.client.googleapis.services.AbstractGoogleClientRequest<StorageObject>public com.google.api.client.http.HttpResponse executeUsingHead()
throws java.io.IOException
executeUsingHead in class com.google.api.client.googleapis.services.AbstractGoogleClientRequest<StorageObject>java.io.IOExceptionpublic com.google.api.client.http.HttpRequest buildHttpRequestUsingHead()
throws java.io.IOException
buildHttpRequestUsingHead in class com.google.api.client.googleapis.services.AbstractGoogleClientRequest<StorageObject>java.io.IOExceptionpublic Storage.Objects.Get setAlt(java.lang.String alt)
StorageRequestsetAlt in class StorageRequest<StorageObject>public Storage.Objects.Get setFields(java.lang.String fields)
StorageRequestsetFields in class StorageRequest<StorageObject>public Storage.Objects.Get setKey(java.lang.String key)
StorageRequestsetKey in class StorageRequest<StorageObject>public Storage.Objects.Get setOauthToken(java.lang.String oauthToken)
StorageRequestsetOauthToken in class StorageRequest<StorageObject>public Storage.Objects.Get setPrettyPrint(java.lang.Boolean prettyPrint)
StorageRequestsetPrettyPrint in class StorageRequest<StorageObject>public Storage.Objects.Get setQuotaUser(java.lang.String quotaUser)
StorageRequestsetQuotaUser in class StorageRequest<StorageObject>public Storage.Objects.Get setUserIp(java.lang.String userIp)
StorageRequestsetUserIp in class StorageRequest<StorageObject>public java.lang.String getBucket()
public Storage.Objects.Get setBucket(java.lang.String bucket)
public java.lang.String getObject()
public Storage.Objects.Get setObject(java.lang.String object__)
public java.lang.Long getGeneration()
public Storage.Objects.Get setGeneration(java.lang.Long generation)
public java.lang.Long getIfGenerationMatch()
public Storage.Objects.Get setIfGenerationMatch(java.lang.Long ifGenerationMatch)
public java.lang.Long getIfGenerationNotMatch()
public Storage.Objects.Get setIfGenerationNotMatch(java.lang.Long ifGenerationNotMatch)
public java.lang.Long getIfMetagenerationMatch()
public Storage.Objects.Get setIfMetagenerationMatch(java.lang.Long ifMetagenerationMatch)
public java.lang.Long getIfMetagenerationNotMatch()
public Storage.Objects.Get setIfMetagenerationNotMatch(java.lang.Long ifMetagenerationNotMatch)
public java.lang.String getProjection()
public Storage.Objects.Get setProjection(java.lang.String projection)
public java.lang.String getProvisionalUserProject()
public Storage.Objects.Get setProvisionalUserProject(java.lang.String provisionalUserProject)
public java.lang.String getUserProject()
public Storage.Objects.Get setUserProject(java.lang.String userProject)
public Storage.Objects.Get set(java.lang.String parameterName, java.lang.Object value)
set in class StorageRequest<StorageObject>