Revised OpenFlow Library  v0.6.0dev
 All Classes Files Functions Variables Friends Groups Pages
Public Member Functions | Friends | List of all members
rofl::crofbase Class Reference

Base class for revised OpenFlow library. More...

#include <crofbase.h>

Public Member Functions

 crofbase (const rofl::openflow::cofhello_elem_versionbitmap &versionbitmap=rofl::openflow::cofhello_elem_versionbitmap())
 crofbase constructor More...
 
virtual ~crofbase ()
 crofbase destructor More...
 
Methods for listening sockets accepting connections from datapath elements
void close_dpt_listening ()
 Closes all listening csocket instances.
 
rofl::csocketadd_dpt_listening (unsigned int sockid, enum rofl::csocket::socket_type_t socket_type, const rofl::cparams &params)
 Creates a new listening rofl::csocket instance for accepting incoming OpenFlow connections. More...
 
rofl::csocketset_dpt_listening (unsigned int sockid, enum rofl::csocket::socket_type_t socket_type, const rofl::cparams &params)
 Returns a reference to the listening csocket object specified by identifier sockid. More...
 
const rofl::csocketget_dpt_listening (unsigned int sockid) const
 Returns a const reference to the listening csocket object specified by identifier sockid. More...
 
void drop_dpt_listening (unsigned int sockid)
 Removes a listening socket identified by sockid. More...
 
bool has_dpt_listening (unsigned int sockid)
 Checks for existence of a listening socket identified by sockid. More...
 
Methods for listening sockets accepting connections from controller entities
void close_ctl_listening ()
 Closes all listening csocket instances.
 
rofl::csocketadd_ctl_listening (unsigned int sockid, enum rofl::csocket::socket_type_t socket_type, const rofl::cparams &params)
 Creates a new listening rofl::csocket instance for accepting incoming OpenFlow connections. More...
 
rofl::csocketset_ctl_listening (unsigned int sockid, enum rofl::csocket::socket_type_t socket_type, const rofl::cparams &params)
 Returns a reference to the listening csocket object specified by identifier sockid. More...
 
const rofl::csocketget_ctl_listening (unsigned int sockid) const
 Returns a const reference to the listening csocket object specified by identifier sockid. More...
 
void drop_ctl_listening (unsigned int sockid)
 Removes a listening socket identified by sockid. More...
 
bool has_ctl_listening (unsigned int sockid)
 Checks for existence of a listening socket identified by sockid. More...
 
Methods for managing peer entities acting in datapath role
rofl::cdptid get_idle_dptid () const
 Returns the next idle identifier for a new rofl::crofdpt instance. More...
 
void drop_dpts ()
 Deletes all existing rofl::crofdpt instances.
 
rofl::crofdptadd_dpt (const rofl::cdptid &dptid, const rofl::openflow::cofhello_elem_versionbitmap &versionbitmap, bool remove_on_channel_close=false, const rofl::cdpid &dpid=rofl::cdpid(0))
 Creates new rofl::crofdpt instance for given identifier. More...
 
rofl::crofdptset_dpt (const rofl::cdptid &dptid, const rofl::openflow::cofhello_elem_versionbitmap &versionbitmap, bool remove_on_channel_close=false, const rofl::cdpid &dpid=rofl::cdpid(0))
 Returns existing or creates new rofl::crofdpt instance for given identifier. More...
 
rofl::crofdptset_dpt (const rofl::cdptid &dptid)
 Returns reference to existing rofl::crofdpt instance. More...
 
const rofl::crofdptget_dpt (const rofl::cdptid &dptid) const
 Returns const reference to existing rofl::crofdpt instance. More...
 
void drop_dpt (rofl::cdptid dptid)
 Deletes a rofl::crofdpt instance given by identifier. More...
 
bool has_dpt (const rofl::cdptid &dptid) const
 Checks for existence of rofl::crofdpt instance with given identifier. More...
 
Methods for managing peer entities acting in controller role
rofl::cctlid get_idle_ctlid () const
 Returns the next idle identifier for a new rofl::crofctl instance. More...
 
void drop_ctls ()
 Deletes all existing rofl::crofctl instances.
 
rofl::crofctladd_ctl (const rofl::cctlid &ctlid, const rofl::openflow::cofhello_elem_versionbitmap &versionbitmap, bool remove_on_channel_close=false)
 Creates new rofl::crofctl instance for given identifier. More...
 
rofl::crofctlset_ctl (const rofl::cctlid &ctlid, const rofl::openflow::cofhello_elem_versionbitmap &versionbitmap, bool remove_on_channel_close=false)
 Returns existing or creates new rofl::crofctl instance for given identifier. More...
 
rofl::crofctlset_ctl (const rofl::cctlid &ctlid)
 Returns reference to existing rofl::crofctl instance. More...
 
const rofl::crofctlget_ctl (const rofl::cctlid &ctlid) const
 Returns const reference to existing rofl::crofctl instance. More...
 
void drop_ctl (rofl::cctlid ctlid)
 Deletes a rofl::crofctl instance given by identifier. More...
 
bool has_ctl (const rofl::cctlid &ctlid) const
 Checks for existence of rofl::crofctl instance with given identifier. More...
 
- Public Member Functions inherited from rofl::ciosrv
 ciosrv (pthread_t tid=0)
 Initializes all structures for this ciosrv object.
 
virtual ~ciosrv ()
 Deallocates resources for this ciosrv object.
 
 ciosrv (const ciosrv &iosrv)
 Initializes all structures for this ciosrv object.
 
ciosrvoperator= (const ciosrv &iosrv)
 
void notify (const cevent &event)
 Sends a notification to this ciosrv instance. More...
 
pthread_t get_thread_id () const
 Returns thread-id of local thread. More...
 
- Public Member Functions inherited from rofl::csocket_env
virtual ~csocket_env ()
 Destructor.
 
- Public Member Functions inherited from rofl::crofctl_env
 crofctl_env ()
 rofl::crofctl_env constructor
 
virtual ~crofctl_env ()
 rofl::crofctl_env destructor
 
- Public Member Functions inherited from rofl::crofdpt_env
 crofdpt_env ()
 rofl::crofdpt_env constructor
 
virtual ~crofdpt_env ()
 rofl::crofdpt_env destructor
 

Protected Member Functions

Event handlers for management notifications for datapath elements

Overwrite any of these methods for receiving datapath related event notifications.

virtual void handle_dpt_open (rofl::crofdpt &dpt)
 Called after establishing the associated OpenFlow control channel. More...
 
