ListBlobsOptions Class

  • java.lang.Object
    • com.azure.storage.blob.models.ListBlobsOptions

public final class ListBlobsOptions

Defines options available to configure the behavior of a call to listBlobsFlatSegment on a BlobContainerClient object. See the constructor for details on each of the options.

Constructor Summary

Constructor Description
ListBlobsOptions()

Constructs an unpopulated ListBlobsOptions.

Method Summary

Modifier and Type Method and Description
BlobListDetails getDetails()

Gets the details for listing specific blobs.

String getEndBefore()

Gets the endBefore value.

Integer getMaxResultsPerPage()

Specifies the maximum number of blobs to return, including all BlobPrefix elements.

String getPrefix()

Filters the results to return only blobs whose names begin with the specified prefix.

String getStartFrom()

Gets an optional parameter that specifies an absolute path within the container.

StorageResponseSerializationFormat getStorageResponseSerializationFormat()

Gets the response serialization format the service should use when listing blobs.

ListBlobsOptions setDetails(BlobListDetails details)

Sets the details for listing specific blobs.

ListBlobsOptions setEndBefore(String endBefore)

Sets the endBefore value.

ListBlobsOptions setMaxResultsPerPage(Integer maxResultsPerPage)

Specifies the maximum number of blobs to return, including all BlobPrefix elements.

ListBlobsOptions setPrefix(String prefix)

Filters the results to return only blobs whose names begin with the specified prefix.

ListBlobsOptions setStartFrom(String startFrom)

Sets an optional parameter that specifies an absolute path within the container.

ListBlobsOptions setStorageResponseSerializationFormat(StorageResponseSerializationFormat storageResponseSerializationFormat)

Sets the response serialization format the service should use when listing blobs.

Methods inherited from java.lang.Object

Constructor Details

ListBlobsOptions

public ListBlobsOptions()

Constructs an unpopulated ListBlobsOptions.

Method Details

getDetails

public BlobListDetails getDetails()

Gets the details for listing specific blobs.

Returns:

the details for listing specific blobs

getEndBefore

public String getEndBefore()

Gets the endBefore value. Only supported with Arrow listings. The listing will end before this path (exclusive).

Returns:

the endBefore value.

getMaxResultsPerPage

public Integer getMaxResultsPerPage()

Specifies the maximum number of blobs to return, including all BlobPrefix elements. If the request does not specify maxResultsPerPage or specifies a value greater than 5,000, the server will return up to 5,000 items.

Returns:

the number of blobs that will be returned in a single response

getPrefix

public String getPrefix()

Filters the results to return only blobs whose names begin with the specified prefix. May be null to return all blobs.

Returns:

the prefix that a blob must match to be returned in the listing

getStartFrom

public String getStartFrom()

Gets an optional parameter that specifies an absolute path within the container. This parameter is similar to the prefix filter: it allows listing blobs starting from the specified path, rather than from the beginning of the container. For non-recursive lists, only one entity level is supported.

Returns:

the marker indicating where to start listing blobs (inclusive)

getStorageResponseSerializationFormat

public StorageResponseSerializationFormat getStorageResponseSerializationFormat()

Gets the response serialization format the service should use when listing blobs.

Returns:

the StorageResponseSerializationFormat, or null if unset (equivalent to AUTO).

setDetails

public ListBlobsOptions setDetails(BlobListDetails details)

Sets the details for listing specific blobs.

Parameters:

details - The details for listing specific blobs

Returns:

the updated ListBlobsOptions object

setEndBefore

public ListBlobsOptions setEndBefore(String endBefore)

Sets the endBefore value. Only supported with Arrow listings. The listing will end before this path (exclusive).

Parameters:

endBefore - the endBefore value to set.

Returns:

the updated ListBlobsOptions object.

setMaxResultsPerPage

public ListBlobsOptions setMaxResultsPerPage(Integer maxResultsPerPage)

Specifies the maximum number of blobs to return, including all BlobPrefix elements. If the request does not specify maxResultsPerPage or specifies a value greater than 5,000, the server will return up to 5,000 items.

Parameters:

maxResultsPerPage - The number of blobs to returned in a single response

Returns:

the updated ListBlobsOptions object

setPrefix

public ListBlobsOptions setPrefix(String prefix)

Filters the results to return only blobs whose names begin with the specified prefix. May be null to return all blobs.

Parameters:

prefix - A prefix that a blob must match to be returned

Returns:

the updated ListBlobsOptions object

setStartFrom

public ListBlobsOptions setStartFrom(String startFrom)

Sets an optional parameter that specifies an absolute path within the container. This parameter is similar to the prefix filter: it allows listing blobs starting from the specified path, rather than from the beginning of the container. For non-recursive lists, only one entity level is supported.

Parameters:

startFrom - The marker indicating where to start listing blobs (inclusive)

Returns:

the updated ListBlobsOptions object

setStorageResponseSerializationFormat

public ListBlobsOptions setStorageResponseSerializationFormat(StorageResponseSerializationFormat storageResponseSerializationFormat)

Sets the response serialization format the service should use when listing blobs.

Parameters:

storageResponseSerializationFormat - the format to request. null and AUTO both let the SDK pick.

Returns:

the updated ListBlobsOptions object.

Applies to