Generated encode functions are invoked through the class interface by calling the base class Encode method. The calling sequence for this method is as follows:
stat = <object>.Encode ();
In this definition, <object> is an object of the class generated for the given production. The function result variable stat returns the status value from the XER encode function. This status value will be zero if encoding was successful or a negative error status value if encoding fails. Return status values are defined in the rtxErrCodes.h include file.
The user must call the encode buffer class methods getMsgPtr and getMsgLen to obtain the starting address and length of the encoded message component.