com.microsoft.windowsazure.services.blob.client.BlobListingContext Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of microsoft-windowsazure-api Show documentation
Show all versions of microsoft-windowsazure-api Show documentation
API for Microsoft Windows Azure Clients
/**
* Copyright Microsoft Corporation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.microsoft.windowsazure.services.blob.client;
import java.util.EnumSet;
import com.microsoft.windowsazure.services.core.storage.utils.implementation.ListingContext;
/**
* RESERVED FOR INTERNAL USE. Provides the listing context for blobs including the delimiter and listingdetails
*/
final class BlobListingContext extends ListingContext {
/**
* Gets or sets the delimiter for a blob listing operation. The delimiter parameter enables the caller to traverse
* the blob namespace by using a user-configured delimiter. Using this parameter, it is possible to traverse a
* virtual hierarchy of blobs as though it were a file system.
*/
private String delimiter;
/**
* Gets or sets the details for the listing operation, which indicates the types of data to include in the response.
* The include parameter specifies that the response should include one or more of the following subsets: snapshots,
* metadata, uncommitted blobs.
*/
private EnumSet listingDetails;
/**
* Initializes a new instance of the BlobListingContext class
*
* @param prefix
* the prefix to use.
* @param maxResults
* the maximum results to download.
*/
public BlobListingContext(final String prefix, final Integer maxResults) {
super(prefix, maxResults);
}
/**
* Initializes a new instance of the BlobListingContext class
*
* @param prefix
* the prefix to use.
* @param maxResults
* the maximum results to download.
* @param delimiter
* the delimiter to use
* @param listingDetails
* the BlobListingDetails to use.
*/
public BlobListingContext(final String prefix, final Integer maxResults, final String delimiter,
final EnumSet listingDetails) {
super(prefix, maxResults);
this.setDelimiter(delimiter);
this.setListingDetails(listingDetails);
}
/**
* @return the delimiter
*/
protected String getDelimiter() {
return this.delimiter;
}
/**
* @return the listingDetails
*/
protected EnumSet getListingDetails() {
return this.listingDetails;
}
/**
* @param delimiter
* the delimiter to set
*/
protected void setDelimiter(final String delimiter) {
this.delimiter = delimiter;
}
/**
* @param listingDetails
* the listingDetails to set
*/
protected void setListingDetails(final EnumSet listingDetails) {
this.listingDetails = listingDetails;
}
}