This commit is contained in:
Mike Battista 2024-05-07 12:51:37 -07:00
Родитель d794cd4b79
Коммит 6e23b3aaea
1 изменённых файлов: 1 добавлений и 0 удалений

Просмотреть файл

@ -56,6 +56,7 @@ DISCLAIMER: This list is a work in progress and is not yet comprehensive.
* Reserved parameters are decorated with the `[Reserved]` attribute. Since reserved parameters always expect a `NULL` value, projections can choose to abstract away these parameters to improve the developer experience.
* Pointer parameters that represent arrays are decorated with the `[NativeArrayInfo]` attribute that can contain the size of a fixed-length array (`CountConst`), the 0-based index of the parameter that defines the size of the array (`CountParamIndex`), or the struct field name (`CountFieldName`) that defines the size of the array
* Pointer parameters whose byte size must be specified in another parameter are decorated with the `[MemorySize]` attribute that will contain the 0-based index of the parameter that can be automatically populated with the size of the provided pointer parameter (`BytesParamIndex`) ([#284](https://github.com/microsoft/win32metadata/issues/284))
* Pointer parameters for `OVERLAPPED` operations are decorated with the `[Retained]` attribute when the pointers must remain allocated throughout the lifetime of the [asynchronous operation](https://learn.microsoft.com/windows/win32/fileio/synchronous-and-asynchronous-i-o) ([#1726](https://github.com/microsoft/win32metadata/issues/1726))
* Parameters that accept values from an enum but have conflicting types are decorated with the `[AssociatedEnum]` attribute indicating the enum that may be used with the parameter. The enum must exist in the same namespace as the API. This enables the metadata to preserve the original API definition while allowing projections to improve usability of the API with the enum if they choose. ([#1502](https://github.com/microsoft/win32metadata/issues/1502))
* Output parameters that must be closed with a specific function are decorated with the `[FreeWith]` attribute
* Handle parameters or return values that are unowned and should not be closed are decorated with the `[DoNotRelease]` attribute ([#1622](https://github.com/microsoft/win32metadata/issues/1622))