Get file status.
These function return information about a file. Execute (search) permission is required on all of the directories in path that lead to the file.
#include <kodi/Filesystem.h>
...
kodi::vfs::FileStatus statFile;
fprintf(stderr, "deviceId (ID of device containing file) = %u\n"
"size (total size, in bytes) = %lu\n"
"accessTime (time of last access) = %lu\n"
"modificationTime (time of last modification) = %lu\n"
"statusTime (time of last status change) = %lu\n"
"isDirectory (The stat url is a directory) = %s\n"
"isSymLink (The stat url is a symbolic link) = %s\n"
"Return value = %i\n",
statFile.GetDeviceId(),
statFile.GetSize(),
statFile.GetAccessTime(),
statFile.GetModificationTime(),
statFile.GetStatusTime(),
statFile.GetIsDirectory() ? "true" : "false",
statFile.GetIsSymLink() ? "true" : "false",
ret);
bool ATTRIBUTE_HIDDEN StatFile(const std::string &filename, kodi::vfs::FileStatus &buffer)
Get file status.
Definition: Filesystem.h:995