Class GoogleCloudStorageBlobStore
java.lang.Object
org.jclouds.blobstore.internal.BaseBlobStore
org.jclouds.googlecloudstorage.blobstore.GoogleCloudStorageBlobStore
- All Implemented Interfaces:
BlobStore
-
Field Summary
Fields inherited from class org.jclouds.blobstore.internal.BaseBlobStore
blobUtils, context, defaultLocation, locations, slicer -
Method Summary
Modifier and TypeMethodDescriptionvoidbooleanblobExists(String container, String name) Checks whether an accessible object is available.blobMetadata(String container, String name) Retrieves the metadata of aBlobat locationcontainer/namecompleteMultipartUpload(MultipartUpload mpu, List<MultipartPart> parts) booleancontainerExists(String container) determines if a service-level container existscopyBlob(String fromContainer, String fromName, String toContainer, String toName, CopyOptions options) Copy blob from one container to another.booleancreateContainerInLocation(Location location, String container) Creates a namespace for your blobsbooleancreateContainerInLocation(Location location, String container, CreateContainerOptions options) protected booleandeleteAndVerifyContainerGone(String container) Delete a container if it is empty.getBlob(String container, String name, GetOptions options) Retrieves aBlobrepresenting the data at locationcontainer/namegetBlobAccess(String container, String name) getContainerAccess(String container) longintlonginitiateMultipartUpload(String container, BlobMetadata blobMetadata, PutOptions options) PageSet<? extends StorageMetadata> list()Lists all root-level resources available to the identity.PageSet<? extends StorageMetadata> Returns list of of all the objectsPageSet<? extends StorageMetadata> list(String container, ListContainerOptions options) LikeBlobStore.list(String)except you can control the size, recursion, and context of the list usingoptionslistMultipartUploads(String container) This supports multipart/related upload which has exactly 2 parts, media-part and metadata-partputBlob(String container, Blob blob, PutOptions options) Adds aBlobrepresenting the data at locationcontainer/blob.metadata.nameoptions using multipart strategies.voidremoveBlob(String container, String name) Deletes aBlobrepresenting the data at locationcontainer/namevoidsetBlobAccess(String container, String name, BlobAccess access) voidsetContainerAccess(String container, ContainerAccess access) uploadMultipartPart(MultipartUpload mpu, int partNumber, Payload payload) Methods inherited from class org.jclouds.blobstore.internal.BaseBlobStore
blobBuilder, clearContainer, clearContainer, countBlobs, countBlobs, createDirectory, deleteContainer, deleteContainerIfEmpty, deleteDirectory, deletePathAndEnsureGone, directoryExists, downloadBlob, downloadBlob, getBlob, getContext, listAssignableLocations, putMultipartBlob, putMultipartBlob, removeBlobs, streamBlob, streamBlob
-
Method Details
-
list
Description copied from interface:BlobStoreLists all root-level resources available to the identity. -
containerExists
Description copied from interface:BlobStoredetermines if a service-level container exists -
createContainerInLocation
Description copied from interface:BlobStoreCreates a namespace for your blobs A container is a namespace for your objects. Depending on the service, the scope can be global, identity, or sub-identity scoped. For example, in Amazon S3, containers are called buckets, and they must be uniquely named such that no-one else in the world conflicts. In other blobstores, the naming convention of the container is less strict. All blobstores allow you to list your containers and also the contents within them. These contents can either be blobs, folders, or virtual paths.- Parameters:
location- some blobstores allow you to specify a location, such as US-EAST, for where this container will exist. null will choose a default locationcontainer- namespace. Typically constrained to lowercase alpha-numeric and hyphens.- Returns:
- true if the container was created, false if it already existed.
-
createContainerInLocation
public boolean createContainerInLocation(Location location, String container, CreateContainerOptions options) - Parameters:
options- controls default access control- See Also:
-
getContainerAccess
-
setContainerAccess
-
list
Returns list of of all the objects- Specified by:
listin interfaceBlobStore- Overrides:
listin classBaseBlobStore- Parameters:
container- container name- Returns:
- a list that may be incomplete, depending on whether PageSet#getNextMarker is set
-
list
Description copied from interface:BlobStoreLikeBlobStore.list(String)except you can control the size, recursion, and context of the list usingoptions- Parameters:
container- what to listoptions- size, recursion, and context of the list- Returns:
- a list that may be incomplete, depending on whether PageSet#getNextMarker is set
-
blobExists
Checks whether an accessible object is available. Google cloud storage does not support directly support BucketExist or ObjectExist operations- Parameters:
container- container where the blob resides
-
putBlob
This supports multipart/related upload which has exactly 2 parts, media-part and metadata-part- Parameters:
container- container to place the blob.blob- fully qualified name relative to the container.- Returns:
- etag of the blob you uploaded, possibly null where etags are unsupported
-
putBlob
Description copied from interface:BlobStoreAdds aBlobrepresenting the data at locationcontainer/blob.metadata.nameoptions using multipart strategies.- Parameters:
container- container to place the blob.blob- fully qualified name relative to the container.options- byte range options- Returns:
- etag of the blob you uploaded, possibly null where etags are unsupported
-
blobMetadata
Description copied from interface:BlobStoreRetrieves the metadata of aBlobat locationcontainer/name- Parameters:
container- container where this exists.name- fully qualified name relative to the container.- Returns:
- null if name isn't present or the blob you intended to receive.
-
getBlob
Description copied from interface:BlobStoreRetrieves aBlobrepresenting the data at locationcontainer/name- Parameters:
container- container where this exists.name- fully qualified name relative to the container.options- byte range or condition options- Returns:
- the blob you intended to receive or null, if it doesn't exist.
-
removeBlob
Description copied from interface:BlobStoreDeletes aBlobrepresenting the data at locationcontainer/name- Parameters:
container- container where this exists.name- fully qualified name relative to the container.
-
getBlobAccess
-
setBlobAccess
-
deleteAndVerifyContainerGone
Description copied from class:BaseBlobStoreDelete a container if it is empty.- Specified by:
deleteAndVerifyContainerGonein classBaseBlobStore- Parameters:
container- what to delete- Returns:
- whether container was deleted
-
copyBlob
public String copyBlob(String fromContainer, String fromName, String toContainer, String toName, CopyOptions options) Description copied from interface:BlobStoreCopy blob from one container to another. Some providers implement this more efficiently than corresponding getBlob and putBlob operations. Note: options are currently ignored- Specified by:
copyBlobin interfaceBlobStore- Overrides:
copyBlobin classBaseBlobStore- Returns:
- ETag of new blob
-
initiateMultipartUpload
public MultipartUpload initiateMultipartUpload(String container, BlobMetadata blobMetadata, PutOptions options) -
abortMultipartUpload
-
completeMultipartUpload
-
uploadMultipartPart
-
listMultipartUpload
-
listMultipartUploads
-
getMinimumMultipartPartSize
public long getMinimumMultipartPartSize() -
getMaximumMultipartPartSize
public long getMaximumMultipartPartSize() -
getMaximumNumberOfParts
public int getMaximumNumberOfParts()
-