virtual void handle_dpt_close (rofl::crofdpt &dpt)
 Called after termination of associated OpenFlow control channel. More...
 
virtual void handle_conn_established (rofl::crofdpt &dpt, const rofl::cauxid &auxid)
 Called when a control connection (main or auxiliary) has been established. More...
 
virtual void handle_conn_terminated (rofl::crofdpt &dpt, const rofl::cauxid &auxid)
 Called when a control connection (main or auxiliary) has been terminated by the peer entity. More...
 
virtual void handle_conn_refused (rofl::crofdpt &dpt, const rofl::cauxid &auxid)
 Called when an attempt to establish a control connection has been refused. More...
 
virtual void handle_conn_failed (rofl::crofdpt &dpt, const rofl::cauxid &auxid)
 Called when an attempt to establish a control connection has been failed. More...
 
virtual void handle_conn_writable (rofl::crofdpt &dpt, const rofl::cauxid &auxid)
 Called when a congestion situation on the control connection has been solved. More...
 
Event handlers for management notifications for controller entities

Overwrite any of these methods for receiving controller related event notifications.

virtual void handle_ctl_open (rofl::crofctl &ctl)
 Called after establishing the associated OpenFlow control channel. More...
 
virtual void handle_ctl_close (rofl::crofctl &ctl)
 Called after termination of associated OpenFlow control channel. More...
 
virtual void handle_conn_established (rofl::crofctl &ctl, const rofl::cauxid &auxid)
 Called when a control connection (main or auxiliary) has been established. More...
 
virtual void handle_conn_terminated (rofl::crofctl &ctl, const rofl::cauxid &auxid)
 Called when a control connection (main or auxiliary) has been terminated by the peer entity. More...
 
virtual void handle_conn_refused (rofl::crofctl &ctl, const rofl::cauxid &auxid)
 Called when an attempt to establish a control connection has been refused. More...
 
virtual void handle_conn_failed (rofl::crofctl &ctl, const rofl::cauxid &auxid)
 Called when an attempt to establish a control connection has been failed. More...
 
virtual void handle_conn_writable (rofl::crofctl &ctl, const rofl::cauxid &auxid)
 Called when a congestion situation on the control connection has been solved. More...
 
Event handlers for OpenFlow message notifications received from datapath elements

Overwrite any of these methods for receiving messages from the attached datapath element. Once this method terminates, rofl will destroy the message object. If you want to save a message or parts of it, you must create a local copy. All messages are internally allocated on the heap and both allocation and deallocation is handled by rofl-common. Do not delete any of these messages or its internals.

virtual void handle_features_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_features_reply &msg)
 OpenFlow Features-Reply message received. More...
 
virtual void handle_features_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Features-Reply message. More...
 
virtual void handle_get_config_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_get_config_reply &msg)
 OpenFlow Get-Config-Reply message received. More...
 
virtual void handle_get_config_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Get-Config-Reply message. More...
 
virtual void handle_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_stats_reply &msg)
 OpenFlow Stats-Reply message received. More...
 
virtual void handle_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid, uint8_t stats_type)
 Timer expired while waiting for OpenFlow Stats-Reply message. More...
 
virtual void handle_desc_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_desc_stats_reply &msg)
 OpenFlow Desc-Stats-Reply message received. More...
 
virtual void handle_desc_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Desc-Stats-Reply message. More...
 
virtual void handle_table_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_table_stats_reply &msg)
 OpenFlow Table-Stats-Reply message received. More...
 
virtual void handle_table_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Table-Stats-Reply message. More...
 
virtual void handle_port_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_port_stats_reply &msg)
 OpenFlow Port-Stats-Reply message received. More...
 
virtual void handle_port_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Port-Stats-Reply message. More...
 
virtual void handle_flow_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_flow_stats_reply &msg)
 OpenFlow Flow-Stats-Reply message received. More...
 
virtual void handle_flow_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Flow-Stats-Reply message. More...
 
virtual void handle_aggregate_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_aggr_stats_reply &msg)
 OpenFlow Aggregate-Stats-Reply message received. More...
 
virtual void handle_aggregate_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Aggregate-Stats-Reply message. More...
 
virtual void handle_queue_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_queue_stats_reply &msg)
 OpenFlow Queue-Stats-Reply message received. More...
 
virtual void handle_queue_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Queue-Stats-Reply message. More...
 
virtual void handle_group_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_group_stats_reply &msg)
 OpenFlow Group-Stats-Reply message received. More...
 
virtual void handle_group_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Group-Stats-Reply message. More...
 
virtual void handle_group_desc_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_group_desc_stats_reply &msg)
 OpenFlow Group-Desc-Stats-Reply message received. More...
 
virtual void handle_group_desc_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Group-Desc-Stats-Reply message. More...
 
virtual void handle_group_features_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_group_features_stats_reply &msg)
 OpenFlow Group-Features-Stats-Reply message received. More...
 
virtual void handle_group_features_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Group-Features-Stats-Reply message. More...
 
virtual void handle_meter_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_meter_stats_reply &msg)
 OpenFlow Meter-Stats-Reply message received. More...
 
virtual void handle_meter_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Meter-Stats-Reply message. More...
 
virtual void handle_meter_config_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_meter_config_stats_reply &msg)
 OpenFlow Meter-Config-Stats-Reply message received. More...
 
virtual void handle_meter_config_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Meter-Config-Stats-Reply message. More...
 
virtual void handle_meter_features_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_meter_features_stats_reply &msg)
 OpenFlow Meter-Features-Stats-Reply message received. More...
 
virtual void handle_meter_features_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Meter-Features-Stats-Reply message. More...
 
virtual void handle_table_features_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_table_features_stats_reply &msg)
 OpenFlow Table-Features-Stats-Reply message received. More...
 
virtual void handle_table_features_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Table-Features-Stats-Reply message. More...
 
virtual void handle_port_desc_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_port_desc_stats_reply &msg)
 OpenFlow Port-Desc-Stats-Reply message received. More...
 
virtual void handle_port_desc_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Port-Desc-Stats-Reply message. More...
 
virtual void handle_experimenter_stats_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_experimenter_stats_reply &msg)
 OpenFlow Experimenter-Stats-Reply message received. More...
 
virtual void handle_experimenter_stats_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Experimenter-Stats-Reply message. More...
 
virtual void handle_packet_in (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_packet_in &msg)
 OpenFlow Packet-In message received. More...
 
