Important: The information in this document is obsolete and should not be used for new development.
PBHGetFInfo
You can use thePBHGetFInfo
function to obtain information about a file.
FUNCTION PBHGetFInfo (paramBlock: HParmBlkPtr; async: Boolean): OSErr;
paramBlock
- A pointer to a basic HFS parameter block.
async
- A Boolean value that specifies asynchronous (
TRUE) or synchronous (FALSE) execution.
--> ioCompletion
ProcPtr
A pointer to a completion routine. <-- ioResult
OSErr
The result code of the function. <-> ioNamePtr
StringPtr
A pointer to a pathname. --> ioVRefNum
Integer
A volume specification. <-- ioFRefNum
Integer
A file reference number. --> ioFDirIndex
Integer
An index. <-- ioFlAttrib
SignedByte
The file attributes. <-- ioFlFndrInfo
FInfo
Information used by the Finder. <-> ioDirID
LongInt
On input, a directory ID; on output, a file ID. <-- ioFlStBlk
Integer
The first allocation block of the data fork. <-- ioFlLgLen
LongInt
The logical end-of-file of the data fork. <-- ioFlPyLen
LongInt
The physical end-of-file of the data fork. <-- ioFlRStBlk
Integer
The first allocation block of the resource fork. <-- ioFlRLgLen
LongInt
The logical end-of-file of the resource fork. <-- ioFlRPyLen
LongInt
The physical end-of-file of the resource fork. <-- ioFlCrDat
LongInt
The date and time of creation. <-- ioFlMdDat
LongInt
The date and time of last modification. DESCRIPTION
If the value ofioFDirIndex
is positive, thePBHGetFInfo
function returns information about the file whose directory index isioFDirIndex
on the volume specified byioVRefNum
in the directory specified byioDirID
. You should callPBHGetFInfo
just beforePBHSetFInfo
, so that the current information is present
in the parameter block.
If the value of
- Note
- If a working directory reference number is specified in
ioVRefNum
, the File Manager returns information about the file whose directory index isioFDirIndex
in the specified directory.ioFDirIndex
is negative or 0, thePBHGetFInfo
function returns information about the file having the name pointed to byioNamePtr
on the volume specified byioVRefNum
. If the file is open, the reference number of the first access path found is returned inioFRefNum
, and the name of the file is returned inioNamePtr
(unlessioNamePtr
isNIL
).ASSEMBLY-LANGUAGE INFORMATION
The trap macro forPBHGetFInfo
is_HGetFileInfo
.RESULT CODES