diff options
author | 2020-10-15 12:52:01 +0200 | |
---|---|---|
committer | 2020-10-30 16:51:00 +0100 | |
commit | ac6db7788a8dfd6e7658427be6d034cadb50081c (patch) | |
tree | e5830e0426b4e30905299f8c1345f4570d3543a2 /api/resource.h | |
parent | api: log out-of-memory errors too (diff) | |
download | wintun-ac6db7788a8dfd6e7658427be6d034cadb50081c.tar.xz wintun-ac6db7788a8dfd6e7658427be6d034cadb50081c.zip |
api: move documentation to .h and discontinue on static functions
While Doxygen correctly locates the function documentation when it is
written directly preceding the function body, Microsoft Visual Studio
IDE does not. The former requires the documentation to precede the
function declaration.
Signed-off-by: Simon Rozman <simon@rozman.si>
Diffstat (limited to 'api/resource.h')
-rw-r--r-- | api/resource.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/api/resource.h b/api/resource.h index 2ee2547..5021490 100644 --- a/api/resource.h +++ b/api/resource.h @@ -8,9 +8,31 @@ #include "api.h" #include <Windows.h> +/** + * Locates RT_RCDATA resource memory address and size. + * + * ResourceName Name of the RT_RCDATA resource. Use MAKEINTRESOURCEW to locate resource by ID. + * + * Address Pointer to a pointer variable to receive resource address. + * + * Size Pointer to a variable to receive resource size. + * + * @return ERROR_SUCCESS on success; Win32 error code otherwise. + */ WINTUN_STATUS ResourceGetAddress(_In_z_ const WCHAR *ResourceName, _Out_ const VOID **Address, _Out_ DWORD *Size); +/** + * Copies resource to a file. + * + * DestinationPath File path + * + * SecurityAttributes File security attributes. May be NULL for detault. + * + * ResourceName Name of the RT_RCDATA resource. Use MAKEINTRESOURCEW to locate resource by ID. + * + * @return ERROR_SUCCESS on success; Win32 error code otherwise. + */ WINTUN_STATUS ResourceCopyToFile( _In_z_ const WCHAR *DestinationPath, |