xdr_admin, xdr_getpos, xdr_inline, xdr_setpos-library routines for external data representation
XDR library routines allow C programmers to describe arbitrary data structures in a machine-independent fashion. Protocols such as communications calls use these routines to describe the format of the data.
These routines deal specifically with the management of the XDR stream.
#include <rpc/xdr.h>
u_int xdr_getpos(const XDR *xdrs)
XDR stream, xdrs. The routine returns an unsigned integer, which indicates the position of the XDR byte stream. A desirable feature of XDR streams is that simple arithmetic works with this number, although the XDR stream instances need not guarantee this. Therefore, applications written for portability should not depend on this feature.
long * xdr_inline(XDR *xdrs, const int len)
XDR stream, xdrs. The routine returns a pointer to a contiguous piece of the stream's buffer; len is the byte length of the desired buffer. Note: pointer is cast to long *. Warning: xdr_inline may return NULL (0) if it cannot allocate a contiguous piece of a buffer. Therefore the behavior may vary among stream instances; it exists for the sake of efficiency, and applications written for portability should not depend on this feature.
bool_t xdr_setpos(XDR *xdrs, const u_int pos)
XDR stream xdrs. The parameter pos is a position value obtained from xdr_getpos. This routine returns 1 if the XDR stream was repositioned, and 0 otherwise. Warning: it is difficult to reposition some types of XDR streams, so this routine may fail with one type of stream and succeed with another. Therefore, applications written for portability should not depend on this feature.
xdr_complex(3I), xdr_create(3I), xdr_simple(3I).