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 /


Chapter 1  Introduction to Open Transport

Figure 1-1  The OSI model and Open Transport protocols

Figure 1-2  The basic architecture of Open Transport

Figure 1-3  An Open Transport Provider

Figure 1-4  Hierarchy of Open Transport providers


Table 1-1   The Open Transport protocol matrix and some Open Transport protocols


Chapter 2  Getting Started With Open Transport

Figure 2-1  The TNetbuf structure


Table 2-1   Open Transport libraries for PowerPC code

Table 2-2   Open Transport libraries for 68000 code


Listing 2-1  Using a TNetBuf structure to store an address

Listing 2-2  Using Helper Routines to Initialize an Address

Listing 2-3  CFM terminate procedure

Listing 2-4  Downloading a URL With HTTP


Chapter 3  Providers

Table 3-1   Result codes that all Open Transport functions can return


Listing 3-1  A notifier function

Listing 3-2  Transferring provider ownsership


Chapter 4  Endpoints

Figure 4-1  Typical endpoint states for a connectionless endpoint

Figure 4-2  Possible endpoint states for a connection-oriented endpoint

Figure 4-3  Establishing a connection with the active peer in synchronous mode

Figure 4-4  Establishing a connection in asynchronous mode

Figure 4-5  An abortive disconnect

Figure 4-6  Remote orderly disconnect

Figure 4-7  A local orderly disconnect

Figure 4-8  How a transaction ID is generated

Figure 4-9  Data transfer using connectionless transaction-based endpoints in asynchronous mode

Figure 4-10  Data transfer using connection-oriented transaction-based endpoints in asynchronous mode


Table 4-1   The names of functions used to transfer data

Table 4-2  Endpoint functions that behave differently in synchronous and asynchronous modes

Table 4-3   Endpoint states

Table 4-4   Functions that can change an endpoint's state

Table 4-5   Events that can change an endpoint's state

Table 4-6   The Open Transport type-of-service matrix and some Open Transport protocols

Table 4-7   Pending asynchronous events and the functions that clear them

Table 4-8   Pending asynchronous events and the synchronous functions they can affect


Chapter 5  Programming With Open Transport

Figure 5-1  Synchronous processing with threads

Figure 5-2  Polling for events

Figure 5-3  Asynchronous processing with a notifier


Chapter 6  Mappers

Figure 6-1  Format of entries in OTLookupName reply buffer


Table 6-1   Completion events for asynchronous mapper functions


Listing 6-1  The main function to OTLookupNameTest

Listing 6-2  Notifier that yields time to other processes

Listing 6-3  The LookupAndPrint function

Listing 6-4  Printing names and addresses


Chapter 7  Option Management

Figure 7-1  The format of option information

Figure 7-2  An options buffer


Table 7-1   XTI-level options

Table 7-2   Open Transport generic options


Listing 7-1  Constructing an options buffer using the OTCreateOptions function

Listing 7-2  Using the OTCreateOptionString function to parse through a buffer

Listing 7-3  Calling functions that get, set, and display options

Listing 7-4  Getting an option value

Listing 7-5  Setting an option value

Listing 7-6  Parsing an options buffer

Listing 7-7  Obtaining options for a specific level

Listing 7-8  Using the OTCreateOptionString function

Listing 7-9  Building an options buffer from a configuration string


Chapter 8  Ports

Listing 8-1  Finding all serial ports


Chapter 9  Utilities

Listing 9-1 ListMania: global declarations

Listing 9-2  The InitWidgetLists function

Listing 9-3  The CreateWidget function

Listing 9-4  The ProduceWidgets function

Listing 9-5  The ConsumeWidgets function

Listing 9-6  The PrintWidget function

Listing 9-7  The DumpAllWidgetLists

Listing 9-8  The DumpWidgetList function


Chapter 10  Advanced Topics

Figure 10-1  Describing noncontiguous data

Figure 10-2  OTBuffer structures


Listing 10-1  Doing a no-copy receive: method 1

Listing 10-2  Doing a no-copy receive: method 2

Listing 10-3  Negotiating raw mode using options

Listing 10-4  Testing for raw data support

Listing 10-5  Testing for raw mode support for a DDP endpoint


Chapter 11  TCP/IP Services

Figure 11-1  TCP/IP protocols and functional layers

Figure 11-2  Internet subnet address


Table 11-1  The Open Transport protocol matrix and TCP/IP protocols

Table 11-2  Configuration strings for TCP/IP options


Listing 11-1  Sample IP Secondary Addresses file

Listing 11-2  Setting an option value


Chapter 12  Introduction to AppleTalk

Figure 12-1  AppleTalk protocol stack and the OSI model


Table 12-1   AppleTalk addressing identifiers

Table 12-2   Protocol identifiers for use in configuring AppleTalk providers

Table 12-3   Indicating AppleTalk options in the configuration string

Table 12-4   Open Transport support for AppleTalk endpoint protocols


Chapter 13  AppleTalk Addressing

Listing 13-1  Setting up a DDP Address

Listing 13-2  Setting up an NBP address


Table 13-1  Open Transport name-registration functions

Table 13-2  Open Transport name and address functions

Table 13-3  Wildcard operators


Chapter 14  AppleTalk Service Providers

Figure 14-1  AppleTalk service providers and their underlying delivery mechanism


Listing 14-1 Using the  DoGetMyZone function synchronously


Chapter 15  Datagram Delivery Protocol (DDP)

Figure 15-1  The DDP endpoint provider's underlying delivery mechanism


Table 15-1   Effects of using the DDP type field


Chapter 16  AppleTalk Data Stream Protocol (ADSP)

Figure 16-1  The ADSP endpoint provider's underlying delivery mechanism


Chapter 17  AppleTalk Transaction Protocol (ATP)

Figure 17-1  The ATP endpoint provider's underlying delivery mechanism


Table 17-1   ATP option definitions and default values


Chapter 18  Printer Access Protocol (PAP)

Figure 18-1  The PAP endpoint provider's underlying delivery mechanism


Listing 18-1  Using the ATP_OPTREPLYCNT option


Chapter 19  Serial Endpoint Providers

Figure 19-1 The format of serialized bits

Figure 19-2 Serial port I/O handshaking 358



Appendix A  Open Transport and XTI

Table A-1   XTI-to-Open Transport function cross-reference

Table A-2   Open Transport-to-XTI function cross-reference

Table A-3   Open Transport Functions not found in XTI

Table A-4   XTI-to-Open Transport data structure cross-reference

Table A-5   Apple extensions to XTI data structures

Table A-6   XTI-to-Open Transport result code cross-reference


Appendix B  Result Codes

Table B-1   Open Transport result codes


Appendix C  Special Functions

Table C-1   Functions callable at hardware interrupt time, all ISAs

Table C-2   Functions callable at hardware interrupt time, native ISA only

Table C-3   Functions callable from deferred tasks

Table C-4   Functions that allocate memory


Appendix D  XTI Option Summary

Figure D-1  Negotiating an association-related option


Table D-1   Open Transport endpoint functions and the types of options they accept


Previous Book Contents Book Index Next

© Apple Computer, Inc.
15 JAN 1998