@Path(value="/") public interface AzureBlobClient extends Closeable
Modifier and Type | Method and Description |
---|---|
boolean |
blobExists(String container,
String name) |
boolean |
containerExists(String container)
Issues a HEAD command to determine if the container exists or not.
|
String |
copyBlob(URI copySource,
String toContainer,
String toName,
CopyBlobOptions options) |
boolean |
createContainer(String container,
CreateContainerOptions... options)
The Create Container operation creates a new container under the specified identity.
|
boolean |
createRootContainer(CreateContainerOptions... options)
The root container is a default container that may be inferred from a URL requesting a blob
resource.
|
void |
deleteBlob(String container,
String name)
The Delete Blob operation marks the specified blob for deletion.
|
void |
deleteContainer(String container)
The Delete Container operation marks the specified container for deletion.
|
void |
deleteRootContainer()
The Delete Container operation marks the specified container for deletion.
|
AzureBlob |
getBlob(String container,
String name,
GetOptions... options)
The Get Blob operation reads or downloads a blob from the system, including its metadata and
properties.
|
BlobProperties |
getBlobProperties(String container,
String name)
The Get Blob Properties operation returns all user-defined metadata, standard HTTP properties,
and system properties for the blob.
|
ListBlobBlocksResponse |
getBlockList(String container,
String name) |
ContainerProperties |
getContainerProperties(String container)
The Get Container Properties operation returns all user-defined metadata and system properties
for the specified container.
|
PublicAccess |
getPublicAccessForContainer(String container)
Returns whether data in the container may be accessed publicly and the level of access
|
ListBlobsResponse |
listBlobs(ListBlobsOptions... options) |
ListBlobsResponse |
listBlobs(String container,
ListBlobsOptions... options)
The List Blobs operation enumerates the list of blobs under the specified container.
|
BoundedSet<ContainerProperties> |
listContainers(ListOptions... listOptions)
The List Containers operation returns a list of the containers under the specified identity.
|
AzureBlob |
newBlob() |
String |
putBlob(String container,
AzureBlob object)
The Put Blob operation creates a new blob or updates the content of an existing blob.
|
void |
putBlock(String container,
String name,
String blockId,
Payload part)
The Put Block operation creates a block blob on Azure which can be later assembled into
a single, large blob object with the Put Block List operation.
|
String |
putBlockList(String container,
AzureBlob object,
List<String> blockIdList)
The Put Block List assembles a list of blocks previously uploaded with Put Block into a single
blob.
|
String |
putBlockList(String container,
String name,
List<String> blockIdList)
Deprecated.
call putBlockList(String, AzureBlob, List<String>) instead
|
String |
setBlobMetadata(String container,
String name,
Map<String,String> metadata) |
String |
setBlobProperties(String container,
String name,
ContentMetadata contentMetadata) |
void |
setBlobTier(String container,
String name,
AccessTier tier) |
String |
setPublicAccessForContainer(String container,
PublicAccess access)
Returns whether data in the container may be accessed publicly and the level of access
|
void |
setResourceMetadata(String container,
Map<String,String> metadata)
The Set Container Metadata operation sets one or more user-defined name/value pairs for the
specified container.
|
@Provides AzureBlob newBlob()
@Named(value="ListContainers") @GET BoundedSet<ContainerProperties> listContainers(ListOptions... listOptions)
listOptions
- controls the number or type of results requestedListOptions
@Named(value="CreateContainer") @PUT @Path(value="{container}") boolean createContainer(@PathParam(value="container") String container, CreateContainerOptions... options)
CreateContainerOptions
@Named(value="GetContainerProperties") @HEAD @Path(value="{container}") ContainerProperties getContainerProperties(@PathParam(value="container") String container)
@Named(value="GetContainerProperties") @HEAD @Path(value="{container}") boolean containerExists(@PathParam(value="container") String container)
@Named(value="SetContainerMetadata") @PUT @Path(value="{container}") void setResourceMetadata(@PathParam(value="container") String container, Map<String,String> metadata)
@Named(value="DeleteContainer") @DELETE @Path(value="{container}") void deleteContainer(@PathParam(value="container") String container)
@Named(value="CreateContainer") @PUT @Path(value="$root") boolean createRootContainer(CreateContainerOptions... options)
CreateContainerOptions
@Named(value="GetContainerACL") @HEAD @Path(value="{container}") PublicAccess getPublicAccessForContainer(@PathParam(value="container") String container)
@Named(value="SetContainerACL") @PUT @Path(value="{container}") String setPublicAccessForContainer(@PathParam(value="container") String container, PublicAccess access)
@Named(value="DeleteContainer") @DELETE @Path(value="$root") void deleteRootContainer()
@Named(value="ListBlobs") @GET @Path(value="{container}") ListBlobsResponse listBlobs(@PathParam(value="container") String container, ListBlobsOptions... options)
@Named(value="ListBlobs") @GET @Path(value="$root") ListBlobsResponse listBlobs(ListBlobsOptions... options)
@Named(value="PutBlob") @PUT @Path(value="{container}/{name}") String putBlob(@PathParam(value="container") String container, @PathParam(value="name") AzureBlob object)
@Named(value="GetBlob") @GET @Path(value="{container}/{name}") AzureBlob getBlob(@PathParam(value="container") String container, @PathParam(value="name") String name, GetOptions... options)
@Named(value="PutBlock") @PUT @Path(value="{container}/{name}") void putBlock(@PathParam(value="container") String container, @PathParam(value="name") String name, @QueryParam(value="blockid") String blockId, Payload part)
@Deprecated @Named(value="PutBlockList") @PUT @Path(value="{container}/{name}") String putBlockList(@PathParam(value="container") String container, @PathParam(value="name") String name, List<String> blockIdList)
@Named(value="PutBlockList") @PUT @Path(value="{container}/{name}") String putBlockList(@PathParam(value="container") String container, @PathParam(value="name") AzureBlob object, List<String> blockIdList)
@Named(value="GetBlockList") @GET @Path(value="{container}/{name}") ListBlobBlocksResponse getBlockList(@PathParam(value="container") String container, @PathParam(value="name") String name)
@Named(value="GetBlobProperties") @HEAD @Path(value="{container}/{name}") BlobProperties getBlobProperties(@PathParam(value="container") String container, @PathParam(value="name") String name)
@Named(value="SetBlobProperties") @PUT @Path(value="{container}/{name}") String setBlobProperties(@PathParam(value="container") String container, @PathParam(value="name") String name, ContentMetadata contentMetadata)
@Named(value="SetBlobMetadata") @PUT @Path(value="{container}/{name}") String setBlobMetadata(@PathParam(value="container") String container, @PathParam(value="name") String name, Map<String,String> metadata)
@Named(value="SetAccessTier") @PUT @Path(value="{container}/{name}") void setBlobTier(@PathParam(value="container") String container, @PathParam(value="name") String name, @HeaderParam(value="x-ms-access-tier") AccessTier tier)
@Named(value="DeleteBlob") @DELETE @Path(value="{container}/{name}") void deleteBlob(@PathParam(value="container") String container, @PathParam(value="name") String name)
@Named(value="GetBlobProperties") @HEAD @Path(value="{container}/{name}") boolean blobExists(@PathParam(value="container") String container, @PathParam(value="name") String name)
ContainerNotFoundException
- if the container is not present.@Named(value="CopyBlob") @PUT @Path(value="{toContainer}/{toName}") String copyBlob(@PathParam(value="copySource") URI copySource, @PathParam(value="toContainer") String toContainer, @PathParam(value="toName") String toName, CopyBlobOptions options)
ContainerNotFoundException
- if the container is not present.Copyright © 2009-2021 The Apache Software Foundation. All Rights Reserved.