ns3-bgp
0.2
BGP module for ns-3.
|
Simple container class for FSM to send data to peer. More...
#include <bgp-ns3-socket-out.h>
Public Member Functions | |
BgpNs3SocketOut (Ptr< Socket > socket, Callback< void, Ptr< Socket >, int, int > state_change_cb) | |
Construct the container. More... | |
bool | handleOut (const uint8_t *buffer, size_t length) |
Handle output from libbgp. See libbgp document. More... | |
void | notifyStateChange (int old_state, int new_state) |
Handle state change notification from libbgp. See libbgp document. More... | |
void | setStateChangeCallback (Callback< void, Ptr< Socket >, int, int > state_change_cb) |
Set callback to use when FSM change state. More... | |
Public Member Functions inherited from libbgp::BgpOutHandler | |
virtual void | notifyStateChange (__attribute__((unused)) int old_state, __attribute__((unused)) int new_state) |
Simple container class for FSM to send data to peer.
Definition at line 25 of file bgp-ns3-socket-out.h.
ns3::BgpNs3SocketOut::BgpNs3SocketOut | ( | Ptr< Socket > | socket, |
Callback< void, Ptr< Socket >, int, int > | state_change_cb | ||
) |
Construct the container.
socket | socket to write to. |
state_change_cb | Callback to notify FSM state changes. |
Definition at line 21 of file bgp-ns3-socket-out.cc.
|
virtual |
Handle output from libbgp. See libbgp document.
buffer | Packet buffer. |
length | Buffer size. |
Implements libbgp::BgpOutHandler.
Definition at line 34 of file bgp-ns3-socket-out.cc.
void ns3::BgpNs3SocketOut::notifyStateChange | ( | int | old_state, |
int | new_state | ||
) |
Handle state change notification from libbgp. See libbgp document.
old_state | Old state. |
new_state | New state. |
Definition at line 44 of file bgp-ns3-socket-out.cc.
void ns3::BgpNs3SocketOut::setStateChangeCallback | ( | Callback< void, Ptr< Socket >, int, int > | state_change_cb | ) |
Set callback to use when FSM change state.
state_change_cb | Callback. |
Definition at line 53 of file bgp-ns3-socket-out.cc.