MCPcopy Create free account
hub / github.com/TheRealMJP/SHforHLSL / GetFileTimestamp

Function GetFileTimestamp

SHTest/SampleFramework12/v1.04/FileIO.cpp:134–141  ·  view source on GitHub ↗

Gets the last written timestamp of the file

Source from the content-addressed store, hash-verified

132
133// Gets the last written timestamp of the file
134uint64 GetFileTimestamp(const wchar* filePath)
135{
136 Assert_(filePath);
137
138 WIN32_FILE_ATTRIBUTE_DATA attributes;
139 Win32Call(GetFileAttributesEx(filePath, GetFileExInfoStandard, &attributes));
140 return attributes.ftLastWriteTime.dwLowDateTime | (uint64(attributes.ftLastWriteTime.dwHighDateTime) << 32);
141}
142
143// Returns the contents of a file as a string
144std::string ReadFileAsString(const wchar* filePath)

Callers 1

UpdateShadersFunction · 0.85

Calls 1

Win32CallFunction · 0.85

Tested by

no test coverage detected