virtual void handle_barrier_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_barrier_reply &msg)
 OpenFlow Barrier-Reply message received. More...
 
virtual void handle_barrier_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Barrier-Reply message. More...
 
virtual void handle_flow_removed (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_flow_removed &msg)
 OpenFlow Flow-Removed message received. More...
 
virtual void handle_port_status (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_port_status &msg)
 OpenFlow Port-Status-Reply message received. More...
 
virtual void handle_queue_get_config_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_queue_get_config_reply &msg)
 OpenFlow Queue-Get-Config-Reply message received. More...
 
virtual void handle_queue_get_config_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Table-Stats-Reply message. More...
 
virtual void handle_error_message (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_error &msg)
 OpenFlow Error message received. More...
 
virtual void handle_experimenter_message (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_experimenter &msg)
 OpenFlow Experimenter message received. More...
 
virtual void handle_experimenter_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Experimenter message. More...
 
virtual void handle_role_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_role_reply &msg)
 OpenFlow Role-Reply message received. More...
 
virtual void handle_role_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Role-Reply message. More...
 
virtual void handle_get_async_config_reply (rofl::crofdpt &dpt, const rofl::cauxid &auxid, rofl::openflow::cofmsg_get_async_config_reply &msg)
 OpenFlow Get-Async-Config-Reply message received. More...
 
virtual void handle_get_async_config_reply_timeout (rofl::crofdpt &dpt, uint32_t xid)
 Timer expired while waiting for OpenFlow Get-Async-Config-Reply message. More...
 
Event handlers for OpenFlow message notifications received from controller entities

Overwrite any of these methods for receiving messages from the attached controller entity. Once this method terminates, rofl will destroy the message object. If you want to save a message or parts of it, you must create a local copy. All messages are internally allocated on the heap and both allocation and deallocation is handled by rofl-common. Do not delete any of these messages or its internals.

Higher logic implemented on top of crofbase and acting in datapath role should handle incoming requests, e.g., sending back a reply to the controller entity. rofl-common does not generate reply messages automatically. You may throw any of the OpenFlow related exceptions defined by rofl-common within these handler methods. rofl-common will detect such exceptions and generate appropriate error messages for transmission to the peer entity.

virtual void handle_features_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_features_request &msg)
 OpenFlow Features-Request message received. More...
 
virtual void handle_get_config_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_get_config_request &msg)
 OpenFlow Get-Config-Request message received. More...
 
virtual void handle_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_stats_request &msg)
 OpenFlow Stats-Request message received. More...
 
virtual void handle_desc_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_desc_stats_request &msg)
 OpenFlow Desc-Stats-Request message received. More...
 
virtual void handle_table_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_table_stats_request &msg)
 OpenFlow Table-Stats-Request message received. More...
 
virtual void handle_port_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_port_stats_request &msg)
 OpenFlow Port-Stats-Request message received. More...
 
virtual void handle_flow_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_flow_stats_request &msg)
 OpenFlow Flow-Stats-Request message received. More...
 
virtual void handle_aggregate_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_aggr_stats_request &msg)
 OpenFlow Aggregate-Stats-Request message received. More...
 
virtual void handle_queue_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_queue_stats_request &msg)
 OpenFlow Queue-Stats-Request message received. More...
 
virtual void handle_group_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_group_stats_request &msg)
 OpenFlow Group-Stats-Request message received. More...
 
virtual void handle_group_desc_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_group_desc_stats_request &msg)
 OpenFlow Group-Desc-Stats-Request message received. More...
 
virtual void handle_group_features_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_group_features_stats_request &msg)
 OpenFlow Group-Features-Stats-Request message received. More...
 
virtual void handle_meter_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_meter_stats_request &msg)
 OpenFlow Meter-Stats-Request message received. More...
 
virtual void handle_meter_config_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_meter_config_stats_request &msg)
 OpenFlow Meter-Config-Stats-Request message received. More...
 
virtual void handle_meter_features_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_meter_features_stats_request &msg)
 OpenFlow Meter-Features-Stats-Request message received. More...
 
virtual void handle_table_features_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_table_features_stats_request &msg)
 OpenFlow Table-Features-Stats-Request message received. More...
 
virtual void handle_port_desc_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_port_desc_stats_request &msg)
 OpenFlow Port-Desc-Stats-Request message received. More...
 
virtual void handle_experimenter_stats_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_experimenter_stats_request &msg)
 OpenFlow Experimenter-Stats-Request message received. More...
 
virtual void handle_packet_out (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_packet_out &msg)
 OpenFlow Packet-Out message received. More...
 
virtual void handle_barrier_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_barrier_request &msg)
 OpenFlow Barrier-Request message received. More...
 
virtual void handle_flow_mod (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_flow_mod &msg)
 OpenFlow Flow-Mod message received. More...
 
virtual void handle_group_mod (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_group_mod &msg)
 OpenFlow Group-Mod message received. More...
 
virtual void handle_table_mod (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_table_mod &msg)
 OpenFlow Table-Mod message received. More...
 
virtual void handle_port_mod (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_port_mod &msg)
 OpenFlow Port-Mod message received. More...
 
virtual void handle_queue_get_config_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_queue_get_config_request &msg)
 OpenFlow Queue-Get-Config-Request message received. More...
 
virtual void handle_set_config (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_set_config &msg)
 OpenFlow Set-Config message received. More...
 
virtual void handle_experimenter_message (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_experimenter &msg)
 OpenFlow Experimenter message received. More...
 
virtual void handle_error_message (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_error &msg)
 OpenFlow error message received. More...
 
virtual void handle_role_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_role_request &msg)
 OpenFlow Role-Request message received. More...
 
virtual void handle_get_async_config_request (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_get_async_config_request &msg)
 OpenFlow Get-Async-Config-Request message received. More...
 
virtual void handle_set_async_config (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_set_async_config &msg)
 OpenFlow Set-Async-Config message received. More...
 
virtual void handle_meter_mod (rofl::crofctl &ctl, const rofl::cauxid &auxid, rofl::openflow::cofmsg_meter_mod &msg)
 OpenFlow Meter-Mod message received. More...
 
Methods for sending asynchronous messages towards a controller entity.

This group of methods allows an entity acting in datapath role to send asynchronous OpenFlow messages towards a group of controller entities based on their roles as defined in OpenFlow. This includes message transmission based on individual controller modes like master, slave and equal and the asynchronous configuration defining the set of messages sent towards each controller. rofl-common maintains these roles automatically within rofl::crofctl instances based on OpenFlow Role-Request message received from the control plane.

