]> git.saurik.com Git - apple/network_cmds.git/blob - ypserv.tproj/ypv1.h
network_cmds-176.tar.gz
[apple/network_cmds.git] / ypserv.tproj / ypv1.h
1 /*
2 * Copyright (c) 1999 Apple Computer, Inc. All rights reserved.
3 *
4 * @APPLE_LICENSE_HEADER_START@
5 *
6 * Copyright (c) 1999-2003 Apple Computer, Inc. All Rights Reserved.
7 *
8 * This file contains Original Code and/or Modifications of Original Code
9 * as defined in and that are subject to the Apple Public Source License
10 * Version 2.0 (the 'License'). You may not use this file except in
11 * compliance with the License. Please obtain a copy of the License at
12 * http://www.opensource.apple.com/apsl/ and read it before using this
13 * file.
14 *
15 * The Original Code and all software distributed under the License are
16 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
17 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
18 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
19 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
20 * Please see the License for the specific language governing rights and
21 * limitations under the License.
22 *
23 * @APPLE_LICENSE_HEADER_END@
24 */
25 /* $OpenBSD: ypv1.h,v 1.2 1997/07/25 20:12:31 mickey Exp $ */
26
27 /*
28 * Please do not edit this file.
29 * It was generated using rpcgen.
30 */
31
32 #ifndef _YPV1_H_RPCGEN
33 #define _YPV1_H_RPCGEN
34
35 #include <rpc/rpc.h>
36
37 #define YPOLDVERS ((u_long)1)
38
39 enum ypreqtype {
40 YPREQ_KEY = 1,
41 YPREQ_NOKEY = 2,
42 YPREQ_MAP_PARMS = 3
43 };
44 typedef enum ypreqtype ypreqtype;
45 #ifdef __cplusplus
46 extern "C" bool_t xdr_ypreqtype(XDR *, ypreqtype*);
47 #elif defined(__STDC__)
48 extern bool_t xdr_ypreqtype(XDR *, ypreqtype*);
49 #else /* Old Style C */
50 bool_t xdr_ypreqtype();
51 #endif /* Old Style C */
52
53 typedef struct {
54 ypreqtype yp_reqtype;
55 union {
56 struct ypreq_key yp_req_keytype;
57 struct ypreq_nokey yp_req_nokeytype;
58 struct ypmap_parms yp_req_map_parmstype;
59 }yp_reqbody;
60 } yprequest;
61 #ifdef __cplusplus
62 extern "C" bool_t xdr_yprequest(XDR *, yprequest*);
63 #elif defined(__STDC__)
64 extern bool_t xdr_yprequest(XDR *, yprequest*);
65 #else /* Old Style C */
66 bool_t xdr_yprequest();
67 #endif /* Old Style C */
68
69 #define YPMATCH_REQTYPE YPREQ_KEY
70 #define ypmatch_req_domain yp_reqbody.yp_req_keytype.domain
71 #define ypmatch_req_map yp_reqbody.yp_req_keytype.map
72 #define ypmatch_req_keydat yp_reqbody.yp_req_keytype.key
73 #define ypmatch_req_keyptr yp_reqbody.yp_req_keytype.key.keydat_val
74 #define ypmatch_req_keysize yp_reqbody.yp_req_keytype.key.keydat_len
75
76 #define YPFIRST_REQTYPE YPREQ_NOKEY
77 #define ypfirst_req_domain yp_reqbody.yp_req_nokeytype.domain
78 #define ypfirst_req_map yp_reqbody.yp_req_nokeytype.map
79
80 #define YPNEXT_REQTYPE YPREQ_KEY
81 #define ypnext_req_domain yp_reqbody.yp_req_keytype.domain
82 #define ypnext_req_map yp_reqbody.yp_req_keytype.map
83 #define ypnext_req_keydat yp_reqbody.yp_req_keytype.key
84 #define ypnext_req_keyptr yp_reqbody.yp_req_keytype.key.keydat_val
85 #define ypnext_req_keysize yp_reqbody.yp_req_keytype.key.keydat_len
86
87 #define YPPUSH_REQTYPE YPREQ_NOKEY
88 #define yppush_req_domain yp_reqbody.yp_req_nokeytype.domain
89 #define yppush_req_map yp_reqbody.yp_req_nokeytype.map
90
91 #define YPPULL_REQTYPE YPREQ_NOKEY
92 #define yppull_req_domain yp_reqbody.yp_req_nokeytype.domain
93 #define yppull_req_map yp_reqbody.yp_req_nokeytype.map
94
95 #define YPPOLL_REQTYPE YPREQ_NOKEY
96 #define yppoll_req_domain yp_reqbody.yp_req_nokeytype.domain
97 #define yppoll_req_map yp_reqbody.yp_req_nokeytype.map
98
99 #define YPGET_REQTYPE YPREQ_MAP_PARMS
100 #define ypget_req_domain yp_reqbody.yp_req_map_parmstype.domain
101 #define ypget_req_map yp_reqbody.yp_req_map_parmstype.map
102 #define ypget_req_ordernum yp_reqbody.yp_req_map_parmstype.ordernum
103 #define ypget_req_owner yp_reqbody.yp_req_map_parmstype.peer
104
105 enum ypresptype {
106 YPRESP_VAL = 1,
107 YPRESP_KEY_VAL = 2,
108 YPRESP_MAP_PARMS = 3
109 };
110 typedef enum ypresptype ypresptype;
111 #ifdef __cplusplus
112 extern "C" bool_t xdr_ypresptype(XDR *, ypresptype*);
113 #elif defined(__STDC__)
114 extern bool_t xdr_ypresptype(XDR *, ypresptype*);
115 #else /* Old Style C */
116 bool_t xdr_ypresptype();
117 #endif /* Old Style C */
118
119 typedef struct {
120 ypresptype yp_resptype;
121 union {
122 struct ypresp_val yp_resp_valtype;
123 struct ypresp_key_val yp_resp_key_valtype;
124 struct ypmap_parms yp_resp_map_parmstype;
125 } yp_respbody;
126 } ypresponse;
127 #ifdef __cplusplus
128 extern "C" bool_t xdr_ypresponse(XDR *, ypresponse*);
129 #elif defined(__STDC__)
130 extern bool_t xdr_ypresponse(XDR *, ypresponse*);
131 #else /* Old Style C */
132 bool_t xdr_ypresponse();
133 #endif /* Old Style C */
134
135 #define YPMATCH_RESPTYPE YPRESP_VAL
136 #define ypmatch_resp_status yp_respbody.yp_resp_valtype.stat
137 #define ypmatch_resp_val yp_respbody.yp_resp_valtype
138 #define ypmatch_resp_valdat yp_respbody.yp_resp_valtype.val
139 #define ypmatch_resp_valptr yp_respbody.yp_resp_valtype.val.valdat_val
140 #define ypmatch_resp_valsize yp_respbody.yp_resp_valtype.val.valdat_len
141
142 #define YPFIRST_RESPTYPE YPRESP_KEY_VAL
143 #define ypfirst_resp_status yp_respbody.yp_resp_key_valtype.stat
144 #define ypfirst_resp_keydat yp_respbody.yp_resp_key_valtype.key
145 #define ypfirst_resp_keyptr yp_respbody.yp_resp_key_valtype.key.keydat_val
146 #define ypfirst_resp_keysize yp_respbody.yp_resp_key_valtype.key.keydat_len
147 #define ypfirst_resp_val yp_respbody.yp_resp_key_valtype
148 #define ypfirst_resp_valdat yp_respbody.yp_resp_key_valtype.val
149 #define ypfirst_resp_valptr yp_respbody.yp_resp_key_valtype.val.valdat_val
150 #define ypfirst_resp_valsize yp_respbody.yp_resp_key_valtype.val.valdat_len
151
152 #define YPNEXT_RESPTYPE YPRESP_KEY_VAL
153 #define ypnext_resp_status yp_respbody.yp_resp_key_valtype.stat
154 #define ypnext_resp_keydat yp_respbody.yp_resp_key_valtype.key
155 #define ypnext_resp_keyptr yp_respbody.yp_resp_key_valtype.key.keydat_val
156 #define ypnext_resp_keysize yp_respbody.yp_resp_key_valtype.key.keydat_len
157 #define ypnext_resp_val yp_respbody.yp_resp_key_valtype
158 #define ypnext_resp_valdat yp_respbody.yp_resp_key_valtype.val
159 #define ypnext_resp_valptr yp_respbody.yp_resp_key_valtype.val.valdat_val
160 #define ypnext_resp_valsize yp_respbody.yp_resp_key_valtype.val.valdat_len
161
162 #define YPPOLL_RESPTYPE YPRESP_MAP_PARMS
163 #define yppoll_resp_domain yp_respbody.yp_resp_map_parmstype.domain
164 #define yppoll_resp_map yp_respbody.yp_resp_map_parmstype.map
165 #define yppoll_resp_ordernum yp_respbody.yp_resp_map_parmstype.ordernum
166 #define yppoll_resp_owner yp_respbody.yp_resp_map_parmstype.peer
167
168 #ifdef __cplusplus
169 #define YPOLDPROC_NULL ((u_long)0)
170 extern "C" void * ypproc_null_1(void *, CLIENT *);
171 extern "C" void * ypproc_null_1_svc(void *, struct svc_req *);
172 #define YPOLDPROC_DOMAIN ((u_long)1)
173 extern "C" bool_t * ypproc_domain_1(domainname *, CLIENT *);
174 extern "C" bool_t * ypproc_domain_1_svc(domainname *, struct svc_req *);
175 #define YPOLDPROC_DOMAIN_NONACK ((u_long)2)
176 extern "C" bool_t * ypproc_domain_nonack_1(domainname *, CLIENT *);
177 extern "C" bool_t * ypproc_domain_nonack_1_svc(domainname *, struct svc_req *);
178 #define YPOLDPROC_MATCH ((u_long)3)
179 extern "C" ypresponse * ypproc_match_1(yprequest *, CLIENT *);
180 extern "C" ypresponse * ypproc_match_1_svc(yprequest *, struct svc_req *);
181 #define YPOLDPROC_FIRST ((u_long)4)
182 extern "C" ypresponse * ypproc_first_1(yprequest *, CLIENT *);
183 extern "C" ypresponse * ypproc_first_1_svc(yprequest *, struct svc_req *);
184 #define YPOLDPROC_NEXT ((u_long)5)
185 extern "C" ypresponse * ypproc_next_1(yprequest *, CLIENT *);
186 extern "C" ypresponse * ypproc_next_1_svc(yprequest *, struct svc_req *);
187 #define YPOLDPROC_POLL ((u_long)6)
188 extern "C" ypresponse * ypproc_poll_1(yprequest *, CLIENT *);
189 extern "C" ypresponse * ypproc_poll_1_svc(yprequest *, struct svc_req *);
190 #define YPOLDPROC_PUSH ((u_long)7)
191 extern "C" void * ypproc_push_1(yprequest *, CLIENT *);
192 extern "C" void * ypproc_push_1_svc(yprequest *, struct svc_req *);
193 #define YPOLDPROC_PULL ((u_long)8)
194 extern "C" void * ypproc_pull_1(yprequest *, CLIENT *);
195 extern "C" void * ypproc_pull_1_svc(yprequest *, struct svc_req *);
196 #define YPOLDPROC_GET ((u_long)9)
197 extern "C" void * ypproc_get_1(yprequest *, CLIENT *);
198 extern "C" void * ypproc_get_1_svc(yprequest *, struct svc_req *);
199
200 #elif defined(__STDC__)
201 #define YPOLDPROC_NULL ((u_long)0)
202 extern void * ypproc_null_1(void *, CLIENT *);
203 extern void * ypproc_null_1_svc(void *, struct svc_req *);
204 #define YPOLDPROC_DOMAIN ((u_long)1)
205 extern bool_t * ypproc_domain_1(domainname *, CLIENT *);
206 extern bool_t * ypproc_domain_1_svc(domainname *, struct svc_req *);
207 #define YPOLDPROC_DOMAIN_NONACK ((u_long)2)
208 extern bool_t * ypproc_domain_nonack_1(domainname *, CLIENT *);
209 extern bool_t * ypproc_domain_nonack_1_svc(domainname *, struct svc_req *);
210 #define YPOLDPROC_MATCH ((u_long)3)
211 extern ypresponse * ypproc_match_1(yprequest *, CLIENT *);
212 extern ypresponse * ypproc_match_1_svc(yprequest *, struct svc_req *);
213 #define YPOLDPROC_FIRST ((u_long)4)
214 extern ypresponse * ypproc_first_1(yprequest *, CLIENT *);
215 extern ypresponse * ypproc_first_1_svc(yprequest *, struct svc_req *);
216 #define YPOLDPROC_NEXT ((u_long)5)
217 extern ypresponse * ypproc_next_1(yprequest *, CLIENT *);
218 extern ypresponse * ypproc_next_1_svc(yprequest *, struct svc_req *);
219 #define YPOLDPROC_POLL ((u_long)6)
220 extern ypresponse * ypproc_poll_1(yprequest *, CLIENT *);
221 extern ypresponse * ypproc_poll_1_svc(yprequest *, struct svc_req *);
222 #define YPOLDPROC_PUSH ((u_long)7)
223 extern void * ypproc_push_1(yprequest *, CLIENT *);
224 extern void * ypproc_push_1_svc(yprequest *, struct svc_req *);
225 #define YPOLDPROC_PULL ((u_long)8)
226 extern void * ypproc_pull_1(yprequest *, CLIENT *);
227 extern void * ypproc_pull_1_svc(yprequest *, struct svc_req *);
228 #define YPOLDPROC_GET ((u_long)9)
229 extern void * ypproc_get_1(yprequest *, CLIENT *);
230 extern void * ypproc_get_1_svc(yprequest *, struct svc_req *);
231
232 #else /* Old Style C */
233 #define YPOLDPROC_NULL ((u_long)0)
234 extern void * ypproc_null_1();
235 extern void * ypproc_null_1_svc();
236 #define YPOLDPROC_DOMAIN ((u_long)1)
237 extern bool_t * ypproc_domain_1();
238 extern bool_t * ypproc_domain_1_svc();
239 #define YPOLDPROC_DOMAIN_NONACK ((u_long)2)
240 extern bool_t * ypproc_domain_nonack_1();
241 extern bool_t * ypproc_domain_nonack_1_svc();
242 #define YPOLDPROC_MATCH ((u_long)3)
243 extern ypresponse * ypproc_match_1();
244 extern ypresponse * ypproc_match_1_svc();
245 #define YPOLDPROC_FIRST ((u_long)4)
246 extern ypresponse * ypproc_first_1();
247 extern ypresponse * ypproc_first_1_svc();
248 #define YPOLDPROC_NEXT ((u_long)5)
249 extern ypresponse * ypproc_next_1();
250 extern ypresponse * ypproc_next_1_svc();
251 #define YPOLDPROC_POLL ((u_long)6)
252 extern ypresponse * ypproc_poll_1();
253 extern ypresponse * ypproc_poll_1_svc();
254 #define YPOLDPROC_PUSH ((u_long)7)
255 extern void * ypproc_push_1();
256 extern void * ypproc_push_1_svc();
257 #define YPOLDPROC_PULL ((u_long)8)
258 extern void * ypproc_pull_1();
259 extern void * ypproc_pull_1_svc();
260 #define YPOLDPROC_GET ((u_long)9)
261 extern void * ypproc_get_1();
262 extern void * ypproc_get_1_svc();
263 #endif /* Old Style C */
264
265 #endif /* !_YPV1_H_RPCGEN */