Share via


RESTORABLE_FILE_INFO structure

Provides information about a restorable file. This structure is used when calling ScanRestorableFiles.

Note

FMAPI can only be used in the Windows Preinstallation Environment (WinPE) for Windows Vista, Windows Server 2008, and later. Applications that use FMAPI must license WinPE.

Syntax

typedef struct _RESTORABLE_FILE_INFO {
  ULONG     Size;
  DWORD     Version;
  ULONGLONG FileSize;
  FILETIME  CreationTime;
  FILETIME  LastAccessTime;
  FILETIME  LastWriteTime;
  DWORD     Attributes;
  BOOL      IsRemoved;
  LONGLONG  ClustersUsedByFile;
  LONGLONG  ClustersCurrentlyInUse;
  ULONG     RestoreDataOffset;
  WCHAR     FileName[1];
} RESTORABLE_FILE_INFO, *PRESTORABLE_FILE_INFO;

Members

Size

The size of the structure, in bytes.

Version

The major and minor version of the file.

FileSize

The size of the file.

CreationTime

The time the file was created. See FILETIME.

LastAccessTime

The time the file was last accessed.

LastWriteTime

The time the file was last modified.

Attributes

The attributes for the file. This member can be a combination of one or more of the following values.

Attribute Meaning
FILE_ATTRIBUTE_ARCHIVE
The file or directory is an archive file. Applications use this attribute to mark files for backup or removal.
FILE_ATTRIBUTE_COMPRESSED
The file or directory is compressed. For a file, this means that all of the data in the file is compressed. For a directory, this means that compression is the default for newly created files and subdirectories.
FILE_ATTRIBUTE_DIRECTORY
The handle identifies a directory.
FILE_ATTRIBUTE_ENCRYPTED
The file or directory is encrypted. For a file, this means that all data in the file is encrypted. For a directory, this means that encryption is the default for newly created files and subdirectories.
FILE_ATTRIBUTE_HIDDEN
The file or directory is hidden. It is not included in an ordinary directory listing.
FILE_ATTRIBUTE_NORMAL
The file does not have other attributes. This attribute is valid only if used alone.
FILE_ATTRIBUTE_OFFLINE
The file data is not available immediately. This attribute indicates that the file data is physically moved to offline storage. This attribute is used by Remote Storage, the hierarchical storage management software. Applications should not arbitrarily change this attribute.
FILE_ATTRIBUTE_READONLY
The file or directory is read-only. Applications can read the file, but cannot write to it or delete it. If it is a directory, applications cannot delete it.
FILE_ATTRIBUTE_REPARSE_POINT
The file or directory has an associated reparse point.
FILE_ATTRIBUTE_SPARSE_FILE
The file is a sparse file.
FILE_ATTRIBUTE_SYSTEM
The file or directory is part of the operating system or is used exclusively by the operating system.
FILE_ATTRIBUTE_TEMPORARY
The file is being used for temporary storage. File systems avoid writing data back to mass storage if sufficient cache memory is available, because often the application deletes the temporary file after the handle is closed. In that case, the system can entirely avoid writing the data. Otherwise, the data will be written after the handle is closed.
FILE_ATTRIBUTE_VIRTUAL
A file is a virtual file.

IsRemoved

TRUE if the file has been removed; otherwise, FALSE.

ClustersUsedByFile

The number of clusters that the file allocates. This member is used in conjunction with ClustersCurrentlyInUse to determine the percentage of file data that can be recovered.

ClustersCurrentlyInUse

The number of clusters that are marked as used for the file in the volume bitmap.

RestoreDataOffset

The offset from the beginning of the structure to the Binary Large Object (BLOB) that is used by RestoreFile.

FileName

The full path of the file.

Remarks

Note that there is no associated header file for this structure.

The FileName member is variable in length. An additional implementation-specific BLOB is added after the name of the file. The location of the BLOB is determined by RestoreDataOffset.

Requirements

Minimum supported client
Windows Vista [desktop apps only]
Minimum supported server
Windows Server 2008 [desktop apps only]

See also

RestoreFile

ScanRestorableFiles