void send_packet_in_message (const rofl::cauxid &auxid, uint32_t buffer_id, uint16_t total_len, uint8_t reason, uint8_t table_id, uint64_t cookie, uint16_t in_port, rofl::openflow::cofmatch &match, uint8_t *data, size_t datalen)
 Sends OpenFlow Packet-In message to controller entity. More...
 
void send_flow_removed_message (const rofl::cauxid &auxid, rofl::openflow::cofmatch &match, uint64_t cookie, uint16_t priority, uint8_t reason, uint8_t table_id, uint32_t duration_sec, uint32_t duration_nsec, uint16_t idle_timeout, uint16_t hard_timeout, uint64_t packet_count, uint64_t byte_count)
 Sends OpenFlow Flow-Removed message to controller entity. More...
 
void send_port_status_message (const rofl::cauxid &auxid, uint8_t reason, const rofl::openflow::cofport &port)
 Sends OpenFlow Port-Status message to controller entity. More...
 
- Protected Member Functions inherited from rofl::ciosrv
ctimer get_next_timer ()
 
virtual void handle_event (const rofl::cevent &event)
 Handler for event notifications using cevent instances. More...
 
virtual void handle_revent (int fd)
 Handler for read events on file descriptors. More...
 
virtual void handle_wevent (int fd)
 Handler for write events on file descriptors. More...
 
virtual void handle_xevent (int fd)
 Handler for exceptions on file descriptors. More...
 
void register_filedesc_r (int fd)
 Registers a file descriptor for read events. More...
 
void deregister_filedesc_r (int fd)
 Deregisters a file descriptor from read events. More...
 
void register_filedesc_w (int fd)
 Registers a file descriptor for write events. More...
 
void deregister_filedesc_w (int fd)
 Deregisters a file descriptor from write events. More...
 
const rofl::ctimeridregister_timer (int opaque, const rofl::ctimespec &timespec)
 Installs a new timer to fire in t seconds. More...
 
const rofl::ctimeridreset_timer (const rofl::ctimerid &timer_id, const rofl::ctimespec &timespec)
 Resets a running timer of type opaque. More...
 
ctimeridrestart_timer (rofl::ctimerid &timer_id, int opaque, const rofl::ctimespec &timespec)
 Resets an existing or creates a new timer. More...
 
bool pending_timer (const rofl::ctimerid &timer_id)
 Checks for a pending timer of type opaque. More...
 
void cancel_timer (const rofl::ctimerid &timer_id)
 Cancels a pending timer. More...
 
void cancel_all_timers ()
 Cancels all pending timers of this instance.
 
void cancel_all_events ()
 Cancels all pending events of this instance.
 
Event handlers for management notifications for controller entities

Overwrite any of these methods for receiving controller related event notifications.

Event handlers for OpenFlow message notifications received from controller entities

Overwrite any of these methods for receiving messages from the attached controller entity. Once this method terminates, rofl will destroy the message object. If you want to save a message or parts of it, you must create a local copy. All messages are internally allocated on the heap and both allocation and deallocation is handled by rofl-common. Do not delete any of these messages or its internals.

Higher logic implemented on top of crofbase and acting in datapath role should handle incoming requests, e.g., sending back a reply to the controller entity. rofl-common does not generate reply messages automatically. You may throw any of the OpenFlow related exceptions defined by rofl-common within these handler methods. rofl-common will detect such exceptions and generate appropriate error messages for transmission to the peer entity.

Event handlers for receiving datapath related event notifications.
Event handlers for OpenFlow message notifications received from datapath elements

Overwrite any of these methods for receiving messages from the attached datapath element. Once this method terminates, rofl will destroy the message object. If you want to save a message or parts of it, you must create a local copy. All messages are internally allocated on the heap and both allocation and deallocation is handled by rofl-common. Do not delete any of these messages or its internals.

Friends

std::ostream & operator<< (std::ostream &os, crofbase const &rofbase)
 

Auxiliary methods

rofl::openflow::cofhello_elem_versionbitmapset_versionbitmap ()
 Returns reference to OpenFlow version bitmap used for incoming connections.
 
const
rofl::openflow::cofhello_elem_versionbitmap
get_versionbitmap () const
 Returns const reference to OpenFlow version bitmap used for incoming connections.
 
uint8_t get_highest_supported_ofp_version () const
 Returns highest OpenFlow version supported for incoming connections.
 
bool is_ofp_version_supported (uint8_t ofp_version) const
 Returns true, when the given OpenFlow version is supported by this crofbase instance.
 
static uint32_t get_ofp_no_buffer (uint8_t ofp_version)
 Returns OpenFlow's NO_BUFFER constant for various OpenFlow versions.
 
static uint32_t get_ofp_controller_port (uint8_t ofp_version)
 Returns OpenFlow's OFPP_CONTROLLER constant for various OpenFlow versions.
 
static uint32_t get_ofp_flood_port (uint8_t ofp_version)
 Returns OpenFlow's OFPP_FLOOD constant for various OpenFlow versions.
 
static uint8_t get_ofp_command (uint8_t ofp_version, const enum openflow::ofp_flow_mod_command &cmd)
 Returns OpenFlow's OFPFC constants for various OpenFlow versions.
 

Additional Inherited Members

- Static Public Member Functions inherited from rofl::crofconn_env
static crofconn_envset_env (crofconn_env *env)
 
static bool has_env (crofconn_env *env)
 

Detailed Description

Base class for revised OpenFlow library.

Derive from this class in order to use ROFL's functionality. crofbase supports communication to peer entities acting in either controller or datapath role using the OpenFlow protocol in various versions. Each peer entity is represented by an instance of class crofdpt (handle for a remote datapath) or an instance of class crofctl (handle for a remote controller). These classes provide a rich API for managing the OpenFlow control channel, e.g., establishing of main and auxiliary control connections. Furthermore, they include a protocol parser mapping OpenFlow messages from their wire (TCP) representation into a correspondent C++ representation. crofbase provides three groups of functionality:

  1. Management of an arbitrary number of listening sockets for accepting incoming OpenFlow connections either in controller or datapath role.
  2. Management of an arbitrary number of peer controller entities each encapsulated in a separate instance of class crofctl.
  3. Management of an arbitrary number of peer datapath entities each encapsulated in a separate instance of class crofdpt.

Furthermore, crofbase manages all active transactions when acting in controller role. crofctl and crofdpt instances support an arbitrary number of auxiliary connections as defined by OpenFlow 1.3. See class descriptions for crofctl and crofdpt for details.

