Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Networking With Open Transport / Part 2 - Open Transport Reference
Chapter 30 - AppleTalk Reference / AppleTalk Addressing Reference
AppleTalk Utility Functions /


OTSetAddressFromNBPEntity

Stores an NBP entity structure as an NBP address string.

C INTERFACE
size_t OTSetAddressFromNBPEntity(UInt8* nameBuf, 
                     const NBPEntity* entity);
C++ INTERFACE
None. C++ applications use the C interface to this function.

PARAMETERS
nameBuf
A pointer to a stroing in which you wish to store the NBP entity, formatted as a string.
entity
A pointer to the NBP entity you wish to store.
function result
The number of bytes that were actually stored in the buffer referenced by the nameBuf parameter.
DISCUSSION
The OTSetAddressFromNBPEntity function stores the information in the NBP entity into the string specified by the nameBuf parameter in the format required for mapper calls--that is, if you have a backslash (\), a colon (:), or an at-sign (@) in your NBP name, this function inserts a backslash before each so that the mapper functions can handle them correctly.

To determine the appropriate buffer size for this call, use the OTGetNBPEntityLengthAsAddress function .

To parse and store all or part of an NBP name into an NBP entity, use the OTSetNBPEntityFromAddress function.

SPECIAL CONSIDERATIONS
Use the OTGetNBPEntityLengthAsAddress function beforehand to determine the appropriate buffer size.

SEE ALSO
"The NBP Address Structure".


Previous Book Contents Book Index Next

© Apple Computer, Inc.
15 JAN 1998