BY_HANDLE_FILE_INFORMATION

BY_HANDLE_FILE_INFORMATION

类型定义

Type BY_HANDLE_FILE-INFORMATION ' 52 Bytes

dwFileAttributes As Long

ftCreationTime As FILETIME

ftLastAccessTime As FILETIME

ftLastWriteTime As FILETIME

dwVolumeSerialNumber As Long

nFileSizeHigh As Long

nFileSizeLow As Long

nNumberOfLinks As Long

nFileIndexHigh As Long

nFileIndexLow As Long

End Type

说明

Used by the GetFileInformationByHandle function to retrieve information about a file.

字段表

字段

类型及说明

dwFileAttributes

Long,Refer to the File Attribute Types table that follows.

ftCreationTime

FILETIME,Time of file creation. Zero if file system does not support file creation time.

ftLastAccessTime

FILETIME,Time of last access to this file. Zero if file system does not support file last access time.

ftLastWriteTime

FILETIME,Time of last write operation to this file.

dwVolumeSerialNumber

Long,Serial number of the volume that contains the file.

nFileSizeHigh

Long,High-order word of the file size.

nFileSizeLow

Long,Low-order word of the file size.

nNumberOfLinks

Long,Number of links to this file. Always 1 for the FAT file system and HPFS.

nFileIndexHigh

Long,High-order word of a unique identifier associated with the file.

nFileIndexLow

Long,Low-order word of a unique identifier associated with the file. Use this element and the dwVolumeSerialNumber to uniquely identify a file.

File Attribute Types table

FILE_ATTRIBUTE_ARCHIVE    Archive file.

FILE_ATTRIBUTE_COMPRESSED    The file or directory is compressed.

FILE_ATTRIBUTE_DIRECTORY    File is a directory.

FILE_ATTRIBUTE_HIDDEN    File is hidden.

FILE_ATTRIBUTE_NORMAL    File is normal (no other file attributes are specified).

FILE_ATTRIBUTE_READONLY    File is read-only.

FILE_ATTRIBUTE_SYSTEM    File is a system file.

FILE_ATTRIBUTE_NORMAL    File is a temporary file.

注解

dwFileAttributes字段包含了带有FILE_ATTRIBUTE_???前缀的一个或多个常数的组合,它们对文件属性进行了描述。nNumberOfLinks则列出了NFS下对一个文件的链接数量。nFileIndexHigh和nFileIndexLow字段合并起来构成一个64位数字,它对磁盘卷中的一个文件进行了唯一标志

Top