X-TraceC++Library
|
A No-op option for X-Trace, serialized to a single '0' byte. More...
#include <XtrOption.h>
Public Member Functions | |
OptionNop () | |
OptionNop (const u_int8_t *b, size_t *size) | |
OptionNop * | clone () const |
Returns a pointer to a newly allocated Option, of the same subtype as the cloned object. | |
u_int8_t | getType () const |
Returns the type of this option. | |
u_int8_t | getLength () const |
Returns the length of the payload for this option. | |
u_int8_t | getSize () const |
Returns the size of the options when packed. | |
xtr_result | pack (u_int8_t *dest, size_t *size) const |
Writes the binary packed form of this option to the destination. |
A No-op option for X-Trace, serialized to a single '0' byte.
This option can be used as a space filler or for testing.
xtr::OptionNop::OptionNop | ( | ) | [inline] |
Referenced by clone().
xtr::OptionNop::OptionNop | ( | const u_int8_t * | b, |
size_t * | size | ||
) |
OptionNop* xtr::OptionNop::clone | ( | ) | const [inline, virtual] |
Returns a pointer to a newly allocated Option, of the same subtype as the cloned object.
Implements xtr::Option.
References OptionNop().
u_int8_t xtr::OptionNop::getLength | ( | ) | const [inline, virtual] |
Returns the length of the payload for this option.
Implements xtr::Option.
u_int8_t xtr::OptionNop::getSize | ( | ) | const [inline, virtual] |
Returns the size of the options when packed.
Implements xtr::Option.
u_int8_t xtr::OptionNop::getType | ( | ) | const [inline, virtual] |
xtr_result xtr::OptionNop::pack | ( | u_int8_t * | dest, |
size_t * | size | ||
) | const [virtual] |
Writes the binary packed form of this option to the destination.
dest | buffer to write option to |
size | INPUT: maximum safe size to write to dest OUTPUT: actual number of bytes written |
Implements xtr::Option.