RoutingSocketReader (RoutingSocket& rs)
| RoutingSocketReader |
~RoutingSocketReader ()
| ~RoutingSocketReader |
[virtual]
int receive_data (RoutingSocket& rs, uint32_t seqno, string& error_msg)
| receive_data |
Force the reader to receive data from the specified routing socket.
Parameters:
rs | the routing socket to receive the data from. |
seqno | the sequence number of the data to receive. |
error_msg | the error message (if error). |
Returns: XORP_OK on success, otherwise XORP_ERROR.
const uint8_t* buffer ()
| buffer |
[const]
Get the buffer with the data that was received.
Returns: a pointer to the beginning of the buffer with the data that was received.
const size_t buffer_size ()
| buffer_size |
[const]
Get the size of the buffer with the data that was received.
Returns: the size of the buffer with the data that was received.
void rtsock_data (const uint8_t* data, size_t nbytes)
| rtsock_data |
[virtual]
Receive data from the routing socket.
Note that this method is called asynchronously when the routing socket has data to receive, therefore it should never be called directly by anything else except the routing socket facility itself.
Parameters:
data | the buffer with the received data. |
nbytes | the number of bytes in the data buffer. |
Reimplemented from RoutingSocketObserver.