Java SDK API Reference
This section provides a comprehensive reference for the Azure Storage client library for Java. Explore the classes, methods, and properties available to interact with Azure Storage services.
Blob Storage
Interact with Azure Blob Storage for storing unstructured data like documents, images, and videos.
BlobServiceClient
The primary client object for interacting with Azure Blob Storage.
Methods
| Method | Description | Return Type |
|---|---|---|
GETgetBlobContainerClient(String containerName) |
Gets a client to interact with a specific blob container. | BlobContainerClient |
POSTcreateBlobContainer(String containerName) |
Creates a new blob container. | BlobContainerClient |
DELETEdeleteBlobContainer(String containerName) |
Deletes a blob container. | void |
GETlistBlobContainers() |
Lists all blob containers in the storage account. | Iterable<BlobContainerItem> |
BlobContainerClient
Represents a blob container and provides methods for managing blobs within it.
Methods
| Method | Description | Return Type |
|---|---|---|
GETgetBlobClient(String blobName) |
Gets a client to interact with a specific blob. | BlobClient |
PUTuploadBlob(String blobName, java.io.InputStream content) |
Uploads a new blob or replaces an existing blob. | BlobInfo |
GETdownloadBlob(String blobName) |
Downloads a blob. | BlobDownloadResponse |
DELETEdeleteBlob(String blobName) |
Deletes a blob. | void |
BlobClient
Represents a specific blob and provides methods for its management.
Methods
| Method | Description | Return Type |
|---|---|---|
GETgetProperties() |
Retrieves the properties of the blob. | BlobProperties |
PUTupload(java.io.InputStream content) |
Uploads a new blob or replaces an existing blob. | BlobInfo |
GETdownload() |
Downloads the blob content. | BlobDownloadResponse |
DELETEdelete() |
Deletes the blob. | void |
Queue Storage
Use Azure Queue Storage to store large numbers of messages that can be processed asynchronously.
QueueServiceClient
The primary client object for interacting with Azure Queue Storage.
Methods
| Method | Description | Return Type |
|---|---|---|
GETgetQueueClient(String queueName) |
Gets a client to interact with a specific queue. | QueueClient |
PUTcreateQueue(String queueName) |
Creates a new queue. | QueueClient |
DELETEdeleteQueue(String queueName) |
Deletes a queue. | void |
GETlistQueues() |
Lists all queues in the storage account. | Iterable<QueueItem> |
QueueClient
Represents a queue and provides methods for managing messages.
Methods
| Method | Description | Return Type |
|---|---|---|
POSTsendMessage(String messageText) |
Adds a message to the queue. | SendReceipt |
GETreceiveMessages(int maxMessages) |
Retrieves one or more messages from the front of the queue. | Iterable<QueueMessage> |
DELETEdeleteMessage(String messageId, String popReceipt) |
Deletes a specific message from the queue. | void |
File Storage
Azure Files offers fully managed cloud file shares that are accessible via the industry-standard Server Message Block (SMB) protocol.
ShareServiceClient
The primary client object for interacting with Azure File Storage.
Methods
| Method | Description | Return Type |
|---|---|---|
GETgetShareClient(String shareName) |
Gets a client to interact with a specific file share. | ShareClient |
PUTcreateShare(String shareName) |
Creates a new file share. | ShareClient |
DELETEdeleteShare(String shareName) |
Deletes a file share. | void |
ShareClient
Represents a file share and provides methods for managing directories and files.
Methods
| Method | Description | Return Type |
|---|---|---|
GETgetDirectoryClient(String directoryName) |
Gets a client to interact with a specific directory. | ShareDirectoryClient |
PUTcreateFile(String fileName, long size) |
Creates a new file. | ShareFileClient |
Table Storage
Azure Table Storage is a NoSQL key-attribute store that allows you to store large amounts of structured, non-relational data.
TableServiceClient
The primary client object for interacting with Azure Table Storage.
Methods
| Method | Description | Return Type |
|---|---|---|
GETgetTableClient(String tableName) |
Gets a client to interact with a specific table. | TableClient |
PUTcreateTable(String tableName) |
Creates a new table. | TableClient |
DELETEdeleteTable(String tableName) |
Deletes a table. | void |
TableClient
Represents a table and provides methods for managing entities.
Methods
| Method | Description | Return Type |
|---|---|---|
POSTcreateEntity(Object entity) |
Creates a new entity in the table. | Response<Void> |
GETgetEntity(String partitionKey, String rowKey) |
Retrieves a specific entity from the table. | Response<T> |
PATCHupdateEntity(Object entity) |
Updates an existing entity. | Response<Void> |
DELETEdeleteEntity(String partitionKey, String rowKey) |
Deletes an entity from the table. | Response<Void> |