vMVolumeGrade
#include <Files.h>
short vMVersion; Â2 0 version number
long vMAttrib; Â4 2 bit vector of attributes;
see vMAttrib constants
Handle vMLocalHand; Â4 6 handle to private data long vMServerAdr; Â4 10 network server address
long vMVolumeGrade; 4 14 relative speed rating
short vMForeignPrivID; 4 18 access privilege model
Notes: The first four fields are the same as those in the original
are new in system software version 7.0.
Offset Field Size Meaning
14 vMVolumeGrade long Relative speed rating of volume. This
scale is currently uncalibrated.
Generally, lower values re present
faster speeds. A value of 0 means the
volume is unrated.
18 vMForeignPrivID short Code for the privilege model
supported by the volume. This field
now has two possible values: 0
re presents a standard HFS volume,
which might or might not support the
AFP privilege model; fsUnixPriv
re presents an A/UX volume.
To determine whether the functions for manipulating privilege
information in foreign file systems are available on a volume, check the
vMForeignPrivID field in the attributes buffer. If this field contains a
nonzero value, the functions are available.
vMAttrib field of the attributes buffer. Version 7.0 has defined additional
bits in the vMAttrib field to signal whether the following features are
present.
Volume supports the file ID functions, bHasFileIDs
including PBEx changeFiles
Volume supports inherited access bHasBlankAccessPrivileges
privileges for folders
functions, described in the
Volume supports a shorter name, for bHasShortName
compatibility with other file systems
Local file sharing is enabled bHasPersonalAccessPrivileges
Volume supports the Users and Groups bHasUserGroupList
file and thus the AFP privilege functions,
The description of PBHGetVolParms lists all of the bits in the vMAttrib field and their meanings.
The following code example illustrates how you can determine whether the
PBCatSearch function is available before using it to search a volume's catalog.
// Assumes inclusion of MacHeaders
// prototype your function like this prior to calling it
Boolean SupportsCatSearch( short yourVRef) {
GetVolParmsInfoBuffer VParmsBuf;
// Error handler prototype
myHPBPtr = &myHPBRec;
myHPBRec.ioParam.ioCompletion = nil; // no completion routine
myHPBRec.ioParam.ioNamePtr = nil;
myHPBRec.ioParam.ioVRefNum = yourVRef;
myHPBRec.ioParam.ioBuffer = (Ptr)&VParmsBuf; myHPBRec.ioParam.ioReqCount = sizeof(GetVolParmsInfoBuffer);
if ( myErr )
// process the error
DoError(myErr);
if ( VParmsBuf.vMAttrib & bHasCatSearch << 1 )
else
}
To determine whether the remote mounting functions are available, you
must attempt to call one of them. If they are not available, the functions
return a result code of paramErr.