[#BloombergLP-bdls-FilesystemUtil_WindowsImpUtil]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdls.adoc[bdls]::FilesystemUtil&lowbar;WindowsImpUtil
:relfileprefix: ../../
:mrdocs:

Namespace for `FilesystemUtil` Windows implementation details&period;

== Synopsis

Declared in `&lt;bdls&lowbar;filesystemutil&lowbar;windowsimputil&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;class WINDOWS&lowbar;INTERFACE&gt;
struct FilesystemUtil&lowbar;WindowsImpUtil;
----

== Description

This component&hyphen;private utility `struct` provides a namespace for a suite of functions that `FilesystemUtil` uses as implementation details&period; These functions have a `WINDOWS&lowbar;INTERFACE` template parameter, which provides access to the entities that Windows systems declare, and that the function implementations need&period;

The program is ill&hyphen;formed unless the specified `WINDOWS&lowbar;INTERFACE` is a class type that meets the following requirements&colon;

&ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;BOOL` is a type alias to the `BOOL` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;DWORD` is a type alias to the `DWORD` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;FILETIME` is a type alias to the `FILETIME` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;HANDLE` is a type alias to the `HANDLE` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;INT64` is a type alias to the `IN64` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;LPFILETIME` is a type alias to the `LPFILETIME` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;SYSTEMTIME` is a type alias to the `LPFILETIME` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;ULARGE&lowbar;INTEGER` is a type alias to the `ULARGE&lowbar;INTEGER` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;ULONG64` is a type alias to the `ULONG64` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;ULONGLONG` is a type alias to the `ULONGLONG` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;WORD` is a type alias to the `WORD` type provided by the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;FileTimeToSystemTime` is a public, static member function that has `BOOL (const FILETIME &ast;lpFileTime, LPSYSTEMTIME lpSystemTime)` type and whose contract is to return the result of `&colon;&colon;FileTimeToSystemTime(lpFileTime, lpSystemTime)`, where `&colon;&colon;FileTimeToSystemTime` is the corresponding function declared in the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;GetFileSize` is a public, static member function that has `DWORD (HANDLE hFile, LPDWORD lpFileSizeHigh)` type and whose contract is to return the result of `&colon;&colon;GetFileSize(hFile, lpFileSizeHigh)`, where `&colon;&colon;GetFileSize` is the corresponding function declared in the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;GetFileTime` is a public, static member function that has &apos;BOOL (HANDLE hFile, LPFILETIME lpCreationTime, LPFILETIME lpLastAccessTime, LPFILETIME, lpLastWriteTime)&apos; type and whose contract is to return the result of &apos;&colon;&colon;GetFileTime(hFile, lpCreationTime, lpLastAccessTime, lpLastWriteTime)`, where `&colon;&colon;GetFileTime&apos; is the corresponding function declared in the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;GetLastError` is a public, static member function that has `DWORD ()` type and whose contract is to return the result of `&colon;&colon;GetLastError()`, where `&colon;&colon;GetLastError` is the corresponding function declared in the `windows&period;h` header&period; &ast; `WINDOWS&lowbar;INTERFACE&colon;&colon;SystemTimeToFileTime` is a public, static member function that has `BOOL (const SYSTEMTIME &ast;lpSystemTime, LPFILEMTIME lpFileTime)` type and whose contract is to return the result of `&colon;&colon;SystemTimeToFileTime(lpSystemTime, lpFileTime)`, where `&colon;&colon;SystemTimeToFileTime` is the corresponding function declared in the `windows&period;h` header&period;

== Type Aliases

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bdls/FilesystemUtil_WindowsImpUtil/FileDescriptor.adoc[`FileDescriptor`] 
| `FileDescriptor` is an alias for operating system&apos;s native file descriptor &sol; file handle type&period;
| xref:BloombergLP/bdls/FilesystemUtil_WindowsImpUtil/Offset.adoc[`Offset`] 
| `Offset` is an alias for a signed integral type, and represents the offset of a location in a file&period;
|===


== Static Member Functions

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bdls/FilesystemUtil_WindowsImpUtil/convertFileTimeToDatetime.adoc[`convertFileTimeToDatetime`] 
| Load into the specified `time` the time in the specified `lpFileTime`&period; Return 0 on success, and a non&hyphen;zero value otherwise&period; Note that the time is reported in UTC&period;
| xref:BloombergLP/bdls/FilesystemUtil_WindowsImpUtil/getFileSize.adoc[`getFileSize`] 
| Return the size, in bytes, of the file with the specified `descriptor`, or a negative value if an error occurs&period;
| xref:BloombergLP/bdls/FilesystemUtil_WindowsImpUtil/getLastModificationTime.adoc[`getLastModificationTime`] 
| Load the file&apos;s last modification time into `time`&period;
|===


== Static Data Members

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bdls/FilesystemUtil_WindowsImpUtil/k_NANOSECONDS_PER_WINDOWS_TICK.adoc[`k&lowbar;NANOSECONDS&lowbar;PER&lowbar;WINDOWS&lowbar;TICK`] 
| Nanoseconds per Windows tick&period;
| xref:BloombergLP/bdls/FilesystemUtil_WindowsImpUtil/k_WINDOWS_TICKS_PER_MICROSECOND.adoc[`k&lowbar;WINDOWS&lowbar;TICKS&lowbar;PER&lowbar;MICROSECOND`] 
| Windows ticks per microsecond&period;
|===



[.small]#Created with https://www.mrdocs.com[MrDocs]#
