Carbon


AFPVolMountInfo

Header: Files.h

struct AFPVolMountInfo {
    SInt16 length; 
    VolumeType media; 
    SInt16 flags; 
    SInt8 nbpInterval; 
    SInt8 nbpCount; 
    SInt16 uamType; 
    SInt16 zoneNameOffset; 
    SInt16 serverNameOffset; 
    SInt16 volNameOffset; 
    SInt16 userNameOffset; 
    SInt16 userPasswordOffset; 
    SInt16 volPasswordOffset; 
    char AFPData[144];
};
typedef AFPVolMountInfo AFPVolMountInfoPtr;

Field descriptions

length

The length of the AFPVolMountInfo structure (that is, the total length of the structure header described here plus the variable-length location data).

media

The volume type of the remote volume. The value AppleShareMediaType (a constant that translates to 'afpm') represents an AppleShare volume.

flags

Reserved; set this field to 0. If bit 0 is set, no greeting message from the server is displayed.

nbpInterval

The NBP retransmit interval, in units of 8 ticks.

nbpCount

The NBP retransmit count. This field specifies the total number of times a packet should be transmitted, including the first transmission.

uamType

The access-control method used by the remote volume. AppleShare uses four methods, defined by the constants described in “Access Control Method Constants”.

zoneNameOffset

The offset in bytes from the beginning of the structure to the entry in the AFPData field containing the name of the AppleShare zone.

serverNameOffset

The offset in bytes from the beginning of the structure to the entry in the AFPData field containing the name of the AppleShare server.

volNameOffset

The offset in bytes from the beginning of the structure to the entry in the AFPData field containing the name of the volume.

userNameOffset

The offset in bytes from the beginning of the structure to the entry in the AFPData field containing the name of the user.

userPasswordOffset

The offset in bytes from the beginning of the structure to the entry in the AFPData field containing the user’s password.

volPasswordOffset

The offset in bytes from the beginning of the structure to the entry in the AFPData field containing the volume’s password. Some versions of the AppleShare software do not pass the information in this field to the server.

AFPData

The actual volume mounting information, offsets to which are contained in the preceding six fields. To mount an AFP volume, you must fill in the structure with at least the zone name, server name, user name, user password, and volume password. You can lay out the data in any order within this data field, as long as you specify the correct offsets in the offset fields.

The only volumes that currently support the programmatic mounting functions are AppleShare servers, which use a volume mounting structure of type AFPVolMountInfo.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)