tables.c revision bbe1b32b
1/* $Xorg: tables.c,v 1.4 2001/02/09 02:05:43 xorgcvs Exp $ */
2/*
3 * all the dispatch, error, event and reply vectors
4 */
5/*
6
7Copyright 1990, 1991, 1998  The Open Group
8
9Permission to use, copy, modify, distribute, and sell this software and its
10documentation for any purpose is hereby granted without fee, provided that
11the above copyright notice appear in all copies and that both that
12copyright notice and this permission notice appear in supporting
13documentation.
14
15The above copyright notice and this permission notice shall be included in
16all copies or substantial portions of the Software.
17
18THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
21OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
22AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
23CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
24
25Except as contained in this notice, the name of The Open Group shall not be
26used in advertising or otherwise to promote the sale, use or other dealings
27in this Software without prior written authorization from The Open Group.
28
29 * Copyright 1990, 1991 Network Computing Devices;
30 * Portions Copyright 1987 by Digital Equipment Corporation
31 *
32 * Permission to use, copy, modify, distribute, and sell this software and
33 * its documentation for any purpose is hereby granted without fee, provided
34 * that the above copyright notice appear in all copies and that both that
35 * copyright notice and this permission notice appear in supporting
36 * documentation, and that the names of Network Computing Devices, or Digital
37 * not be used in advertising or publicity pertaining to distribution
38 * of the software without specific, written prior permission.
39 *
40 * NETWORK COMPUTING DEVICES, AND DIGITAL DISCLAIM ALL WARRANTIES WITH
41 * REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF
42 * MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL NETWORK COMPUTING DEVICES,
43 * OR DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
44 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
45 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
46 * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
47 * THIS SOFTWARE.
48 */
49/* $XFree86: xc/programs/xfs/difs/tables.c,v 1.5 2001/01/17 23:45:29 dawes Exp $ */
50
51#include <dispatch.h>
52#include <swaprep.h>
53#include <swapreq.h>
54#include <fsevents.h>
55
56#include "globals.h"
57#include "client.h"
58#include "extentst.h"
59#include "difs.h"
60
61InitialFunc InitialVector[3] =
62{
63    0,
64    ProcInitialConnection,
65    ProcEstablishConnection
66};
67
68ProcFunc ProcVector[NUM_PROC_VECTORS] =
69{
70    ProcNoop,			/* 0 */
71    ProcListExtensions,
72    ProcQueryExtension,
73    ProcListCatalogues,
74    ProcSetCatalogues,
75    ProcGetCatalogues,		/* 5 */
76    ProcSetEventMask,
77    ProcGetEventMask,
78    ProcCreateAC,
79    ProcFreeAC,
80    ProcSetAuthorization,	/* 10 */
81    ProcSetResolution,
82    ProcGetResolution,
83    ProcListFonts,
84    ProcListFontsWithXInfo,
85    ProcOpenBitmapFont,		/* 15 */
86    ProcQueryXInfo,
87    ProcQueryXExtents,
88    ProcQueryXExtents,
89    ProcQueryXBitmaps,
90    ProcQueryXBitmaps,		/* 20 */
91    ProcCloseFont,
92    0,
93    0,
94    0
95};
96
97SwappedProcFunc SwappedProcVector[NUM_PROC_VECTORS] =
98{
99    SProcSimpleRequest,		/* 0 */
100    SProcSimpleRequest,
101    SProcQueryExtension,
102    SProcListCatalogues,
103    SProcSimpleRequest,		/* SetCatalogues */
104    SProcSimpleRequest,		/* 5 */
105    SProcResourceRequest,	/* SetEventMask */
106    SProcSimpleRequest,
107    SProcCreateAC,
108    SProcResourceRequest,
109    SProcResourceRequest,	/* 10 */
110    SProcSetResolution,
111    SProcSimpleRequest,
112    SProcListFonts,
113    SProcListFontsWithXInfo,
114    SProcOpenBitmapFont,	/* 15 */
115    SProcResourceRequest,
116    SProcQueryXExtents,
117    SProcQueryXExtents,
118    SProcQueryXBitmaps,
119    SProcQueryXBitmaps,		/* 20 */
120    SProcResourceRequest,
121    0,
122    0,
123    0
124};
125
126EventSwapFunc EventSwapVector[NUM_EVENT_VECTORS] =
127{
128    SErrorEvent,
129    (EventSwapFunc)NotImplemented,
130    0,
131    0,
132    0,
133    0,
134    0,
135    0
136};
137
138ReplySwapFunc ReplySwapVector[NUM_PROC_VECTORS] =
139{
140    (ReplySwapFunc)NotImplemented,		/* NoOp */
141    SListExtensionsReply,
142    SQueryExtensionReply,	/* SQueryExtensionReply */
143    SListCataloguesReply,
144    (ReplySwapFunc)NotImplemented,		/* SetCatalogues */
145    SGenericReply,		/* GetCatalogues */
146    (ReplySwapFunc)NotImplemented,		/* SetEventMask */
147    SGetEventMaskReply,
148    SCreateACReply,
149    (ReplySwapFunc)NotImplemented,		/* FreeAC */
150    (ReplySwapFunc)NotImplemented,		/* SetAuthorization - 10 */
151    (ReplySwapFunc)NotImplemented,		/* SetResolution */
152    SGetResolutionReply,
153    SListFontsReply,
154    SListFontsWithXInfoReply,
155    SOpenBitmapFontReply,	/* 15 */
156    SQueryXInfoReply,
157    SQueryXExtentsReply,
158    SQueryXExtentsReply,
159    SQueryXBitmapsReply,
160    SQueryXBitmapsReply,	/* 20 */
161    (ReplySwapFunc)NotImplemented,		/* Close */
162    (ReplySwapFunc)NotImplemented,
163    (ReplySwapFunc)NotImplemented
164};
165