Rearrange the header files.
[deb_libnfs.git] / portmap / libnfs-raw-portmap.h
CommitLineData
763cd6e3
RS
1/*
2 * Please do not edit this file.
3 * It was generated using rpcgen.
4 */
5
6#ifndef _PORTMAP_H_RPCGEN
7#define _PORTMAP_H_RPCGEN
8
e803ae57 9#include <nfsc/libnfs-zdr.h>
763cd6e3
RS
10
11#ifdef __cplusplus
12extern "C" {
13#endif
14
15#define PMAP_PORT 111
16
17struct pmap_mapping {
18 u_int prog;
19 u_int vers;
20 u_int prot;
21 u_int port;
22};
23typedef struct pmap_mapping pmap_mapping;
24
25struct pmap_call_args {
26 u_int prog;
27 u_int vers;
28 u_int proc;
29 struct {
30 u_int args_len;
31 char *args_val;
32 } args;
33};
34typedef struct pmap_call_args pmap_call_args;
35
36struct pmap_call_result {
37 u_int port;
38 struct {
39 u_int res_len;
40 char *res_val;
41 } res;
42};
43typedef struct pmap_call_result pmap_call_result;
44
45#define PMAP_PROGRAM 100000
46#define PMAP_V2 2
47
48#if defined(__STDC__) || defined(__cplusplus)
49#define PMAP_NULL 0
50extern void * pmap_null_2(void *, CLIENT *);
51extern void * pmap_null_2_svc(void *, struct svc_req *);
52#define PMAP_SET 1
53extern bool_t * pmap_set_2(pmap_mapping *, CLIENT *);
54extern bool_t * pmap_set_2_svc(pmap_mapping *, struct svc_req *);
55#define PMAP_UNSET 2
56extern bool_t * pmap_unset_2(pmap_mapping *, CLIENT *);
57extern bool_t * pmap_unset_2_svc(pmap_mapping *, struct svc_req *);
58#define PMAP_GETPORT 3
59extern u_int * pmap_getport_2(pmap_mapping *, CLIENT *);
60extern u_int * pmap_getport_2_svc(pmap_mapping *, struct svc_req *);
61#define PMAP_CALLIT 5
62extern pmap_call_result * pmap_callit_2(pmap_call_args *, CLIENT *);
63extern pmap_call_result * pmap_callit_2_svc(pmap_call_args *, struct svc_req *);
64extern int pmap_program_2_freeresult (SVCXPRT *, zdrproc_t, caddr_t);
65
66#else /* K&R C */
67#define PMAP_NULL 0
68extern void * pmap_null_2();
69extern void * pmap_null_2_svc();
70#define PMAP_SET 1
71extern bool_t * pmap_set_2();
72extern bool_t * pmap_set_2_svc();
73#define PMAP_UNSET 2
74extern bool_t * pmap_unset_2();
75extern bool_t * pmap_unset_2_svc();
76#define PMAP_GETPORT 3
77extern u_int * pmap_getport_2();
78extern u_int * pmap_getport_2_svc();
79#define PMAP_CALLIT 5
80extern pmap_call_result * pmap_callit_2();
81extern pmap_call_result * pmap_callit_2_svc();
82extern int pmap_program_2_freeresult ();
83#endif /* K&R C */
84
85/* the zdr functions */
86
87#if defined(__STDC__) || defined(__cplusplus)
88extern bool_t zdr_pmap_mapping (ZDR *, pmap_mapping*);
89extern bool_t zdr_pmap_call_args (ZDR *, pmap_call_args*);
90extern bool_t zdr_pmap_call_result (ZDR *, pmap_call_result*);
91
92#else /* K&R C */
93extern bool_t zdr_pmap_mapping ();
94extern bool_t zdr_pmap_call_args ();
95extern bool_t zdr_pmap_call_result ();
96
97#endif /* K&R C */
98
99#ifdef __cplusplus
100}
101#endif
102
103#endif /* !_PORTMAP_H_RPCGEN */