crofbase acts as environment surrounding instances of crofctl and crofdpt and receives information notifications and messages generated during operation. A deriving class may overwrite any of the handler methods defined within crofbase to receive a specific event. Overwriting handler methods is optional and crofbase defines a reasonable default handler for each event.

See Also
crofctl
crofdpt
Inheritance diagram for rofl::crofbase:
rofl::ciosrv rofl::csocket_env rofl::crofconn_env rofl::ctransactions_env rofl::crofctl_env rofl::crofdpt_env rofl::ctimer_env rofl::examples::ethswctld::cetherswitch

Constructor & Destructor Documentation

crofbase constructor

Constructor takes a single argument defining the OpenFlow versions allowed for passively created OpenFlow sockets. You may specify multiple OpenFlow versions as needed.

Parameters
versionbitmapOpenFlow version bitmap
crofbase::~crofbase ( )
virtual

crofbase destructor

Destructor shuts down all active connections and listening sockets and deallocates all instance of classes crofctl and crofdpt.

Member Function Documentation

rofl::crofctl& rofl::crofbase::add_ctl ( const rofl::cctlid ctlid,
const rofl::openflow::cofhello_elem_versionbitmap versionbitmap,
bool  remove_on_channel_close = false 
)
inline

Creates new rofl::crofctl instance for given identifier.

Creates a new rofl::crofctl instance identified by the identifier specified in rofl::cctlid parameter. If an instance with this identifier already exists, it is destroyed first (this includes termination of all OpenFlow connections established in its associated OpenFlow control channel) before a new, empty instance is created. You must add OpenFlow connections to actually bind the rofl::crofctl instance to a controller peer entity.

Parameters
ctlidinternal controller handle
versionbitmapversion bitmap defining all acceptable OpenFlow versions
remove_on_channel_closewhen true, automatically remove this rofl::crofctl instance, when all OpenFlow control channel connections have been terminated
Returns
reference to new rofl::crofctl instance
rofl::csocket& rofl::crofbase::add_ctl_listening ( unsigned int  sockid,
enum rofl::csocket::socket_type_t  socket_type,
const rofl::cparams params 
)
inline

Creates a new listening rofl::csocket instance for accepting incoming OpenFlow connections.

Parameters
sockidsocket identifier
socket_typeone of the constants defined in csocket.h, e.g. SOCKET_TYPE_PLAIN
paramsset of parameters used for creating a listening socket
rofl::crofdpt& rofl::crofbase::add_dpt ( const rofl::cdptid dptid,
const rofl::openflow::cofhello_elem_versionbitmap versionbitmap,
bool  remove_on_channel_close = false,
const rofl::cdpid dpid = rofl::cdpid(0) 
)
inline

Creates new rofl::crofdpt instance for given identifier.

Creates a new rofl::crofdpt instance identified by the identifier specified in rofl::cdptid parameter. If an instance with this identifier already exists, it is destroyed first (this includes termination of all OpenFlow connections established in its associated OpenFlow control channel) before a new, empty instance is created. You must add OpenFlow connections to actually bind the rofl::crofdpt instance to a datapath peer entity.

Parameters
dptidinternal datapath handle (not DPID)
versionbitmapversion bitmap defining all acceptable OpenFlow versions
remove_on_channel_closewhen true, automatically remove this rofl::crofdpt instance, when all OpenFlow control channel connections have been terminated
dpidOpenFlow datapath identifier (optional)
Returns
reference to new rofl::crofdpt instance
rofl::csocket& rofl::crofbase::add_dpt_listening ( unsigned int  sockid,
enum rofl::csocket::socket_type_t  socket_type,
const rofl::cparams params 
)
inline

Creates a new listening rofl::csocket instance for accepting incoming OpenFlow connections.

Parameters
sockidsocket identifier
socket_typeone of the constants defined in csocket.h, e.g. SOCKET_TYPE_PLAIN
paramsset of parameters used for creating a listening socket
void rofl::crofbase::drop_ctl ( rofl::cctlid  ctlid)
inline

Deletes a rofl::crofctl instance given by identifier.

If the identifier is non-existing, the method does nothing and returns.

void rofl::crofbase::drop_ctl_listening ( unsigned int  sockid)
inline

Removes a listening socket identified by sockid.

Parameters
sockidsocket identifier
void rofl::crofbase::drop_dpt ( rofl::cdptid  dptid)
inline

Deletes a rofl::crofdpt instance given by identifier.

If the identifier is non-existing, the method does nothing and returns.

void rofl::crofbase::drop_dpt_listening ( unsigned int  sockid)
inline

Removes a listening socket identified by sockid.

Parameters
sockidsocket identifier
const rofl::crofctl& rofl::crofbase::get_ctl ( const rofl::cctlid ctlid) const
inline

Returns const reference to existing rofl::crofctl instance.

Returns existing rofl::crofctl instance specified by identifier ctlid. If the identifier does not exist, throws an exception eRofBaseNotFound.

Parameters
ctlidinternal controller handle
Returns
reference to existing rofl::crofctl instance
Exceptions
eRofBaseNotFound
const rofl::csocket& rofl::crofbase::get_ctl_listening ( unsigned int  sockid) const
inline

Returns a const reference to the listening csocket object specified by identifier sockid.

Parameters
sockidsocket identifier
const rofl::crofdpt& rofl::crofbase::get_dpt ( const rofl::cdptid dptid) const
inline

Returns const reference to existing rofl::crofdpt instance.

Returns existing rofl::crofdpt instance specified by identifier dptid. If the identifier does not exist, throws an exception eRofBaseNotFound.

Parameters
dptidinternal datapath handle (not DPID)
Returns
reference to existing rofl::crofdpt instance
Exceptions
eRofBaseNotFound
const rofl::csocket& rofl::crofbase::get_dpt_listening ( unsigned int  sockid) const
inline

Returns a const reference to the listening csocket object specified by identifier sockid.

Parameters
sockidsocket identifier
rofl::cctlid rofl::crofbase::get_idle_ctlid ( ) const
inline

Returns the next idle identifier for a new rofl::crofctl instance.

See Also
rofl::crofctl
rofl::cctlid
Returns
Next idle identifier for a rofl::crofctl instance
rofl::cdptid rofl::crofbase::get_idle_dptid ( ) const
inline

Returns the next idle identifier for a new rofl::crofdpt instance.

