ONC+ Developer's Guide

Operation Directions

At times you may want to optimize XDR routines by taking advantage of the direction of the operation--XDR_ENCODE, XDR_DECODE or XDR_FREE. The value xdrs->x_op always contains the direction of the XDR operation. An example in "Linked Lists" demonstrates the usefulness of the xdrs->x_op field.