An encoder for XDR, the eXternal Data Representation format. More...
#include <XDREncoder.h++>
Public Member Functions | |
| XDREncoder (DataWriter &writer) | |
| Construct a new XDREncoder that will encode values to the given DataWriter. | |
| ~XDREncoder () throw () | |
| Destructor. | |
| XDREncoder & | encode (bool v) throw (IOException) |
| Encode a boolean value. | |
| XDREncoder & | encode (byte_t v) throw (IOException) |
| Encode a byte value. | |
| XDREncoder & | encode (char v) throw (IOException) |
| Encode a char value. | |
| XDREncoder & | encode (int16_t v) throw (IOException) |
| Encode a signed 16-bit integer value. | |
| XDREncoder & | encode (uint16_t v) throw (IOException) |
| Encode an unsigned 16-bit integer value. | |
| XDREncoder & | encode (int32_t v) throw (IOException) |
| Encode a signed 32-bit integer value. | |
| XDREncoder & | encode (uint32_t v) throw (IOException) |
| Encode an unsigned 32-bit integer value. | |
| XDREncoder & | encode (const int64_t &v) throw (IOException) |
| Encode a signed 64-bit integer value. | |
| XDREncoder & | encode (const uint64_t &v) throw (IOException) |
| Encode an unsigned 64-bit integer value. | |
| XDREncoder & | encode (float v) throw (IOException) |
| Encode a floating point value. | |
| XDREncoder & | encode (const double &v) throw (IOException) |
| Encode a double-precision floating point value. | |
| XDREncoder & | encode (const char *s, size_t maxlen=0) throw (IOException) |
| Encode a string. | |
| XDREncoder & | encode (const String &s, size_t maxlen=0) throw (IOException) |
| Encode a string. | |
| XDREncoder & | encode (const byte_t *v, size_t len) throw (IOException) |
| Encode a block of opaque data. | |
| XDREncoder & | encode (const Variant &v) throw (IOException) |
| Encode an arbitrary Variant value. | |
An encoder for XDR, the eXternal Data Representation format.
XDR is a scheme for encoding primitive datatypes in a platform-independent manner. For more information, see RFC 1832.
| XDREncoder | ( | DataWriter & | writer | ) |
Construct a new XDREncoder that will encode values to the given DataWriter.
| writer | The DataWriter. |
| ~XDREncoder | ( | ) | throw () |
Destructor.
| XDREncoder & encode | ( | const Variant & | v | ) | throw (IOException) |
Encode an arbitrary Variant value.
| v | The Variant to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder & encode | ( | const byte_t * | v, | |
| size_t | len | |||
| ) | throw (IOException) |
Encode a block of opaque data.
| v | The byte array to encode. | |
| len | The number of bytes to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | const String & | s, | |
| size_t | maxlen = 0 | |||
| ) | throw (IOException) [inline] |
Encode a string.
| s | The String to encode. | |
| maxlen | The maximum number of characters to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder & encode | ( | const char * | s, | |
| size_t | maxlen = 0 | |||
| ) | throw (IOException) |
Encode a string.
| s | The character array to encode. | |
| maxlen | The maximum number of characters to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | const double & | v | ) | throw (IOException) [inline] |
Encode a double-precision floating point value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | float | v | ) | throw (IOException) [inline] |
Encode a floating point value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | const uint64_t & | v | ) | throw (IOException) [inline] |
Encode an unsigned 64-bit integer value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | const int64_t & | v | ) | throw (IOException) [inline] |
Encode a signed 64-bit integer value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | uint32_t | v | ) | throw (IOException) [inline] |
Encode an unsigned 32-bit integer value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | int32_t | v | ) | throw (IOException) [inline] |
Encode a signed 32-bit integer value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | uint16_t | v | ) | throw (IOException) [inline] |
Encode an unsigned 16-bit integer value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | int16_t | v | ) | throw (IOException) [inline] |
Encode a signed 16-bit integer value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | char | v | ) | throw (IOException) [inline] |
Encode a char value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | byte_t | v | ) | throw (IOException) [inline] |
Encode a byte value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
| XDREncoder& encode | ( | bool | v | ) | throw (IOException) [inline] |
Encode a boolean value.
| v | The value to encode. |
| IOException | If an I/O error occcurs. |
1.6.3