See Also
rofl::crofdpt
rofl::cdptid
Returns
Next idle identifier for a rofl::crofdpt instance
virtual void rofl::crofbase::handle_aggregate_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_aggr_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Aggregate-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_aggregate_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Aggregate-Stats-Reply message.

No Aggregate-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_aggregate_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_aggr_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Aggregate-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_barrier_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_barrier_reply msg 
)
inlineprotectedvirtual

OpenFlow Barrier-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_barrier_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Barrier-Reply message.

No Barrier-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_barrier_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_barrier_request msg 
)
inlineprotectedvirtual

OpenFlow Barrier-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_conn_established ( rofl::crofdpt dpt,
const rofl::cauxid auxid 
)
inlineprotectedvirtual

Called when a control connection (main or auxiliary) has been established.

Parameters
dptdatapath instance
auxidconnection identifier (main: 0)

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_conn_established ( rofl::crofctl ctl,
const rofl::cauxid auxid 
)
inlineprotectedvirtual

Called when a control connection (main or auxiliary) has been established.

Parameters
ctlcontroller instance
auxidconnection identifier (main: 0)

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_conn_failed ( rofl::crofdpt dpt,
const rofl::cauxid auxid 
)
inlineprotectedvirtual

Called when an attempt to establish a control connection has been failed.

This event occurs when some failure occures while calling the underlying C-library connect() system call, e.g., no route to destination, etc. This may indicate a local configuration problem inside or outside of the application.

Parameters
dptdatapath instance
auxidconnection identifier (main: 0)

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_conn_failed ( rofl::crofctl ctl,
const rofl::cauxid auxid 
)
inlineprotectedvirtual

Called when an attempt to establish a control connection has been failed.

This event occurs when some failure occures while calling the underlying C-library connect() system call, e.g., no route to destination, etc. This may indicate a local configuration problem inside or outside of the application.

Parameters
ctlcontroller instance
auxidconnection identifier (main: 0)

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_conn_refused ( rofl::crofdpt dpt,
const rofl::cauxid auxid 
)
inlineprotectedvirtual

Called when an attempt to establish a control connection has been refused.

This event occurs when the C-library's connect() system call fails with the ECONNREFUSED error code. This indicates typically a problem on the remote site.

Parameters
dptdatapath instance
auxidconnection identifier (main: 0)

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_conn_refused ( rofl::crofctl ctl,
const rofl::cauxid auxid 
)
inlineprotectedvirtual

Called when an attempt to establish a control connection has been refused.

This event occurs when the C-library's connect() system call fails with the ECONNREFUSED error code. This indicates typically a problem on the remote site.

Parameters
ctlcontroller instance
auxidconnection identifier (main: 0)

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_conn_terminated ( rofl::crofdpt dpt,
const rofl::cauxid auxid 
)
inlineprotectedvirtual

Called when a control connection (main or auxiliary) has been terminated by the peer entity.

Parameters
dptdatapath instance
auxidconnection identifier (main: 0)

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_conn_terminated ( rofl::crofctl ctl,
const rofl::cauxid auxid 
)
inlineprotectedvirtual

Called when a control connection (main or auxiliary) has been terminated by the peer entity.

Parameters
ctlcontroller instance
auxidconnection identifier (main: 0)

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_conn_writable ( rofl::crofdpt dpt,
const rofl::cauxid auxid 
)
inlineprotectedvirtual

Called when a congestion situation on the control connection has been solved.

A control channel may face congestion situations when insufficient bandwidth on the underlying IP path or some backpressuring by the remote site requires to throttle the overall message transmission rate on a control connection. A congestion situation is indicated by the return values obtained from the various send-methods defined within rofl::crofdpt. A solved congestion situation is indicated by calling this method. Note that ROFL will store OpenFlow messages even under congestion, thus filling up its internal buffers until no further memory is available for doing so. It is up to the application designer to throttle transmission of further messages according to the channel capacity.

Parameters
dptdatapath instance
auxidcontrol connection identifier (main: 0)

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_conn_writable ( rofl::crofctl ctl,
const rofl::cauxid auxid 
)
inlineprotectedvirtual

Called when a congestion situation on the control connection has been solved.

A control channel may face congestion situations when insufficient bandwidth on the underlying IP path or some backpressuring by the remote site requires to throttle the overall message transmission rate on a control connection. A congestion situation is indicated by the return values obtained from the various send-methods defined within rofl::crofctl. A solved congestion situation is indicated by calling this method. Note that ROFL will store OpenFlow messages even under congestion, thus filling up its internal buffers until no further memory is available for doing so. It is up to the application designer to throttle transmission of further messages according to the channel capacity.

Parameters
ctlcontroller instance
auxidcontrol connection identifier (main: 0)

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_ctl_close ( rofl::crofctl ctl)
inlineprotectedvirtual

Called after termination of associated OpenFlow control channel.

This method is called once the associated OpenFlow control channel has been terminated, i.e., its main connection has been closed from the remote site. The rofl::crofctl instance itself is not destroyed, unless its 'remove_on_channel_close' flag has been set to true during its construction.

Parameters
ctlcontroller instance
virtual void rofl::crofbase::handle_ctl_open ( rofl::crofctl ctl)
inlineprotectedvirtual

Called after establishing the associated OpenFlow control channel.

This method is called once the associated OpenFlow control channel has been established, i.e., its main connection has been accepted by the remote site.

Parameters
ctlcontroller instance
virtual void rofl::crofbase::handle_desc_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_desc_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Desc-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_desc_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Desc-Stats-Reply message.

No Desc-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_desc_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_desc_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Desc-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_dpt_close ( rofl::crofdpt dpt)
inlineprotectedvirtual

Called after termination of associated OpenFlow control channel.

This method is called once the associated OpenFlow control channel has been terminated, i.e., its main connection has been closed from the remote site. The rofl::crofdpt instance itself is not destroyed, unless its 'remove_on_channel_close' flag has been set to true during its construction.

Parameters
dptdatapath instance
virtual void rofl::crofbase::handle_dpt_open ( rofl::crofdpt dpt)
inlineprotectedvirtual

Called after establishing the associated OpenFlow control channel.

This method is called once the associated OpenFlow control channel has been established, i.e., its main connection has been accepted by the remote site.

Parameters
dptdatapath instance
virtual void rofl::crofbase::handle_error_message ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_error msg 
)
inlineprotectedvirtual

OpenFlow Error message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_error_message ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_error msg 
)
inlineprotectedvirtual

OpenFlow error message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_experimenter_message ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_experimenter msg 
)
inlineprotectedvirtual

