VMS DECwindows Transport Manual

*HyperReader

  CONTENTS

  Title Page

  Copyright Page

  Preface

  1      Overview of the VMS DECwindows Transport Layer

  1.1     The Transport Layer Function

  1.2     Transport Common/Specific Architecture

  1.3     Using TCP/IP with DECwindows
    1.3.1      Interoperability and the Transport Layer

  2      X11 Protocol Overview

  2.1     Generating a Protocol Request

  2.2     Xlib Output Buffering and Synchronization

  2.3     Transporting the Protocol Request

  2.4     Client Input
    2.4.1      Handling Input

  3      Transport Layer Architecture

  3.1     Transport Layer Communication Queues
    3.1.1      Transport Common/Specific Queue Relationship
    3.1.2      Adding and Removing Buffers from the Queues
    3.1.3      Communication Queue Notification Flags
    3.1.4      Preventing Queue Access Conflict
      3.1.4.1      Special-Case Queue Conditions

  3.2     Transport Layer Data Structures
    3.2.1      XTPB Data Structure
    3.2.2      IXTCC Data Structure
    3.2.3      XTCC Data Structure
    3.2.4      XTCB Data Structure
    3.2.5      XTCQ Data Structure
    3.2.6      XTDB Data Structure
    3.2.7      XTFT Data Structure

  3.3     Transport-Common and Transport-Specific Components
    3.3.1      Transport-Common Functions
      3.3.1.1      Initializing the Transport-Common Layer
      3.3.1.2      Attaching a Transport-Specific Layer
      3.3.1.3      Opening a Connection
      3.3.1.4      Opening a Connection Asynchronously
      3.3.1.5      Completing an Asynchronous Open
      3.3.1.6      Allocating Transport Memory
      3.3.1.7      Common Transport Read Routines
      3.3.1.8      Writing to the Transport
      3.3.1.9      Transport Layer Timer Mechanism
      3.3.1.10     Closing a Connection
      3.3.1.11     Outputting Messages for Debugging
      3.3.1.12     Buffer Compression
    3.3.2      Transport-Specific Functions
      3.3.2.1      Initializing the Transport
    3.3.3      Attaching the Specific Transport
      3.3.3.1      Opening a Connection
      3.3.3.2      Writing XTCBs to a Transport
      3.3.3.3      Reading XTCBs from a Transport
      3.3.3.4      Closing a Connection
      3.3.3.5      The Transport-Specific Callback

  4      Transport Walk-Through

  5      Transport-Common Routines

  DECW$XPORT_ACCEPT_FAILED

  DECW$XPORT_ALLOC_INIT_QUEUES

  DECW$XPORT_ALLOC_PMEM

  DECW$XPORT_ATTACHED

  DECW$XPORT_ATTACH_LOST

  DECW$XPORT_CLOSE

  DECW$XPORT_COPY_AND_WRITE

  DECW$XPORT_DEALLOC_PMEM

  DECW$XPORT_DEALLOC_QUEUES

  DECW$XPORT_FAO

  DECW$$XPORT_FREE_INPUT

  DECW$XPORT_IN_NOTIFY_USER

  DECW$$XPORT_OPEN_COMPLETE

  DECW$XPORT_READ_COMPLETE

  DECW$XPORT_REATTACH_FAILED

  DECW$XPORT_REFUSED_BY_SERVER

  DECW$XPORT_UNEXPECTED_MESSAG

  DECW$XPORT_UNKNOWN_LINK

  DECW$XPORT_VALIDATE_STRUCT

  DECW$XPORT_VALIDATE_STRUCT_JSB

  DECW$XPORT_VALIDATE_XTCB

  DECW$XPORT_VALIDATE_XTCB_JSB

  DECW$$XPORT_WRITE

  6      Transport-Specific Routines

  6.1     Condition Values

  CLOSE_AND_DEALLOCATE_AST

  DECW$TRANSPORT_INIT

  DETACH_AND_POLL

  FREE_INPUT_AST

  REATTACH_AST

  TRANSPORT_OPEN_CALLBACK

  TRANSPORT_READ_AST

  TRANSPORT_READ_QUEUE

  WRITE_AST

  XTFT$A_ATTACH_TRANSPORT

  XTFT$A_CLOSE

  XTFT$A_EXECUTE_FREE

  XTFT$A_EXECUTE_WRITE

  XTFT$A_FREE_INPUT_BUFFER

  XTFT$A_OPEN

  XTFT$A_RUNDOWN

  XTFT$A_WRITE

  XTFT$A_WRITE_USER

  7      Transport Support Macros

  XPORT_IN_NOTIFY_SET

  XPORT_IN_NOTIFY_CLEAR

  XPORT_IN_NOTIFY_WAIT

  XPORT_IN_NOTIFY_SEND

  XPORT_OUT_NOTIFY_SET

  XPORT_OUT_NOTIFY_CLEAR

  XPORT_OUT_NOTIFY_WAIT

  XPORT_OUT_NOTIFY_SEND

  XPORT_XTCB_FILLED

  XPORT_XTCB_TOTAL

  XPORT_XTCB_FREE

  XPORT_WRITE_WAIT

  XPORT_WRITE_UNWAIT

  XPORT_ABORT_SEND

  XPORT_OUT_WRITE_ENABLE

  XPORT_OUT_WRITE_DISABLE

  XPORT_OUT_STATE_SRP

  XPORT_OUT_STATE_LRP

  XPORT_IN_STATE_SRP

  XPORT_IN_STATE_LRP

  XPORT_IN_FREE_ENABLE

  XPORT_IN_FREE_DISABLE

  VALIDATE_XTCC

  VALIDATE_USERW

  VALIDATE_USER

  8      Writing Your Own Transport

  8.1     Where to Begin

  8.2     Example TCP/IP Transport Layer Implementation
    8.2.1      TCP/IP Transport Layer Setup
    8.2.2      Sample XTFT$A_EXECUTE_WRITE Routine
    8.2.3      Sample XTFT$A_WRITE Routine
    8.2.4      Sample WRITE_AST Routine
    8.2.5      Sample XTFT$A_WRITE_USER Routine
    8.2.6      Sample XTFT$A_EXECUTE_FREE Routine
    8.2.7      Sample XTFT$A_FREE_INPUT_BUFFER Routine
    8.2.8      Sample FREE_INPUT_AST Routine
    8.2.9      Sample PARSE_INTERNET_ADDRESS Routine
    8.2.10     Sample XTFT$A_CLOSE Routine
    8.2.11     Sample CLOSE_AND_DEALLOCATE_AST Routine
    8.2.12     Sample XTFT$A_OPEN Routine
    8.2.13     Sample OPEN_AST1 Routine
    8.2.14     Sample OPEN_AST2 Routine
    8.2.15     Sample OPEN_AST3 Routine
    8.2.16     Sample XTFT$A_ATTACH_TRANSPORT Routine
    8.2.17     Sample TRANSPORT_READ_QUEUE Routine
    8.2.18     Sample TRANSPORT_READ_AST Routine
    8.2.19     Sample TRANSPORT_OPEN_CALLBACK Routine
    8.2.20     Sample DETACH_AND_POLL Routine
    8.2.21     Sample REATTACH_AST Routine
    8.2.22     Sample XTFT$A_RUNDOWN Routine
    8.2.23     Sample DECW$TRANSPORT_INIT Routine

  8.3     Compiling and Linking Options for the Transport
    8.3.1      Installing the Transport-Specific Shareable Image
    8.3.2      Installing the Example Transport Shareable Image

  EXAMPLES

  8-1        TCP/IP Transport Layer Setup

  8-2        Sample XTFT$A_EXECUTE_WRITE Routine

  8-3        Sample XTFT$A_WRITE Routine

  8-4        Sample WRITE_AST Routine

  8-5        Sample XTFT$A_WRITE_USER Routine

  8-6        Sample XTFT$A_EXECUTE_FREE Routine

  8-7        Sample XTFT$A_FREE_INPUT_BUFFER Routine

  8-8        Sample FREE_INPUT_AST Routine

  8-9        Sample PARSE_INTERNET_ADDRESS

  8-10       Sample XTFT$A_CLOSE Routine

  8-11       Sample CLOSE_AND_DEALLOCATE_AST Routine

  8-12       Sample DECW$$TCPIP_OPEN Routine

  8-13       Sample OPEN_AST1 Routine

  8-14       Sample OPEN_AST2 Routine

  8-15       Sample OPEN_AST3 Routine

  8-16       Sample XTFT$A_ATTACH_TRANSPORT Routine

  8-17       Sample TRANSPORT_READ_QUEUE Routine

  8-18       Sample TRANSPORT_READ_AST Routine

  8-19       Sample TRANSPORT_OPEN_CALLBACK Routine

  8-20       Sample DETACH_AND_POLL Routine

  8-21       Sample REATTACH_AST Routine

  8-22       Sample XTFT$A_RUNDOWN Routine

  8-23       Sample DECW$TRANSPORT_INIT Routine

  8-24       DEMO_BUILD.COM Procedure

  FIGURES

  1-1        Remote Transport Connection

  1-2        Local Transport Connection

  2-1        Protocol Request Format

  2-2        Output Buffer Containing a Protocol Request

  3-1        Transport Layer Communication Queues

  3-2        Client/Server Communication Queue Views

  3-3        Transport Common/Specific Connection

  3-4        Transport Common/Specific Queues

  3-5        Transport Attach Data Structures

  3-6        Transport Connection Open Data Structures

  3-7        Transport Connection Open XTCB Data Structures

  3-8        Transport Data Structures

  3-9        XTPB Data Structure

  3-10       IXTCC Data Structure

  3-11       XTCC Data Structure

  3-12       XTCB Data Structure

  3-13       XTCQ Data Structure

  3-14       XTDB Data Structure

  3-15       XTFT Data Structure

  TABLES

  3-1        Transport Layer Communication Queues

  3-2        Views for the Client/Server Communication Queue

  3-3        Communication Queue Notification Flags

  3-4        Transport Layer Data Structures

  3-5        XTPB Data Structure

  3-6        XTPB Default Values

  3-7        IXTCC Data Structure

  3-8        XTCC Data Structure

  3-9        XTCB Data Structure

  3-10       XTCQ Data Structure

  3-11       XTDB Data Structure

  3-12       XTFT Data Structure

  3-13       Transport Memory Allocation Routines

  3-14       Transport Read Routines

  3-15       Common Transport Write Routines

  3-16       Transport-Specific Write Routines

  3-17       Transport-Specific Read Routines

  3-18       Transport-Specific Connection Close Routines

  5-1        Transport-Common Routines

  6-1        Transport-Specific Routines

  7-1        Transport Support Macros