@DoesServiceRequest
    public ResultSegment<ListFileItem> listFilesAndDirectoriesSegmented(final String prefix, final Integer maxResults,
            final ResultContinuation continuationToken, FileRequestOptions options, OperationContext opContext)
            throws StorageException {
        if (opContext == null) {
            opContext = new OperationContext();
        }

        opContext.initialize();
        options = FileRequestOptions.populateAndApplyDefaults(options, this.fileServiceClient);

        Utility.assertContinuationType(continuationToken, ResultContinuationType.FILE);

        SegmentedStorageRequest segmentedRequest = new SegmentedStorageRequest();
        segmentedRequest.setToken(continuationToken);

        return ExecutionEngine.executeWithRetry(this.fileServiceClient, this,
                this.listFilesAndDirectoriesSegmentedImpl(prefix, maxResults, options, segmentedRequest),
                options.getRetryPolicyFactory(), opContext);
    }
@DoesServiceRequest
    public ResultSegment<ListFileItem> listFilesAndDirectoriesSegmented(final String prefix, final Integer maxResults,
            final ResultContinuation continuationToken, FileRequestOptions options, OperationContext opContext)
            throws StorageException {
        if (opContext == null) {
            opContext = new OperationContext();
        }

        opContext.initialize();
        options = FileRequestOptions.populateAndApplyDefaults(options, this.fileServiceClient);

        Utility.assertContinuationType(continuationToken, ResultContinuationType.FILE);

        SegmentedStorageRequest segmentedRequest = new SegmentedStorageRequest();
        segmentedRequest.setToken(continuationToken);

        return ExecutionEngine.executeWithRetry(this.fileServiceClient, this,
                this.listFilesAndDirectoriesSegmentedImpl(prefix, maxResults, options, segmentedRequest),
                options.getRetryPolicyFactory(), opContext);
    }
@ DoesServiceRequest public ResultSegment < ListFileItem > listFilesAndDirectoriesSegmented ( final String prefix , final Integer maxResults , final ResultContinuation continuationToken , FileRequestOptions options , OperationContext opContext ) throws StorageException { if ( opContext == null ) { opContext = new OperationContext ( ) ; } opContext . initialize ( ) ; options = FileRequestOptions . populateAndApplyDefaults ( options , this . fileServiceClient ) ; Utility . assertContinuationType ( continuationToken , ResultContinuationType . FILE ) ; SegmentedStorageRequest segmentedRequest = new SegmentedStorageRequest ( ) ; segmentedRequest . setToken ( continuationToken ) ; return ExecutionEngine . executeWithRetry ( this . fileServiceClient , this , this . listFilesAndDirectoriesSegmentedImpl ( prefix , maxResults , options , segmentedRequest ) , options . getRetryPolicyFactory ( ) , opContext ) ; }
Returns a result segment of an enumerable collection of files and directories for this directory, using the
specified listing details options, request options, and operation context.

@param prefix
A string containing the file or directory name prefix.
@param maxResults
The maximum number of results to retrieve.  If <code>null</code> or greater
than 5000, the server will return up to 5,000 items.  Must be at least 1.
@param continuationToken
A {@link ResultContinuation} object that represents a continuation token
returned by a previous listing operation.
@param options
A {@link FileRequestOptions} object that specifies any additional options for
the request. Specifying <code>null</code> will use the default request options
from the associated service client ( {@link CloudFileClient}).
@param opContext
An {@link OperationContext} object that represents the context for the current
operation. This object is used to track requests to the storage service,
and to provide additional runtime information about the operation.

@return A {@link ResultSegment} object that contains a segment of the enumerable collection of
{@link ListFileItem} objects that represent the files and directories in this directory.

@throws StorageException
If a storage service error occurred.
Returns a result segment of an enumerable collection of files and directories for this directory using the specified listing details options request options and operation context .