This section refers to the prototype implementation that is being developed concurrently with this document. This prototype has been able to flush out many details and problems as the specification was being developed.
In X11R6, all of the source code for this interface was located in
xc/lib/xtrans
.
In X11R7, all of the source code for this interface is delivered via
the lib/libxtrans
modular package from X.Org,
and is installed under
so that other modules may find it when they build.
${prefix}
/X11/Xtrans
All functions names in the source are of the format
TRANS(func)()
. The
TRANS()
macro is defined as
#if (__STDC__ && !defined(UNIXCPP)) || defined(ANSICPP)
#define TRANS(func) _PROTOCOLTrans##func
#else
#define TRANS(func) _PROTOCOLTrans/**/func
#endif
#if (__STDC__ && !defined(UNIXCPP)) || defined(ANSICPP)
#define TRANS(func) _PROTOCOLTrans##func
#else
#define TRANS(func) _PROTOCOLTrans/**/func
#endif
PROTOCOL will be uniquely defined in each directory where this code is compiled. PROTOCOL will be defined to be the name of the protocol that is implemented by the library or server, such as X11, FS, and ICE.
All libraries and servers that use the X Transport Interface should have a new
file called
.
This file will include the transports based on the configuration flags
provided by the TRANSPORT
trans.cconfigure
script. Below is an
example xfstrans.c
for the font server.
#include "config.h"
#define FONT_t 1
#define TRANS_REOPEN 1
#define TRANS_SERVER 1
#include <X11/Xtrans/transport.c>
#include "config.h"
#define FONT_t 1
#define TRANS_REOPEN 1
#define TRANS_SERVER 1
#include <X11/Xtrans/transport.c>
The source files for this interface are listed below.
| Function prototypes and defines for the Transport Independent API. |
| Used by the interface implementation only. Contains the internal data structures. |
| Socket implementation of the Transport Dependent API. |
| TLI implementation of the Transport Dependent API. |
| DECnet implementation of the Transport Dependent API. |
| Implementation of the Transport Dependent API for SYSV Local connections. |
| Exposed Transport Independent API Functions. |
| Collection of Utility functions that use the X Transport Interface. |
The file Xtransint.h
contains much of the transport
related code that was previously in Xlibint.h
and
Xlibnet.h
.
This will make the definitions available for all transport users. This
should also obsolete the equivalent code in other libraries.