From ff10813ba094e1bd6f9538a36440d75a9d649c50 Mon Sep 17 00:00:00 2001 From: JinmingHu Date: Wed, 28 Apr 2021 10:42:58 +0800 Subject: [PATCH] Add docs for return types and options (#2159) * Add docs for return type * datalake options * share options * transfer options --- .../inc/azure/storage/blobs/blob_options.hpp | 108 +- .../azure/storage/blobs/blob_responses.hpp | 216 +++- .../files/datalake/datalake_options.hpp | 63 +- .../storage/files/shares/share_options.hpp | 945 ++++++++++-------- 4 files changed, 837 insertions(+), 495 deletions(-) diff --git a/sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/blob_options.hpp b/sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/blob_options.hpp index 3bdb01665..712a75845 100644 --- a/sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/blob_options.hpp +++ b/sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/blob_options.hpp @@ -153,7 +153,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobServiceClient::ListBlobContainers. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobServiceClient::ListBlobContainers. */ struct ListBlobContainersOptions { @@ -185,7 +185,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobServiceClient::GetUserDelegationKey. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobServiceClient::GetUserDelegationKey. */ struct GetUserDelegationKeyOptions { @@ -197,35 +197,35 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobServiceClient::SetProperties. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobServiceClient::SetProperties. */ struct SetServicePropertiesOptions { }; /** - * @brief Optional parameters for BlobServiceClient::GetProperties. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobServiceClient::GetProperties. */ struct GetServicePropertiesOptions { }; /** - * @brief Optional parameters for BlobServiceClient::GetAccountInfo. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobServiceClient::GetAccountInfo. */ struct GetAccountInfoOptions { }; /** - * @brief Optional parameters for BlobServiceClient::GetStatistics. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobServiceClient::GetStatistics. */ struct GetBlobServiceStatisticsOptions { }; /** - * @brief Optional parameters for BlobServiceClient::FindBlobsByTags. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobServiceClient::FindBlobsByTags. */ struct FindBlobsByTagsOptions { @@ -244,7 +244,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobContainerClient::Create. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobContainerClient::Create. */ struct CreateBlobContainerOptions { @@ -272,7 +272,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobContainerClient::Delete. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobContainerClient::Delete. */ struct DeleteBlobContainerOptions { @@ -283,7 +283,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobContainerClient::Undelete. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobContainerClient::Undelete. */ struct UndeleteBlobContainerOptions { @@ -295,7 +295,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobContainerClient::GetProperties. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobContainerClient::GetProperties. */ struct GetBlobContainerPropertiesOptions { @@ -306,7 +306,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobContainerClient::SetMetadata. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobContainerClient::SetMetadata. */ struct SetBlobContainerMetadataOptions { @@ -324,8 +324,8 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobContainerClient::ListBlobs and - * BlobContainerClient::ListBlobsByHierarchy. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobContainerClient::ListBlobs and + * #Azure::Storage::Blobs::BlobContainerClient::ListBlobsByHierarchy. */ struct ListBlobsOptions { @@ -357,7 +357,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobContainerClient::GetAccessPolicy. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobContainerClient::GetAccessPolicy. */ struct GetBlobContainerAccessPolicyOptions { @@ -368,7 +368,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobContainerClient::SetAccessPolicy. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobContainerClient::SetAccessPolicy. */ struct SetBlobContainerAccessPolicyOptions { @@ -391,7 +391,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::GetProperties. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::GetProperties. */ struct GetBlobPropertiesOptions { @@ -402,7 +402,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::SetHttpHeaders. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::SetHttpHeaders. */ struct SetBlobHttpHeadersOptions { @@ -413,7 +413,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::SetMetadata. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::SetMetadata. */ struct SetBlobMetadataOptions { @@ -424,7 +424,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::SetAccessTier. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::SetAccessTier. */ struct SetBlobAccessTierOptions { @@ -437,7 +437,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::StartCopyFromUri. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::StartCopyFromUri. */ struct StartBlobCopyFromUriOptions { @@ -479,7 +479,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::AbortCopyFromUri. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::AbortCopyFromUri. */ struct AbortBlobCopyFromUriOptions { @@ -490,7 +490,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::Download. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::Download. */ struct DownloadBlobOptions { @@ -512,7 +512,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::DownloadTo. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::DownloadTo. */ struct DownloadBlobToOptions { @@ -521,6 +521,9 @@ namespace Azure { namespace Storage { namespace Blobs { */ Azure::Nullable Range; + /** + * @brief Options for parallel transfer. + */ struct { /** @@ -543,7 +546,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::CreateSnapshot. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::CreateSnapshot. */ struct CreateBlobSnapshotOptions { @@ -562,7 +565,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::Delete. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::Delete. */ struct DeleteBlobOptions { @@ -580,14 +583,14 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::Undelete. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::Undelete. */ struct UndeleteBlobOptions { }; /** - * @brief Optional parameters for BlobLeaseClient::Acquire. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobLeaseClient::Acquire. */ struct AcquireLeaseOptions { @@ -598,7 +601,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobLeaseClient::Renew. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobLeaseClient::Renew. */ struct RenewLeaseOptions { @@ -609,7 +612,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobLeaseClient::Change. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobLeaseClient::Change. */ struct ChangeLeaseOptions { @@ -620,7 +623,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobLeaseClient::Release. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobLeaseClient::Release. */ struct ReleaseLeaseOptions { @@ -631,7 +634,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobLeaseClient::Break. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobLeaseClient::Break. */ struct BreakLeaseOptions { @@ -651,7 +654,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::SetTags. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::SetTags. */ struct SetBlobTagsOptions { @@ -662,7 +665,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlobClient::GetTags. + * @brief Optional parameters for #Azure::Storage::Blobs::BlobClient::GetTags. */ struct GetBlobTagsOptions { @@ -673,7 +676,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlockBlobClient::Upload. + * @brief Optional parameters for #Azure::Storage::Blobs::BlockBlobClient::Upload. */ struct UploadBlockBlobOptions { @@ -706,7 +709,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlockBlobClient::UploadFrom. + * @brief Optional parameters for #Azure::Storage::Blobs::BlockBlobClient::UploadFrom. */ struct UploadBlockBlobFromOptions { @@ -725,6 +728,9 @@ namespace Azure { namespace Storage { namespace Blobs { */ Azure::Nullable AccessTier; + /** + * @brief Options for parallel transfer. + */ struct { /** @@ -747,7 +753,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlockBlobClient::StageBlock. + * @brief Optional parameters for #Azure::Storage::Blobs::BlockBlobClient::StageBlock. */ struct StageBlockOptions { @@ -765,7 +771,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlockBlobClient::StageBlockFromUri. + * @brief Optional parameters for #Azure::Storage::Blobs::BlockBlobClient::StageBlockFromUri. */ struct StageBlockFromUriOptions { @@ -795,7 +801,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlockBlobClient::CommitBlockList. + * @brief Optional parameters for #Azure::Storage::Blobs::BlockBlobClient::CommitBlockList. */ struct CommitBlockListOptions { @@ -821,7 +827,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for BlockBlobClient::GetBlockList. + * @brief Optional parameters for #Azure::Storage::Blobs::BlockBlobClient::GetBlockList. */ struct GetBlockListOptions { @@ -840,7 +846,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for AppendBlobClient::Create. + * @brief Optional parameters for #Azure::Storage::Blobs::AppendBlobClient::Create. */ struct CreateAppendBlobOptions { @@ -861,7 +867,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for AppendBlobClient::AppendBlock. + * @brief Optional parameters for #Azure::Storage::Blobs::AppendBlobClient::AppendBlock. */ struct AppendBlockOptions { @@ -879,7 +885,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for AppendBlobClient::AppendBlockFromUri. + * @brief Optional parameters for #Azure::Storage::Blobs::AppendBlobClient::AppendBlockFromUri. */ struct AppendBlockFromUriOptions { @@ -902,7 +908,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for AppendBlobClient::Seal. + * @brief Optional parameters for #Azure::Storage::Blobs::AppendBlobClient::Seal. */ struct SealAppendBlobOptions { @@ -913,7 +919,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for PageBlobClient::Create. + * @brief Optional parameters for #Azure::Storage::Blobs::PageBlobClient::Create. */ struct CreatePageBlobOptions { @@ -945,7 +951,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for PageBlobClient::UploadPages. + * @brief Optional parameters for #Azure::Storage::Blobs::PageBlobClient::UploadPages. */ struct UploadPagesOptions { @@ -963,7 +969,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for PageBlobClient::UploadPagesFromUri. + * @brief Optional parameters for #Azure::Storage::Blobs::PageBlobClient::UploadPagesFromUri. */ struct UploadPagesFromUriOptions { @@ -981,7 +987,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for PageBlobClient::ClearPages. + * @brief Optional parameters for #Azure::Storage::Blobs::PageBlobClient::ClearPages. */ struct ClearPagesOptions { @@ -992,7 +998,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for PageBlobClient::Resize. + * @brief Optional parameters for #Azure::Storage::Blobs::PageBlobClient::Resize. */ struct ResizePageBlobOptions { @@ -1003,7 +1009,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for PageBlobClient::GetPageRanges. + * @brief Optional parameters for #Azure::Storage::Blobs::PageBlobClient::GetPageRanges. */ struct GetPageRangesOptions { @@ -1020,7 +1026,7 @@ namespace Azure { namespace Storage { namespace Blobs { }; /** - * @brief Optional parameters for PageBlobClient::StartCopyIncremental. + * @brief Optional parameters for #Azure::Storage::Blobs::PageBlobClient::StartCopyIncremental. */ struct StartBlobCopyIncrementalOptions { diff --git a/sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/blob_responses.hpp b/sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/blob_responses.hpp index fae6c69dd..d5f570cb7 100644 --- a/sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/blob_responses.hpp +++ b/sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/blob_responses.hpp @@ -29,54 +29,153 @@ namespace Azure { namespace Storage { namespace Models { + /** + * @brief Response type for #Azure::Storage::Blobs::BlobClient::DownloadTo. + */ struct DownloadBlobToResult { + /** + * The blob's type. + */ Models::BlobType BlobType; + + /** + * Indicates the range of bytes returned. + */ Azure::Core::Http::HttpRange ContentRange; + + /** + * Size of the blob. + */ int64_t BlobSize = 0; - Azure::Nullable TransactionalContentHash; // hash for the downloaded range + + /** + * The request may return a CRC64 or MD5 hash for the downloaded range of data. + */ + Azure::Nullable TransactionalContentHash; + + /** + * Details information of the downloaded blob. + */ DownloadBlobDetails Details; }; using UploadBlockBlobFromResult = UploadBlockBlobResult; + /** + * @brief Response type for #Azure::Storage::Blobs::BlobLeaseClient::Acquire. + */ struct AcquireLeaseResult { + /** + * The ETag contains a value that you can use to perform operations conditionally. + */ Azure::ETag ETag; + + /** + * The date/time that the blob was last modified. The date format follows RFC 1123. + */ Azure::DateTime LastModified; + + /** + * When you request a lease, the Blob service returns a unique lease ID. While the lease is + * active, you must include the lease ID with any request to write to the blob, or to renew, + * change, or release the lease. + */ std::string LeaseId; }; + /** + * @brief Response type for #Azure::Storage::Blobs::BlobLeaseClient::Break. + */ struct BreakLeaseResult { + /** + * The ETag contains a value that you can use to perform operations conditionally. + */ Azure::ETag ETag; + + /** + * The date/time that the blob was last modified. The date format follows RFC 1123. + */ Azure::DateTime LastModified; }; + /** + * @brief Response type for #Azure::Storage::Blobs::BlobLeaseClient::Change. + */ struct ChangeLeaseResult { + /** + * The ETag contains a value that you can use to perform operations conditionally. + */ Azure::ETag ETag; + + /** + * The date/time that the blob was last modified. The date format follows RFC 1123. + */ Azure::DateTime LastModified; + + /** + * When you request a lease, the Blob service returns a unique lease ID. While the lease is + * active, you must include the lease ID with any request to write to the blob, or to renew, + * change, or release the lease. + */ std::string LeaseId; }; + /** + * @brief Response type for #Azure::Storage::Blobs::BlobLeaseClient::Release. + */ struct ReleaseLeaseResult { + /** + * The ETag contains a value that you can use to perform operations conditionally. + */ Azure::ETag ETag; + + /** + * The date/time that the blob was last modified. The date format follows RFC 1123. + */ Azure::DateTime LastModified; }; + /** + * @brief Response type for #Azure::Storage::Blobs::BlobLeaseClient::Renew. + */ struct RenewLeaseResult { + /** + * The ETag contains a value that you can use to perform operations conditionally. + */ Azure::ETag ETag; + + /** + * The date/time that the blob was last modified. The date format follows RFC 1123. + */ Azure::DateTime LastModified; + + /** + * When you request a lease, the Blob service returns a unique lease ID. While the lease is + * active, you must include the lease ID with any request to write to the blob, or to renew, + * change, or release the lease. + */ std::string LeaseId; }; } // namespace Models + /** + * @brief A long-running operation to copy a blob. + */ class StartBlobCopyOperation : public Azure::Core::Operation { public: + /** + * @brief Get the #Azure::Storage::Blobs::Models::BlobProperties object, which includes the + * latest copy information. + * + * @return The #Azure::Storage::Blobs::Models::BlobProperties object. + */ Models::BlobProperties Value() const override { return m_pollResult; } StartBlobCopyOperation() = default; @@ -101,11 +200,6 @@ namespace Azure { namespace Storage { std::chrono::milliseconds period, Azure::Core::Context& context) override; - /** - * @brief Get the raw HTTP response. - * @return A reference to an #Azure::Core::Http::RawResponse. - * @note Does not give up ownership of the RawResponse. - */ Azure::Core::Http::RawResponse const& GetRawResponseInternal() const override { return *m_rawResponse; @@ -118,11 +212,25 @@ namespace Azure { namespace Storage { friend class Blobs::PageBlobClient; }; + /** + * @brief Response type for #Azure::Storage::Blobs::BlobServiceClient::ListBlobContainers. + */ class ListBlobContainersPagedResponse : public Azure::Core::PagedResponse { public: + /** + * Service endpoint. + */ std::string ServiceEndpoint; + + /** + * Container name prefix that's used to filter the result. + */ std::string Prefix; + + /** + * Blob container items. + */ std::vector BlobContainers; private: @@ -136,10 +244,20 @@ namespace Azure { namespace Storage { friend class Files::DataLake::ListFileSystemsPagedResponse; }; + /** + * @brief Response type for #Azure::Storage::Blobs::BlobServiceClient::FindBlobsByTags. + */ class FindBlobsByTagsPagedResponse : public Azure::Core::PagedResponse { public: + /** + * Service endpoint. + */ std::string ServiceEndpoint; + + /** + * Blob items filtered by tag. + */ std::vector TaggedBlobs; private: @@ -153,11 +271,29 @@ namespace Azure { namespace Storage { friend class PagedResponse; }; + /** + * @brief Response type for #Azure::Storage::Blobs::BlobContainerClient::ListBlobs. + */ class ListBlobsPagedResponse : public Azure::Core::PagedResponse { public: + /** + * Service endpoint. + */ std::string ServiceEndpoint; + + /** + * Name of the container. + */ std::string BlobContainerName; + + /** + * Blob name prefix that's used to filter the result. + */ std::string Prefix; + + /** + * Blob items. + */ std::vector Blobs; private: @@ -170,14 +306,41 @@ namespace Azure { namespace Storage { friend class PagedResponse; }; + /** + * @brief Response type for #Azure::Storage::Blobs::BlobContainerClient::ByHierarchy. + */ class ListBlobsByHierarchyPagedResponse : public Azure::Core::PagedResponse { public: + /** + * Service endpoint. + */ std::string ServiceEndpoint; + + /** + * Name of the container. + */ std::string BlobContainerName; + + /** + * Blob name prefix that's used to filter the result. + */ std::string Prefix; + + /** + * A character or a string used to traverse a virtual hierarchy of blobs as though it were a + * file system. + */ std::string Delimiter; + + /** + * Blob items. + */ std::vector Blobs; + + /** + * Blob prefix items. + */ std::vector BlobPrefixes; private: @@ -191,12 +354,30 @@ namespace Azure { namespace Storage { friend class PagedResponse; }; + /** + * @brief Response type for #Azure::Storage::Blobs::PageBlobClient::GetPageRanges. + */ class GetPageRangesPagedResponse : public Azure::Core::PagedResponse { public: + /** + * The ETag contains a value that you can use to perform operations conditionally. + */ Azure::ETag ETag; + + /** + * The date/time that the blob was last modified. The date format follows RFC 1123. + */ Azure::DateTime LastModified; + + /** + * Size of the blob. + */ int64_t BlobSize = 0; + + /** + * Page range items. + */ std::vector PageRanges; private: @@ -209,13 +390,36 @@ namespace Azure { namespace Storage { friend class PagedResponse; }; + /** + * @brief Response type for #Azure::Storage::Blobs::PageBlobClient::GetPageRangesDiff and + * #Azure::Storage::Blobs::PageBlobClient::GetManagedDiskPageRangesDiff. + */ class GetPageRangesDiffPagedResponse : public Azure::Core::PagedResponse { public: + /** + * The ETag contains a value that you can use to perform operations conditionally. + */ Azure::ETag ETag; + + /** + * The date/time that the blob was last modified. The date format follows RFC 1123. + */ Azure::DateTime LastModified; + + /** + * Size of the blob. + */ int64_t BlobSize = 0; + + /** + * Page range items. + */ std::vector PageRanges; + + /** + * Clear range items. + */ std::vector ClearRanges; private: diff --git a/sdk/storage/azure-storage-files-datalake/inc/azure/storage/files/datalake/datalake_options.hpp b/sdk/storage/azure-storage-files-datalake/inc/azure/storage/files/datalake/datalake_options.hpp index 517bc2fee..980605859 100644 --- a/sdk/storage/azure-storage-files-datalake/inc/azure/storage/files/datalake/datalake_options.hpp +++ b/sdk/storage/azure-storage-files-datalake/inc/azure/storage/files/datalake/datalake_options.hpp @@ -25,8 +25,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { using GetUserDelegationKeyOptions = Blobs::GetUserDelegationKeyOptions; /** - * @brief Client options used to initalize DataLakeServiceClient, FileSystemClient, PathClient, - * FileClient and DirectoryClient. + * @brief Client options used to initalize all DataLake clients. */ struct DataLakeClientOptions : Azure::Core::_internal::ClientOptions { @@ -62,7 +61,8 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for ServiceClient::ListFileSystemsOptions. + * @brief Optional parameters for + * #Azure::Storage::Files::DataLake::ServiceClient::ListFileSystems. */ struct ListFileSystemsOptions { @@ -95,7 +95,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for FileSystemClient::Create + * @brief Optional parameters for #Azure::Storage::Files::DataLake::FileSystemClient::Create. */ struct CreateFileSystemOptions { @@ -113,7 +113,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for FileSystemClient::Delete + * @brief Optional parameters for #Azure::Storage::Files::DataLake::FileSystemClient::Delete. */ struct DeleteFileSystemOptions { @@ -124,7 +124,8 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for FileSystemClient::GetProperties + * @brief Optional parameters for + * #Azure::Storage::Files::DataLake::FileSystemClient::GetProperties. */ struct GetFileSystemPropertiesOptions { @@ -135,7 +136,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for FileSystemClient::SetMetadata + * @brief Optional parameters for #Azure::Storage::Files::DataLake::FileSystemClient::SetMetadata. */ struct SetFileSystemMetadataOptions { @@ -146,7 +147,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for FileSystemClient::ListPaths + * @brief Optional parameters for #Azure::Storage::Files::DataLake::FileSystemClient::ListPaths. */ struct ListPathsOptions { @@ -180,7 +181,8 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for FileSystemClient::GetAccessPolicy. + * @brief Optional parameters for + * #Azure::Storage::Files::DataLake::FileSystemClient::GetAccessPolicy. */ struct GetFileSystemAccessPolicyOptions { @@ -191,7 +193,8 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for FileSystemClient::SetAccessPolicy. + * @brief Optional parameters for + * #Azure::Storage::Files::DataLake::FileSystemClient::SetAccessPolicy. */ struct SetFileSystemAccessPolicyOptions { @@ -214,7 +217,8 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for DataLakeFileSystemClient::RenameDirectory + * @brief Optional parameters for + * #Azure::Storage::Files::DataLake::DataLakeFileSystemClient::RenameDirectory. * @remark Some optional parameter is mandatory in certain combination. * More details: * https://docs.microsoft.com/en-us/rest/api/storageservices/datalakestoragegen2/path/create @@ -239,7 +243,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for PathClient::Append + * @brief Optional parameters for #Azure::Storage::Files::DataLake::PathClient::Append. */ struct AppendFileOptions { @@ -255,7 +259,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for PathClient::Flush + * @brief Optional parameters for #Azure::Storage::Files::DataLake::PathClient::Flush. */ struct FlushFileOptions { @@ -303,7 +307,8 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for PathClient::SetAccessControlList + * @brief Optional parameters for + * #Azure::Storage::Files::DataLake::PathClient::SetAccessControlList. */ struct SetPathAccessControlListOptions { @@ -324,7 +329,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for PathClient::SetPermissions + * @brief Optional parameters for #Azure::Storage::Files::DataLake::PathClient::SetPermissions. */ struct SetPathPermissionsOptions { @@ -345,7 +350,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for PathClient::SetHttpHeaders + * @brief Optional parameters for #Azure::Storage::Files::DataLake::PathClient::SetHttpHeaders. */ struct SetPathHttpHeadersOptions { @@ -356,7 +361,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for PathClient::SetMetadata + * @brief Optional parameters for #Azure::Storage::Files::DataLake::PathClient::SetMetadata. */ struct SetPathMetadataOptions { @@ -367,7 +372,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for PathClient::Create + * @brief Optional parameters for #Azure::Storage::Files::DataLake::PathClient::Create. * @remark Some optional parameter is mandatory in certain combination. * More details: * https://docs.microsoft.com/en-us/rest/api/storageservices/datalakestoragegen2/path/create @@ -417,7 +422,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for DirectoryClient::Delete + * @brief Optional parameters for #Azure::Storage::Files::DataLake::DirectoryClient::Delete. * @remark Some optional parameter is mandatory in certain combination. * More details: * https://docs.microsoft.com/en-us/rest/api/storageservices/datalakestoragegen2/path/delete @@ -438,7 +443,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for PathClient::GetProperties + * @brief Optional parameters for #Azure::Storage::Files::DataLake::PathClient::GetProperties. * @remark Some optional parameter is mandatory in certain combination. * More details: * https://docs.microsoft.com/en-us/rest/api/storageservices/datalakestoragegen2/path/getproperties @@ -452,7 +457,8 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for PathClient::GetAccessControlList + * @brief Optional parameters for + * #Azure::Storage::Files::DataLake::PathClient::GetAccessControlList. */ struct GetPathAccessControlListOptions { @@ -463,7 +469,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for PathClient::Read + * @brief Optional parameters for #Azure::Storage::Files::DataLake::PathClient::Read. * @remark Some optional parameter is mandatory in certain combination. * More details: * https://docs.microsoft.com/en-us/rest/api/storageservices/datalakestoragegen2/path/read @@ -487,7 +493,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for FileClient::Create + * @brief Optional parameters for #Azure::Storage::Files::DataLake::FileClient::Create. */ struct RenameFileOptions { @@ -509,7 +515,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { }; /** - * @brief Optional parameters for FileClient::Delete + * @brief Optional parameters for #Azure::Storage::Files::DataLake::FileClient::Delete. */ struct DeleteFileOptions { @@ -522,7 +528,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { using RenameSubdirectoryOptions = RenameDirectoryOptions; /** - * @brief Optional parameters for DirectoryClient::Delete + * @brief Optional parameters for #Azure::Storage::Files::DataLake::DirectoryClient::Delete. */ struct DeleteDirectoryOptions { @@ -536,7 +542,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { using CreateDirectoryOptions = CreatePathOptions; /** - * @brief Optional parameters for FileClient::UploadFromBuffer and FileClient::UploadFromFile + * @brief Optional parameters for #Azure::Storage::Files::DataLake::FileClient::UploadFrom. */ struct UploadFileFromOptions { @@ -550,6 +556,9 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { */ Storage::Metadata Metadata; + /** + * @brief Options for parallel transfer. + */ struct { /** @@ -574,7 +583,7 @@ namespace Azure { namespace Storage { namespace Files { namespace DataLake { using ScheduleFileExpiryOriginType = Blobs::Models::ScheduleBlobExpiryOriginType; /** - * @brief Optional parameters for FileClient::UploadFromBuffer and FileClient::UploadFromFile + * @brief Optional parameters for #Azure::Storage::Files::DataLake::FileClient::UploadFrom. */ struct ScheduleFileDeletionOptions { diff --git a/sdk/storage/azure-storage-files-shares/inc/azure/storage/files/shares/share_options.hpp b/sdk/storage/azure-storage-files-shares/inc/azure/storage/files/shares/share_options.hpp index 2751c384b..b10eceffd 100644 --- a/sdk/storage/azure-storage-files-shares/inc/azure/storage/files/shares/share_options.hpp +++ b/sdk/storage/azure-storage-files-shares/inc/azure/storage/files/shares/share_options.hpp @@ -16,8 +16,7 @@ namespace Azure { namespace Storage { namespace Files { namespace Shares { /** - * @brief Client options used to initalize ShareServiceClient, ShareClient, ShareFileClient and - * ShareDirectoryClient. + * @brief Client options used to initalize share clients. */ struct ShareClientOptions : Azure::Core::_internal::ClientOptions { @@ -27,16 +26,19 @@ namespace Azure { namespace Storage { namespace Files { namespace Shares { std::string ApiVersion = _detail::DefaultServiceApiVersion; }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareServiceClient::ListShares. + */ struct ListSharesOptions { /** - * @brief Filters the results to return only entries whose name begins with the specified + * Filters the results to return only entries whose name begins with the specified * prefix. */ Azure::Nullable Prefix; /** - * @brief A string value that identifies the portion of the list to be returned with the next + * A string value that identifies the portion of the list to be returned with the next * list operation. The operation returns a marker value within the response body if the list * returned was not complete. The marker value may then be used in a subsequent call to request * the next set of list items. The marker value is opaque to the client. @@ -44,131 +46,644 @@ namespace Azure { namespace Storage { namespace Files { namespace Shares { Azure::Nullable ContinuationToken; /** - * @brief Specifies the maximum number of entries to return. If the request does not specify + * Specifies the maximum number of entries to return. If the request does not specify * PageSizeHint, or specifies a value greater than 5,000, the server will return up to 5,000 * items. */ Azure::Nullable PageSizeHint; /** - * @brief Include this parameter to specify one or more datasets to include in the response. + * Include this parameter to specify one or more datasets to include in the response. */ Azure::Nullable ListSharesIncludeFlags; }; + /** + * @brief Optional parameters for + * #Azure::Storage::Files::Shares::ShareServiceClient::SetProperties. + */ struct SetServicePropertiesOptions { }; + /** + * @brief Optional parameters for + * #Azure::Storage::Files::Shares::ShareServiceClient::GetProperties. + */ struct GetServicePropertiesOptions { }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::Create. + */ struct CreateShareOptions { /** - * @brief A name-value pair to associate with a file storage object. + * A name-value pair to associate with a file storage object. */ Storage::Metadata Metadata; /** - * @brief Specifies the access tier of the share. This is only valid for standard file account + * Specifies the access tier of the share. This is only valid for standard file account * and the value can only be one of `Hot`, `Cool` or `TransactionOptimized` */ Azure::Nullable AccessTier; /** - * @brief Specifies the maximum size of the share, in gigabytes. + * Specifies the maximum size of the share, in gigabytes. */ Azure::Nullable ShareQuotaInGiB; }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::Delete. + */ struct DeleteShareOptions { /** - * @brief Specifies the option include to delete the base share and all of its snapshots. + * Specifies the option include to delete the base share and all of its snapshots. */ Azure::Nullable DeleteSnapshots; }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::CreateSnapshot. + */ struct CreateShareSnapshotOptions { /** - * @brief The metadata to be set on the snapshot of the share. + * The metadata to be set on the snapshot of the share. */ Storage::Metadata Metadata; }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::GetProperties. + */ struct GetSharePropertiesOptions { }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::SetProperties. + */ struct SetSharePropertiesOptions { /** - * @brief Specifies the access tier of the share. This is only valid for standard file account + * Specifies the access tier of the share. This is only valid for standard file account * and the value can only be one of `Hot`, `Cool` or `TransactionOptimized` */ Azure::Nullable AccessTier; /** - * @brief Specifies the maximum size of the share, in gigabytes. + * Specifies the maximum size of the share, in gigabytes. */ Azure::Nullable ShareQuotaInGiB; }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::SetMetadata. + */ struct SetShareMetadataOptions { }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::GetAccessPolicy. + */ struct GetShareAccessPolicyOptions { }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::SetAccessPolicy. + */ struct SetShareAccessPolicyOptions { }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::GetStatistics. + */ struct GetShareStatisticsOptions { }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::CreatePermission. + */ struct CreateSharePermissionOptions { }; + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareClient::GetPermission. + */ struct GetSharePermissionOptions { }; /** - * @brief Optional parameters for ShareClient::AcquireLease. + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareDirectoryClient::Create. + */ + struct CreateDirectoryOptions + { + /** + * A name-value pair to associate with a directory object. + */ + Storage::Metadata Metadata; + + /** + * This permission is the security descriptor for the directory specified in the Security + * Descriptor Definition Language (SDDL). If not specified, 'inherit' is used. + */ + Azure::Nullable DirectoryPermission; + + /** + * SMB properties to set for the directory. + */ + Models::FileSmbProperties SmbProperties; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareDirectoryClient::Delete. + */ + struct DeleteDirectoryOptions + { + }; + + /** + * @brief Optional parameters for + * #Azure::Storage::Files::Shares::ShareDirectoryClient::GetProperties. + */ + struct GetDirectoryPropertiesOptions + { + }; + + /** + * @brief Optional parameters for + * #Azure::Storage::Files::Shares::ShareDirectoryClient::SetProperties. + */ + struct SetDirectoryPropertiesOptions + { + /** + * If specified the permission (security descriptor) shall be set for the directory. + * This option can be used if Permission size is <= 8KB, else SmbProperties.PermissionKey + * shall be used. Default value: 'inherit'. If SDDL is specified as input, it must have owner, + * group and dacl. + */ + Azure::Nullable FilePermission; + }; + + /** + * @brief Optional parameters for + * #Azure::Storage::Files::Shares::ShareDirectoryClient::SetMetadata. + */ + struct SetDirectoryMetadataOptions + { + }; + + /** + * @brief Optional parameters for + * #Azure::Storage::Files::Shares::ShareDirectoryClient::ListFilesAndDirectories. + */ + struct ListFilesAndDirectoriesOptions + { + /** + * Filters the results to return only entries whose name begins with the specified + * prefix. + */ + Azure::Nullable Prefix; + + /** + * A string value that identifies the portion of the list to be returned with the next + * list operation. The operation returns a marker value within the response body if the list + * returned was not complete. The marker value may then be used in a subsequent call to request + * the next set of list items. The marker value is opaque to the client. + */ + Azure::Nullable ContinuationToken; + + /** + * Specifies the maximum number of entries to return. If the request does not specify + * PageSizeHint, or specifies a value greater than 5,000, the server will return up to 5,000 + * items. + */ + Azure::Nullable PageSizeHint; + }; + + /** + * @brief Optional parameters for + * #Azure::Storage::Files::Shares::ShareDirectoryClient::ListHandles. + */ + struct ListDirectoryHandlesOptions + { + /** + * A string value that identifies the portion of the list to be returned with the next + * list operation. The operation returns a marker value within the response body if the list + * returned was not complete. The marker value may then be used in a subsequent call to request + * the next set of list items. The marker value is opaque to the client. + */ + Azure::Nullable ContinuationToken; + + /** + * Specifies the maximum number of entries to return. If the request does not specify + * PageSizeHint, or specifies a value greater than 5,000, the server will return up to 5,000 + * items. + */ + Azure::Nullable PageSizeHint; + + /** + * Specifies operation should apply to the directory specified in the URI, its files, its + * subdirectories and their files. + */ + Azure::Nullable Recursive; + }; + + /** + * @brief Optional parameters for + * #Azure::Storage::Files::Shares::ShareDirectoryClient::ForceCloseHandle. + */ + struct ForceCloseDirectoryHandleOptions + { + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::Create. + */ + struct CreateFileOptions + { + /** + * This permission is the security descriptor for the file specified in the Security + * Descriptor Definition Language (SDDL). If not specified, 'inherit' is used. + */ + Azure::Nullable Permission; + + /** + * SMB properties to set for the file. + */ + Models::FileSmbProperties SmbProperties; + + /** + * Specifies the HttpHeaders of the file. + */ + Models::FileHttpHeaders HttpHeaders; + + /** + * A name-value pair to associate with a file storage object. + */ + Storage::Metadata Metadata; + + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::Delete. + */ + struct DeleteFileOptions + { + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::Download. + */ + struct DownloadFileOptions + { + /** + * Downloads only the bytes of the file from this range. + */ + Azure::Nullable Range; + + /** + * When specified together with Range, service returns hash for the range as long as the + * range is less than or equal to 4 MiB in size. Only MD5 is supported for now. + */ + Azure::Nullable RangeHashAlgorithm; + + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::StartCopy. + */ + struct StartFileCopyOptions + { + /** + * A name-value pair to associate with a file storage object. + */ + Storage::Metadata Metadata; + + /** + * This permission is the security descriptor for the file specified in the Security + * Descriptor Definition Language (SDDL). If not specified, 'inherit' is used. + */ + Azure::Nullable Permission; + + /** + * SMB properties to set for the destination file. + */ + Models::FileSmbProperties SmbProperties; + + /** + * Specifies the option to copy file security descriptor from source file or to set it + * using the value which is defined by the smb properties. + */ + Azure::Nullable PermissionCopyMode; + + /** + * Specifies the option to overwrite the target file if it already exists and has + * read-only attribute set. + */ + Azure::Nullable IgnoreReadOnly; + + /** + * Specifies the option to set archive attribute on a target file. True means archive + * attribute will be set on a target file despite attribute overrides or a source file state. + */ + Azure::Nullable SetArchiveAttribute; + + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::AbortCopy. + */ + struct AbortFileCopyOptions + { + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::GetProperties. + */ + struct GetFilePropertiesOptions + { + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::SetProperties. + */ + struct SetFilePropertiesOptions + { + /** + * This permission is the security descriptor for the file specified in the Security + * Descriptor Definition Language (SDDL). If not specified, 'inherit' is used. + */ + Azure::Nullable Permission; + + /** + * Specify this to resize a file to the specified value. + */ + Azure::Nullable Size; + + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::SetMetadata. + */ + struct SetFileMetadataOptions + { + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::UploadRange. + */ + struct UploadFileRangeOptions + { + /** + * An MD5 hash of the content. This hash is used to verify the integrity of the data + * during transport. When the TransactionalContentHash parameter is specified, the File service + * compares the hash of the content that has arrived with the header value that was sent. If the + * two hashes do not match, the operation will fail with error code 400 (Bad Request). + */ + Azure::Nullable TransactionalContentHash; + + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::ClearRange. + */ + struct ClearFileRangeOptions + { + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for + * #Azure::Storage::Files::Shares::ShareFileClient::UploadRangeFromUri. + */ + struct UploadFileRangeFromUriOptions + { + /** + * Specify the hash calculated for the range of bytes that must be read from the copy + * source. + */ + Azure::Nullable TransactionalContentHash; + + /** + * Specify the access condition for the source. Only ContentHash with Crc64 is supported. + */ + ContentHashAccessConditions SourceAccessCondition; + + /** + * The operation will only succeed if the lease access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::GetRangeList. + */ + struct GetFileRangeListOptions + { + /** + * The range to be get from service. + */ + Azure::Nullable Range; + + /** + * The operation will only succeed if the access condition is met. + */ + LeaseAccessConditions AccessConditions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::ListHandles. + */ + struct ListFileHandlesOptions + { + /** + * A string value that identifies the portion of the list to be returned with the next + * list operation. The operation returns a marker value within the response body if the list + * returned was not complete. The marker value may then be used in a subsequent call to request + * the next set of list items. The marker value is opaque to the client. + */ + Azure::Nullable ContinuationToken; + + /** + * Specifies the maximum number of entries to return. If the request does not specify + * PageSizeHint, or specifies a value greater than 5,000, the server will return up to 5,000 + * items. + */ + Azure::Nullable PageSizeHint; + }; + + /** + * @brief Optional parameters for + * #Azure::Storage::Files::Shares::ShareFileClient::ForceCloseHandle. + */ + struct ForceCloseFileHandleOptions + { + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::DownloadTo. + */ + struct DownloadFileToOptions + { + /** + * Downloads only the bytes of the file from this range. + */ + Azure::Nullable Range; + + /** + * @brief Options for parallel transfer. + */ + struct + { + /** + * The size of the first range request in bytes. Files smaller than this limit will be + * downloaded in a single request. Files larger than this limit will continue being downloaded + * in chunks of size ChunkSize. + */ + int64_t InitialChunkSize = 256 * 1024 * 1024; + + /** + * The maximum number of bytes in a single request. + */ + int64_t ChunkSize = 4 * 1024 * 1024; + + /** + * The maximum number of threads that may be used in a parallel transfer. + */ + int Concurrency = 5; + } TransferOptions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareFileClient::UploadFrom. + */ + struct UploadFileFromOptions + { + /** + * The standard HTTP header system properties to set. + */ + Models::FileHttpHeaders HttpHeaders; + + /** + * Name-value pairs associated with the file as metadata. + */ + Storage::Metadata Metadata; + + /** + * SMB properties to set for the destination file. + */ + Models::FileSmbProperties SmbProperties; + + /** + * If specified the permission (security descriptor) shall be set for the directory. + * This option can be used if Permission size is <= 8KB, else SmbProperties.PermissionKey + * shall be used. Default value: 'inherit'. If SDDL is specified as input, it must have owner, + * group and dacl. + */ + Azure::Nullable FilePermission; + + /** + * @brief Options for parallel transfer. + */ + struct + { + /** + * File smaller than this will be uploaded with a single upload operation. This value + * cannot be larger than 4 MiB. + */ + int64_t SingleUploadThreshold = 4 * 1024 * 1024; + + /** + * The maximum number of bytes in a single request. + */ + int64_t ChunkSize = 4 * 1024 * 1024; + + /** + * The maximum number of threads that may be used in a parallel transfer. + */ + int Concurrency = 5; + } TransferOptions; + }; + + /** + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareLeaseClient::Acquire. */ struct AcquireLeaseOptions { }; /** - * @brief Optional parameters for ShareClient::ChangeLease. + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareLeaseClient::Change. */ struct ChangeLeaseOptions { }; /** - * @brief Optional parameters for ShareClient::ReleaseLease. + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareLeaseClient::Release. */ struct ReleaseLeaseOptions { }; /** - * @brief Optional parameters for ShareClient::BreakLease. + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareLeaseClient::Break. */ struct BreakLeaseOptions { /** - * @brief Proposed duration the lease should continue before it is broken, in seconds, + * Proposed duration the lease should continue before it is broken, in seconds, * between 0 and 60. This break period is only used if it is shorter than the time remaining on * the lease. If longer, the time remaining on the lease is used. A new lease will not be * available before the break period has expired, but the lease may be held for longer than the @@ -178,401 +693,9 @@ namespace Azure { namespace Storage { namespace Files { namespace Shares { }; /** - * @brief Optional parameters for ShareClient::BreakLease. + * @brief Optional parameters for #Azure::Storage::Files::Shares::ShareLeaseClient::Renew. */ struct RenewLeaseOptions { }; - - struct CreateDirectoryOptions - { - /** - * @brief A name-value pair to associate with a directory object. - */ - Storage::Metadata Metadata; - - /** - * @brief This permission is the security descriptor for the directory specified in the Security - * Descriptor Definition Language (SDDL). If not specified, 'inherit' is used. - */ - Azure::Nullable DirectoryPermission; - - /** - * @brief SMB properties to set for the directory. - */ - Models::FileSmbProperties SmbProperties; - }; - - struct DeleteDirectoryOptions - { - }; - - struct GetDirectoryPropertiesOptions - { - }; - - struct SetDirectoryPropertiesOptions - { - /** - * @brief If specified the permission (security descriptor) shall be set for the directory. - * This option can be used if Permission size is <= 8KB, else SmbProperties.PermissionKey - * shall be used. Default value: 'inherit'. If SDDL is specified as input, it must have owner, - * group and dacl. - */ - Azure::Nullable FilePermission; - }; - - struct SetDirectoryMetadataOptions - { - }; - - struct ListFilesAndDirectoriesOptions - { - /** - * @brief Filters the results to return only entries whose name begins with the specified - * prefix. - */ - Azure::Nullable Prefix; - - /** - * @brief A string value that identifies the portion of the list to be returned with the next - * list operation. The operation returns a marker value within the response body if the list - * returned was not complete. The marker value may then be used in a subsequent call to request - * the next set of list items. The marker value is opaque to the client. - */ - Azure::Nullable ContinuationToken; - - /** - * @brief Specifies the maximum number of entries to return. If the request does not specify - * PageSizeHint, or specifies a value greater than 5,000, the server will return up to 5,000 - * items. - */ - Azure::Nullable PageSizeHint; - }; - - struct ListDirectoryHandlesOptions - { - /** - * @brief A string value that identifies the portion of the list to be returned with the next - * list operation. The operation returns a marker value within the response body if the list - * returned was not complete. The marker value may then be used in a subsequent call to request - * the next set of list items. The marker value is opaque to the client. - */ - Azure::Nullable ContinuationToken; - - /** - * @brief Specifies the maximum number of entries to return. If the request does not specify - * PageSizeHint, or specifies a value greater than 5,000, the server will return up to 5,000 - * items. - */ - Azure::Nullable PageSizeHint; - - /** - * @brief Specifies operation should apply to the directory specified in the URI, its files, its - * subdirectories and their files. - */ - Azure::Nullable Recursive; - }; - - struct ForceCloseDirectoryHandleOptions - { - }; - - struct CreateFileOptions - { - /** - * @brief This permission is the security descriptor for the file specified in the Security - * Descriptor Definition Language (SDDL). If not specified, 'inherit' is used. - */ - Azure::Nullable Permission; - - /** - * @brief SMB properties to set for the file. - */ - Models::FileSmbProperties SmbProperties; - - /** - * @brief Specifies the HttpHeaders of the file. - */ - Models::FileHttpHeaders HttpHeaders; - - /** - * @brief A name-value pair to associate with a file storage object. - */ - Storage::Metadata Metadata; - - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct DeleteFileOptions - { - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct DownloadFileOptions - { - /** - * @brief Downloads only the bytes of the file from this range. - */ - Azure::Nullable Range; - - /** - * @brief When specified together with Range, service returns hash for the range as long as the - * range is less than or equal to 4 MiB in size. Only MD5 is supported for now. - */ - Azure::Nullable RangeHashAlgorithm; - - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct StartFileCopyOptions - { - /** - * @brief A name-value pair to associate with a file storage object. - */ - Storage::Metadata Metadata; - - /** - * @brief This permission is the security descriptor for the file specified in the Security - * Descriptor Definition Language (SDDL). If not specified, 'inherit' is used. - */ - Azure::Nullable Permission; - - /** - * @brief SMB properties to set for the destination file. - */ - Models::FileSmbProperties SmbProperties; - - /** - * @brief Specifies the option to copy file security descriptor from source file or to set it - * using the value which is defined by the smb properties. - */ - Azure::Nullable PermissionCopyMode; - - /** - * @brief Specifies the option to overwrite the target file if it already exists and has - * read-only attribute set. - */ - Azure::Nullable IgnoreReadOnly; - - /** - * @brief Specifies the option to set archive attribute on a target file. True means archive - * attribute will be set on a target file despite attribute overrides or a source file state. - */ - Azure::Nullable SetArchiveAttribute; - - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct AbortFileCopyOptions - { - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct GetFilePropertiesOptions - { - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct SetFilePropertiesOptions - { - /** - * @brief This permission is the security descriptor for the file specified in the Security - * Descriptor Definition Language (SDDL). If not specified, 'inherit' is used. - */ - Azure::Nullable Permission; - - /** - * @brief Specify this to resize a file to the specified value. - */ - Azure::Nullable Size; - - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct SetFileMetadataOptions - { - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct UploadFileRangeOptions - { - /** - * @brief An MD5 hash of the content. This hash is used to verify the integrity of the data - * during transport. When the TransactionalContentHash parameter is specified, the File service - * compares the hash of the content that has arrived with the header value that was sent. If the - * two hashes do not match, the operation will fail with error code 400 (Bad Request). - */ - Azure::Nullable TransactionalContentHash; - - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct ClearFileRangeOptions - { - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct UploadFileRangeFromUriOptions - { - /** - * @brief Specify the hash calculated for the range of bytes that must be read from the copy - * source. - */ - Azure::Nullable TransactionalContentHash; - - /** - * @brief Specify the access condition for the source. Only ContentHash with Crc64 is supported. - */ - ContentHashAccessConditions SourceAccessCondition; - - /** - * @brief The operation will only succeed if the lease access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct GetFileRangeListOptions - { - /** - * @brief The range to be get from service. - */ - Azure::Nullable Range; - - /** - * @brief The operation will only succeed if the access condition is met. - */ - LeaseAccessConditions AccessConditions; - }; - - struct ListFileHandlesOptions - { - /** - * @brief A string value that identifies the portion of the list to be returned with the next - * list operation. The operation returns a marker value within the response body if the list - * returned was not complete. The marker value may then be used in a subsequent call to request - * the next set of list items. The marker value is opaque to the client. - */ - Azure::Nullable ContinuationToken; - - /** - * @brief Specifies the maximum number of entries to return. If the request does not specify - * PageSizeHint, or specifies a value greater than 5,000, the server will return up to 5,000 - * items. - */ - Azure::Nullable PageSizeHint; - }; - - struct ForceCloseFileHandleOptions - { - }; - - /** - * @brief Optional parameters for FileClient::DownloadTo. - */ - struct DownloadFileToOptions - { - /** - * @brief Downloads only the bytes of the file from this range. - */ - Azure::Nullable Range; - - struct - { - /** - * @brief The size of the first range request in bytes. Files smaller than this limit will be - * downloaded in a single request. Files larger than this limit will continue being downloaded - * in chunks of size ChunkSize. - */ - int64_t InitialChunkSize = 256 * 1024 * 1024; - - /** - * @brief The maximum number of bytes in a single request. - */ - int64_t ChunkSize = 4 * 1024 * 1024; - - /** - * @brief The maximum number of threads that may be used in a parallel transfer. - */ - int Concurrency = 5; - } TransferOptions; - }; - - /** - * @brief Optional parameters for FileClient::UploadFrom. - */ - struct UploadFileFromOptions - { - /** - * @brief The standard HTTP header system properties to set. - */ - Models::FileHttpHeaders HttpHeaders; - - /** - * @brief Name-value pairs associated with the file as metadata. - */ - Storage::Metadata Metadata; - - /** - * @brief SMB properties to set for the destination file. - */ - Models::FileSmbProperties SmbProperties; - - /** - * @brief If specified the permission (security descriptor) shall be set for the directory. - * This option can be used if Permission size is <= 8KB, else SmbProperties.PermissionKey - * shall be used. Default value: 'inherit'. If SDDL is specified as input, it must have owner, - * group and dacl. - */ - Azure::Nullable FilePermission; - - struct - { - /** - * @brief File smaller than this will be uploaded with a single upload operation. This value - * cannot be larger than 4 MiB. - */ - int64_t SingleUploadThreshold = 4 * 1024 * 1024; - - /** - * @brief The maximum number of bytes in a single request. - */ - int64_t ChunkSize = 4 * 1024 * 1024; - - /** - * @brief The maximum number of threads that may be used in a parallel transfer. - */ - int Concurrency = 5; - } TransferOptions; - }; }}}} // namespace Azure::Storage::Files::Shares