OpenFlow Experimenter message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_experimenter_message ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_experimenter msg 
)
inlineprotectedvirtual

OpenFlow Experimenter message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_experimenter_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_experimenter_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Experimenter-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_experimenter_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Experimenter-Stats-Reply message.

No Experimenter-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_experimenter_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_experimenter_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Experimenter-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_experimenter_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Experimenter message.

No Experimenter message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_features_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_features_reply msg 
)
inlineprotectedvirtual

OpenFlow Features-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_features_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Features-Reply message.

No Features-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_features_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_features_request msg 
)
inlineprotectedvirtual

OpenFlow Features-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_flow_mod ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_flow_mod msg 
)
inlineprotectedvirtual

OpenFlow Flow-Mod message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_flow_removed ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_flow_removed msg 
)
inlineprotectedvirtual

OpenFlow Flow-Removed message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_flow_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_flow_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Flow-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_flow_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Flow-Stats-Reply message.

No Flow-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_flow_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_flow_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Flow-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_get_async_config_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_get_async_config_reply msg 
)
inlineprotectedvirtual

OpenFlow Get-Async-Config-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_get_async_config_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Get-Async-Config-Reply message.

No Get-Async-Config-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_get_async_config_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_get_async_config_request msg 
)
inlineprotectedvirtual

OpenFlow Get-Async-Config-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_get_config_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_get_config_reply msg 
)
inlineprotectedvirtual

OpenFlow Get-Config-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_get_config_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Get-Config-Reply message.

No Get-Config-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_get_config_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_get_config_request msg 
)
inlineprotectedvirtual

OpenFlow Get-Config-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_group_desc_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_group_desc_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Group-Desc-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_group_desc_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Group-Desc-Stats-Reply message.

No Group-Desc-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_group_desc_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_group_desc_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Group-Desc-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_group_features_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_group_features_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Group-Features-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_group_features_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Group-Features-Stats-Reply message.

No Group-Features-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_group_features_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_group_features_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Group-Features-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_group_mod ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_group_mod msg 
)
inlineprotectedvirtual

OpenFlow Group-Mod message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_group_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_group_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Group-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_group_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Group-Stats-Reply message.

No Group-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_group_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_group_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Group-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_meter_config_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_meter_config_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Meter-Config-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_meter_config_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Meter-Config-Stats-Reply message.

No Meter-Config-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_meter_config_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_meter_config_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Meter-Config-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_meter_features_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_meter_features_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Meter-Features-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_meter_features_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Meter-Features-Stats-Reply message.

No Meter-Features-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_meter_features_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_meter_features_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Meter-Features-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_meter_mod ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_meter_mod msg 
)
inlineprotectedvirtual

OpenFlow Meter-Mod message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_meter_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_meter_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Meter-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_meter_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Meter-Stats-Reply message.

No Meter-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_meter_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_meter_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Meter-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_packet_in ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_packet_in msg 
)
inlineprotectedvirtual

OpenFlow Packet-In message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_packet_out ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_packet_out msg 
)
inlineprotectedvirtual

OpenFlow Packet-Out message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_port_desc_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_port_desc_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Port-Desc-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_port_desc_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Port-Desc-Stats-Reply message.

No Port-Desc-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_port_desc_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_port_desc_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Port-Desc-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_port_mod ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_port_mod msg 
)
inlineprotectedvirtual

OpenFlow Port-Mod message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_port_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_port_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Port-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_port_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Port-Stats-Reply message.

No Port-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_port_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_port_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Port-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_port_status ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_port_status msg 
)
inlineprotectedvirtual

OpenFlow Port-Status-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_queue_get_config_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_queue_get_config_reply msg 
)
inlineprotectedvirtual

OpenFlow Queue-Get-Config-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_queue_get_config_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Table-Stats-Reply message.

No Table-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_queue_get_config_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_queue_get_config_request msg 
)
inlineprotectedvirtual

OpenFlow Queue-Get-Config-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_queue_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_queue_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Queue-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_queue_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Queue-Stats-Reply message.

No Queue-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_queue_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_queue_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Queue-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_role_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_role_reply msg 
)
inlineprotectedvirtual

OpenFlow Role-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_role_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Role-Reply message.

No Role-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_role_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_role_request msg 
)
inlineprotectedvirtual

OpenFlow Role-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_set_async_config ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_set_async_config msg 
)
inlineprotectedvirtual

OpenFlow Set-Async-Config message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_set_config ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_set_config msg 
)
inlineprotectedvirtual

OpenFlow Set-Config message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid,
uint8_t  stats_type 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Stats-Reply message.

No Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier
stats_typestatistics message subtype

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_table_features_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_table_features_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Table-Features-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_table_features_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Table-Features-Stats-Reply message.

No Table-Features-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_table_features_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_table_features_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Table-Features-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_table_mod ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_table_mod msg 
)
inlineprotectedvirtual

OpenFlow Table-Mod message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

virtual void rofl::crofbase::handle_table_stats_reply ( rofl::crofdpt dpt,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_table_stats_reply msg 
)
inlineprotectedvirtual

OpenFlow Table-Stats-Reply message received.

Parameters
dptdatapath instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_table_stats_reply_timeout ( rofl::crofdpt dpt,
uint32_t  xid 
)
inlineprotectedvirtual

Timer expired while waiting for OpenFlow Table-Stats-Reply message.

No Table-Stats-Reply message was received in the specified time interval for the given OpenFlow transaction identifier.

Parameters
dptdatapath instance
xidOpenFlow transaction identifier

Implements rofl::crofdpt_env.

virtual void rofl::crofbase::handle_table_stats_request ( rofl::crofctl ctl,
const rofl::cauxid auxid,
rofl::openflow::cofmsg_table_stats_request msg 
)
inlineprotectedvirtual

OpenFlow Table-Stats-Request message received.

Parameters
ctlcontroller instance
auxidcontrol connection identifier
msgOpenFlow message instance

Implements rofl::crofctl_env.

bool rofl::crofbase::has_ctl ( const rofl::cctlid ctlid) const
inline

Checks for existence of rofl::crofctl instance with given identifier.

Parameters
ctlidinternal controller handle
Returns
bool value
bool rofl::crofbase::has_ctl_listening ( unsigned int  sockid)
inline

Checks for existence of a listening socket identified by sockid.

Parameters
sockidsocket identifier
bool rofl::crofbase::has_dpt ( const rofl::cdptid dptid) const
inline

