/* IBM_PROLOG_BEGIN_TAG */ /* This is an automatically generated prolog. */ /* */ /* onc720 src/oncplus/usr/include/tirpc/rpc/pmap_clnt.h 1.5.1.1 */ /* */ /* Licensed Materials - Property of IBM */ /* */ /* COPYRIGHT International Business Machines Corp. 1996,2012 */ /* All Rights Reserved */ /* */ /* US Government Users Restricted Rights - Use, duplication or */ /* disclosure restricted by GSA ADP Schedule Contract with IBM Corp. */ /* */ /* IBM_PROLOG_END_TAG */ /* * Copyright (c) 1986 - 1991 by Sun Microsystems, Inc. */ #ifndef _RPC_PMAPCLNT_H #define _RPC_PMAPCLNT_H /* #pragma ident "@(#)pmap_clnt.h 1.11 93/11/12 SMI" */ /* @(#)pmap_clnt.h 1.14 88/10/25 SMI */ /* * pmap_clnt.h * Supplies C routines to get to portmap services. */ #include #include #ifdef __cplusplus extern "C" { #endif /* * Usage: * success = pmap_set(program, version, protocol, port); * success = pmap_unset(program, version); * port = pmap_getport(address, program, version, protocol); * head = pmap_getmaps(address); * clnt_stat = pmap_rmtcall(address, program, version, procedure, * argsp, xdrargs, resp, xdrres, tout, port_ptr) * (works for udp only.) * clnt_stat = clnt_broadcast(program, version, procedure, * xdrargs, argsp, xdrres, resp, eachresult) * (like pmap_rmtcall, except the call is broadcasted to all * locally connected nets. For each valid response received, * the procedure eachresult is called. Its form is: * done = eachresult(resp, raddr) * bool_t done; * caddr_t resp; * struct sockaddr_in raddr; * where resp points to the results of the call and raddr is the * address if the responder to the broadcast. */ extern bool_t pmap_set(rpcprog_t , rpcvers_t, rpcprot_t, unsigned short port); extern bool_t pmap_unset(rpcprog_t, rpcvers_t); extern struct pmaplist *pmap_getmaps(struct sockaddr_in *); extern u_short pmap_getport(struct sockaddr_in *, rpcprog_t, rpcvers_t, rpcprot_t); extern u_short pmap_getport6(struct sockaddr_in6 *, rpcprog_t, rpcvers_t, rpcprot_t); enum clnt_stat clnt_broadcast(u_long, u_long, u_long, xdrproc_t, char *, xdrproc_t, char *, resultproc_t); enum clnt_stat pmap_rmtcall(struct sockaddr_in *, rpcprog_t, rpcvers_t, rpcproc_t, caddr_t, xdrproc_t, caddr_t, xdrproc_t, struct timeval, rpcport_t *); #ifdef __cplusplus } #endif #endif /* _RPC_PMAPCLNT_H */