Skip to content

Commit

Permalink
Pull the entire FILE_INFO_BY_HANDLE_CLASS enum
Browse files Browse the repository at this point in the history
This saves having to count down the list in the docs, when inserting new
values.

Source:
https://docs.microsoft.com/en-us/windows/win32/api/minwinbase/ne-minwinbase-file_info_by_handle_class

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
  • Loading branch information
TBBle committed Dec 12, 2020
1 parent d1ffc52 commit 093b642
Showing 1 changed file with 26 additions and 2 deletions.
28 changes: 26 additions & 2 deletions fileinfo.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,32 @@ import (
//sys setFileInformationByHandle(h syscall.Handle, class uint32, buffer *byte, size uint32) (err error) = SetFileInformationByHandle

const (
fileBasicInfo = 0
fileIDInfo = 0x12
// FILE_INFO_BY_HANDLE_CLASS
fileBasicInfo = 0x00
fileStandardInfo = 0x01
fileNameInfo = 0x02
fileRenameInfo = 0x03
fileDispositionInfo = 0x04
fileAllocationInfo = 0x05
fileEndOffileInfo = 0x06
fileStreamInfo = 0x07
fileCompressionInfo = 0x08
fileAttributeTagInfo = 0x09
fileIDBothDirectoryInfo = 0x0a
fileIDBothDirectoryRestartInfo = 0x0b
fileIoPriorityHintInfo = 0x0c
fileRemoteProtocolInfo = 0x0d
fileFullDirectoryInfo = 0x0e
fileFullDirectoryRestartInfo = 0x0f
fileStorageInfo = 0x10
fileAlignmentInfo = 0x11
fileIDInfo = 0x12
fileIDExtdDirectoryInfo = 0x13
fileIDExtdDirectoryRestartInfo = 0x14
fileDispositionInfoEx = 0x15
fileRenameInfoEx = 0x16
fileCaseSensitiveInfo = 0x17
fileNormalizedNameInfo = 0x18
)

// FileBasicInfo contains file access time and file attributes information.
Expand Down

0 comments on commit 093b642

Please sign in to comment.