Checks for existence of rofl::crofdpt instance with given identifier.

Parameters
dptidinternal datapath handle (not DPID)
Returns
bool value
bool rofl::crofbase::has_dpt_listening ( unsigned int  sockid)
inline

Checks for existence of a listening socket identified by sockid.

Parameters
sockidsocket identifier
void crofbase::send_flow_removed_message ( const rofl::cauxid auxid,
rofl::openflow::cofmatch match,
uint64_t  cookie,
uint16_t  priority,
uint8_t  reason,
uint8_t  table_id,
uint32_t  duration_sec,
uint32_t  duration_nsec,
uint16_t  idle_timeout,
uint16_t  hard_timeout,
uint64_t  packet_count,
uint64_t  byte_count 
)
protected

Sends OpenFlow Flow-Removed message to controller entity.

Parameters
auxidcontroller connection identifier
matchset of OpenFlow matches generated by the datapath element's packet parser
cookiecookie of flow-table entry emitting the flow-removed event
prioritypriority of flow-table entry emitting the flow-removed event
reasonone of OpenFlow's OFPRR constants specifying the reason for sending a flow-removed
table_ididentifier of OpenFlow table emitting the flow-removed event
duration_secoverall lifetime of this flow-table entry (seconds)
duration_nsecoverall lifetime of this flow-table entry (nseconds)
idle_timeoutidle_timeout of flow-table entry emitting the flow-removed event
hard_timeouthard_timeout of flow-table entry emitting the flow-removed event
packet_countnumber of packets that traversed this flow-table entry emitting the flow-removed event
byte_countnumber of bytes that traversed this flow-table entry emitting the flow-removed event
void crofbase::send_packet_in_message ( const rofl::cauxid auxid,
uint32_t  buffer_id,
uint16_t  total_len,
uint8_t  reason,
uint8_t  table_id,
uint64_t  cookie,
uint16_t  in_port,
rofl::openflow::cofmatch match,
uint8_t *  data,
size_t  datalen 
)
protected

Sends OpenFlow Packet-In message to controller entity.

Parameters
auxidcontroller connection identifier
buffer_idOpenFlow buffer identifier where this packet is stored in
total_lentotal length of buffer stored on datapath element
reasonone of OpenFlow's OFPR constants specifying the reason for sending a packet-in
table_ididentifier of OpenFlow table emitting the packet-in event
cookiecookie of flow-table entry emitting the packet-in event
in_portport where packet causing this packet-in event was received (OpenFlow 1.0 only)
matchset of OpenFlow matches generated by the datapath element's packet parser
datapointer to start of data buffer containing the packet
datalenlength of data buffer containing the packet
Exceptions
eRofBaseNotConnected
void crofbase::send_port_status_message ( const rofl::cauxid auxid,
uint8_t  reason,
const rofl::openflow::cofport port 
)
protected

Sends OpenFlow Port-Status message to controller entity.

Parameters
auxidcontroller connection identifier
reasonone of OpenFlow's OFPPR constants specifying the reason for sending a port-status
portcofport instance definine the port's properties
rofl::crofctl& rofl::crofbase::set_ctl ( const rofl::cctlid ctlid,
const rofl::openflow::cofhello_elem_versionbitmap versionbitmap,
bool  remove_on_channel_close = false 
)
inline

Returns existing or creates new rofl::crofctl instance for given identifier.

Returns rofl::crofctl instance specified by identifier ctlid. If none exists, a new empty instance is created. You must add OpenFlow connections to actually bind the rofl::crofctl instance to a controller peer entity.

Parameters
ctlidinternal controller handle
versionbitmapversion bitmap defining all acceptable OpenFlow versions
remove_on_channel_closewhen true, automatically remove this rofl::crofctl instance, when all OpenFlow control channel connections have been terminated
Returns
reference to existing or new rofl::crofctl instance
rofl::crofctl& rofl::crofbase::set_ctl ( const rofl::cctlid ctlid)
inline

Returns reference to existing rofl::crofctl instance.

Returns existing rofl::crofctl instance specified by identifier ctlid. If the identifier does not exist, throws an exception eRofBaseNotFound.

Parameters
ctlidinternal controller handle
Returns
reference to existing rofl::crofctl instance
Exceptions
eRofBaseNotFound
rofl::csocket& rofl::crofbase::set_ctl_listening ( unsigned int  sockid,
enum rofl::csocket::socket_type_t  socket_type,
const rofl::cparams params 
)
inline

Returns a reference to the listening csocket object specified by identifier sockid.

Parameters
sockidsocket identifier
socket_typeone of the constants defined in csocket.h, e.g. SOCKET_TYPE_PLAIN
paramsset of parameters used for creating a listening socket
rofl::crofdpt& rofl::crofbase::set_dpt ( const rofl::cdptid dptid,
const rofl::openflow::cofhello_elem_versionbitmap versionbitmap,
bool  remove_on_channel_close = false,
const rofl::cdpid dpid = rofl::cdpid(0) 
)
inline

Returns existing or creates new rofl::crofdpt instance for given identifier.

Returns rofl::crofdpt instance specified by identifier dptid. If none exists, a new empty instance is created. You must add OpenFlow connections to actually bind the rofl::crofdpt instance to a datapath peer entity.

Parameters
dptidinternal datapath handle (not DPID)
versionbitmapversion bitmap defining all acceptable OpenFlow versions
remove_on_channel_closewhen true, automatically remove this rofl::crofdpt instance, when all OpenFlow control channel connections have been terminated
dpidOpenFlow datapath identifier (optional)
Returns
reference to existing or new rofl::crofdpt instance
rofl::crofdpt& rofl::crofbase::set_dpt ( const rofl::cdptid dptid)
inline

Returns reference to existing rofl::crofdpt instance.

Returns existing rofl::crofdpt instance specified by identifier dptid. If the identifier does not exist, throws an exception eRofBaseNotFound.

Parameters
dptidinternal datapath handle (not DPID)
Returns
reference to existing rofl::crofdpt instance
Exceptions
eRofBaseNotFound
rofl::csocket& rofl::crofbase::set_dpt_listening ( unsigned int  sockid,
enum rofl::csocket::socket_type_t  socket_type,
const rofl::cparams params 
)
inline

Returns a reference to the listening csocket object specified by identifier sockid.

Parameters
sockidsocket identifier
socket_typeone of the constants defined in csocket.h, e.g. SOCKET_TYPE_PLAIN
paramsset of parameters used for creating a listening socket

The documentation for this class was generated from the following files: