Azure / azure-storage-cpp

Microsoft Azure Storage Client Library for C++
http://azure.github.io/azure-storage-cpp
Apache License 2.0
132 stars 147 forks source link

cloud_file_attribute mapping of NTFS File Attribute do not have the same int values #362

Open balajiko1 opened 4 years ago

balajiko1 commented 4 years ago

The NTFS file attribute and the Azure Storage CPP Azure File cloud attribute do not have the same int values and makes it difficult for the clients and results in clients making such a mapping.

enum cloud_file_attributes : uint64_t
{ preserve = 0x0, source = 0x1, none = 0x2, readonly = 0x4, hidden = 0x8, system = 0x10, directory = 0x20, archive = 0x40, temporary = 0x80, offline = 0x100, not_content_indexed = 0x200, no_scrub_data = 0x400, };

And the appropriate File attributes:

define FILE_ATTRIBUTE_READONLY 0x00000001

define FILE_ATTRIBUTE_HIDDEN 0x00000002

define FILE_ATTRIBUTE_SYSTEM 0x00000004

define FILE_ATTRIBUTE_DIRECTORY 0x00000010

define FILE_ATTRIBUTE_ARCHIVE 0x00000020

define FILE_ATTRIBUTE_DEVICE 0x00000040

define FILE_ATTRIBUTE_NORMAL 0x00000080

define FILE_ATTRIBUTE_TEMPORARY 0x00000100

define FILE_ATTRIBUTE_SPARSE_FILE 0x00000200

define FILE_ATTRIBUTE_REPARSE_POINT 0x00000400

define FILE_ATTRIBUTE_COMPRESSED 0x00000800

define FILE_ATTRIBUTE_OFFLINE 0x00001000

define FILE_ATTRIBUTE_NOT_CONTENT_INDEXED 0x00002000