ReadToFileOptions Class

  • java.lang.Object
    • com.azure.storage.file.datalake.options.ReadToFileOptions

public class ReadToFileOptions

Parameters when calling readToFile() on DataLakeFileClient

Constructor Summary

Constructor Description
ReadToFileOptions(String filePath)

Constructs a ReadToFileOptions.

Method Summary

Modifier and Type Method and Description
DataLakeRequestConditions getDataLakeRequestConditions()

Gets the DataLakeRequestConditions.

DownloadRetryOptions getDownloadRetryOptions()

Gets the DownloadRetryOptions.

String getFilePath()

Gets the path of the file to download to.

Set<OpenOption> getOpenOptions()

Gets the OpenOptions to use to configure how to open or create the file.

ParallelTransferOptions getParallelTransferOptions()

Gets the ParallelTransferOptions to use to download to file.

FileRange getRange()

Gets the FileRange.

Boolean isRangeGetContentMd5()

Gets whether the contentMD5 for the specified file range should be returned.

Boolean isUserPrincipalName()

Gets the value for the x-ms-upn header.

ReadToFileOptions setDataLakeRequestConditions(DataLakeRequestConditions dataLakeRequestConditions)

Sets the DataLakeRequestConditions.

ReadToFileOptions setDownloadRetryOptions(DownloadRetryOptions downloadRetryOptions)

Sets the DownloadRetryOptions.

ReadToFileOptions setOpenOptions(Set<OpenOption> openOptions)

Sets the OpenOptions to use to configure how to open or create the file.

ReadToFileOptions setParallelTransferOptions(ParallelTransferOptions parallelTransferOptions)

Sets the ParallelTransferOptions to use to download to file.

ReadToFileOptions setRange(FileRange range)

Sets the FileRange.

ReadToFileOptions setRangeGetContentMd5(Boolean rangeGetContentMd5)

Sets whether the contentMD5 for the specified file range should be returned.

ReadToFileOptions setUserPrincipalName(Boolean userPrincipalName)

Sets the value for the x-ms-upn header.

Methods inherited from java.lang.Object

Constructor Details

ReadToFileOptions

public ReadToFileOptions(String filePath)

Constructs a ReadToFileOptions.

Parameters:

filePath - Path of the file to download to.

Method Details

getDataLakeRequestConditions

public DataLakeRequestConditions getDataLakeRequestConditions()

Gets the DataLakeRequestConditions.

Returns:

requestConditions DataLakeRequestConditions

getDownloadRetryOptions

public DownloadRetryOptions getDownloadRetryOptions()

Gets the DownloadRetryOptions.

Returns:

getFilePath

public String getFilePath()

Gets the path of the file to download to.

Returns:

The path where the downloaded data will be written.

getOpenOptions

public Set getOpenOptions()

Gets the OpenOptions to use to configure how to open or create the file.

Returns:

OpenOptions to use to configure how to open or create the file.

getParallelTransferOptions

public ParallelTransferOptions getParallelTransferOptions()

Gets the ParallelTransferOptions to use to download to file. Number of parallel transfers parameter is ignored.

Returns:

ParallelTransferOptions to use to download to file. Number of parallel transfers parameter is ignored.

getRange

public FileRange getRange()

Gets the FileRange.

Returns:

isRangeGetContentMd5

public Boolean isRangeGetContentMd5()

Gets whether the contentMD5 for the specified file range should be returned.

Returns:

Whether the contentMD5 for the specified file range should be returned.

isUserPrincipalName

public Boolean isUserPrincipalName()

Gets the value for the x-ms-upn header.

Returns:

The value for the x-ms-upn header.

setDataLakeRequestConditions

public ReadToFileOptions setDataLakeRequestConditions(DataLakeRequestConditions dataLakeRequestConditions)

Sets the DataLakeRequestConditions.

Parameters:

dataLakeRequestConditions - DataLakeRequestConditions

Returns:

The updated options.

setDownloadRetryOptions

public ReadToFileOptions setDownloadRetryOptions(DownloadRetryOptions downloadRetryOptions)

Sets the DownloadRetryOptions.

Parameters:

downloadRetryOptions - DownloadRetryOptions

Returns:

The updated options.

setOpenOptions

public ReadToFileOptions setOpenOptions(Set openOptions)

Sets the OpenOptions to use to configure how to open or create the file.

Parameters:

openOptions - OpenOptions to use to configure how to open or create the file.

Returns:

The updated options.

setParallelTransferOptions

public ReadToFileOptions setParallelTransferOptions(ParallelTransferOptions parallelTransferOptions)

Sets the ParallelTransferOptions to use to download to file. Number of parallel transfers parameter is ignored.

Parameters:

parallelTransferOptions - ParallelTransferOptions to use to download to file. Number of parallel transfers parameter is ignored.

Returns:

The updated options.

setRange

public ReadToFileOptions setRange(FileRange range)

Sets the FileRange.

Parameters:

range - FileRange

Returns:

The updated options.

setRangeGetContentMd5

public ReadToFileOptions setRangeGetContentMd5(Boolean rangeGetContentMd5)

Sets whether the contentMD5 for the specified file range should be returned.

Parameters:

rangeGetContentMd5 - Whether the contentMD5 for the specified file range should be returned.

Returns:

The updated options.

setUserPrincipalName

public ReadToFileOptions setUserPrincipalName(Boolean userPrincipalName)

Sets the value for the x-ms-upn header.

Parameters:

userPrincipalName - The value for the x-ms-upn header.

Returns:

The updated options.

Applies to