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

Class representing a remote datapath element. More...

#include <crofdpt.h>

Classes

class  crofdpt_find_by_dpid
 Predicate for finding a rofl::crofdpt instance by its rofl::cdpid. More...
 
class  crofdpt_find_by_dptid
 Predicate for finding a rofl::crofdpt instance by its rofl::cdptid. More...
 

Public Member Functions

 crofdpt (rofl::crofdpt_env *env, const rofl::cdptid &dptid, bool remove_on_channel_close, const rofl::openflow::cofhello_elem_versionbitmap &versionbitmap, const rofl::cdpid &dpid=rofl::cdpid(0))
 crofdpt constructor More...
 
virtual ~crofdpt ()
 crofdpt destructor More...
 
const rofl::cdptidget_dptid () const
 Returns rofl-common's internal rofl::cdptid identifier for this instance. More...
 
std::string str () const
 Returns a one-liner string with basic information about this instance.
 
Methods for connection management

This is a group of methods for typical CRUD like operations on control connections for the OpenFlow control channel. You may create an arbitrary number of control connections to a datapath element in addition to those created by the datapath element (as long as there is a listening socket implemented on the datapath side). Control connections may be closed or reconnected.

std::list< rofl::cauxidget_conn_index () const
 Returns a list of connection identifiers of all existing control connections. More...
 
void connect (const rofl::cauxid &auxid, enum rofl::csocket::socket_type_t socket_type, const rofl::cparams &socket_params)
 Establishes a new control connection to a remote datapath element with the given control connection identifier. More...
 
void disconnect (rofl::cauxid auxid)
 Terminates an existing control connection with given identifier. More...
 
void add_connection (crofconn *conn)
 Add an existing rofl::crofconn instance created on heap to this object. More...
 
Methods related to control channel state
bool is_established () const
 Returns true, when the control handshake (HELLO) has been completed.
 
uint8_t get_version_negotiated () const
 Returns the OpenFlow protocol version used for this control connection. More...
 
const
rofl::openflow::cofhello_elem_versionbitmap
get_versions_available () const
 Returns the defined OpenFlow version bitmap for this instance. More...
 
bool remove_on_channel_termination () const
 Returns true, when this instance should be destroyed when its crofchan has closed.
 
rofl::caddress get_peer_addr (const rofl::cauxid &auxid) const
 Returns caddress of connected remote entity for given connection identifier. More...
 
Methods granting access to the datapath element's basic properties
const rofl::cdpidget_dpid () const
 Returns OpenFlow datapath identifier for this instance. More...
 
const rofl::caddress_llget_hwaddr () const
 Returns the datapath element's hardware address. More...
 
uint32_t get_n_buffers () const
 Returns the datapath element's number of buffers for storing data packets. More...
 
uint8_t get_n_tables () const
 Returns the datapath element's number of tables in the OpenFlow pipeline. More...
 
uint32_t get_capabilities () const
 Returns the datapath element's capabilities. More...
 
uint16_t get_config () const
 Returns the datapath element's configuration. More...
 
uint16_t get_miss_send_len () const
 Returns the datapath element's current miss_send_len parameter. More...
 
const rofl::openflow::cofportsget_ports () const
 Returns const reference to the datapath element's port list. More...
 
const rofl::openflow::coftablesget_tables () const
 Returns const reference to the datapath element's tables list. More...
 
Methods for group table entry identifier management

This group of methods provides simple functionality for assigning group table entry identifiers for various higher logic entities, e.g., for creating new group table entries. This is a simple storage for uint32_t values and does no pre-checks, whether a group table identifier is already in use or can be actually used at all on the datapath element.

uint32_t get_next_idle_group_id ()
 Returns the next idle group table identifier. More...
 
void release_group_id (uint32_t group_id)
 Releases a previously allocated group table identifier. More...
 
void clear_group_ids ()
 Resets the pool of all previously allocated group table identifiers.
 
Methods for purging and resetting a datapath element
void flow_mod_reset ()
 Removes all flow-table entries from the attached datapath element. More...
 
void group_mod_reset ()
 Removes all group-table entries from the attached datapath element. More...
 
void drop_buffer (const rofl::cauxid &auxid, uint32_t buffer_id, uint32_t inport=rofl::openflow::OFPP_CONTROLLER)
 Drops packet identified by buffer-id from the attached datapath element. More...
 
Methods for sending OpenFlow messages

These methods may be called by a derived class for sending a specific OpenFlow message.

uint32_t send_features_request (const rofl::cauxid &auxid, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Features-Request message to attached datapath element. More...
 
uint32_t send_get_config_request (const rofl::cauxid &auxid, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Get-Config-Request message to attached datapath element. More...
 
uint32_t send_table_features_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Table-Features-Stats-Request message to attached datapath element. More...
 
uint32_t send_stats_request (const rofl::cauxid &auxid, uint16_t stats_type, uint16_t stats_flags, uint8_t *body=NULL, size_t bodylen=0, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Stats-Request message to attached datapath element. More...
 
uint32_t send_desc_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Desc-Stats-Request message to attached datapath element. More...
 
uint32_t send_flow_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::openflow::cofflow_stats_request &flow_stats_request, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Flow-Stats-Request message to attached datapath element. More...
 
uint32_t send_aggr_stats_request (const rofl::cauxid &auxid, uint16_t flags, const rofl::openflow::cofaggr_stats_request &aggr_stats_request, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Aggregate-Stats-Request message to attached datapath element. More...
 
uint32_t send_table_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags=0, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Table-Stats-Request message to attached datapath element. More...
 
uint32_t send_port_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::openflow::cofport_stats_request &port_stats_request, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Port-Stats-Request message to attached datapath element. More...
 
uint32_t send_queue_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::openflow::cofqueue_stats_request &queue_stats_request, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Queue-Stats-Request message to attached datapath element. More...
 
uint32_t send_group_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::openflow::cofgroup_stats_request &group_stats_request, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Group-Stats-Request message to attached datapath element. More...
 
uint32_t send_group_desc_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags=0, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Group-Desc-Stats-Request message to attached datapath element. More...
 
uint32_t send_group_features_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Group-Features-Stats-Request message to attached datapath element. More...
 
uint32_t send_port_desc_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Port-Desc-Stats-Request message to attached datapath element. More...
 
uint32_t send_experimenter_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, uint32_t exp_id, uint32_t exp_type, const cmemory &body, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Experimenter-Stats-Request message to attached datapath element. More...
 
uint32_t send_meter_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::openflow::cofmeter_stats_request &meter_stats_request, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Meter-Stats-Request message to attached datapath element. More...
 
uint32_t send_meter_config_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::openflow::cofmeter_config_request &meter_config_stats_request, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Meter-Config-Stats-Request message to attached datapath element. More...
 
uint32_t send_meter_features_stats_request (const rofl::cauxid &auxid, uint16_t stats_flags, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Meter-Features-Stats-Request message to attached datapath element. More...
 
uint32_t send_packet_out_message (const rofl::cauxid &auxid, uint32_t buffer_id, uint32_t in_port, const rofl::openflow::cofactions &actions, uint8_t *data=NULL, size_t datalen=0)
 Sends OpenFlow Packet-Out message to attached datapath element. More...
 
uint32_t send_barrier_request (const rofl::cauxid &auxid, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Barrier-Request message to attached datapath element. More...
 
uint32_t send_role_request (const rofl::cauxid &auxid, const rofl::openflow::cofrole &role, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Role-Request message to attached datapath element. More...
 
uint32_t send_flow_mod_message (const rofl::cauxid &auxid, const rofl::openflow::cofflowmod &flowmod)
 Sends OpenFlow Flow-Mod message to attached datapath element. More...
 
uint32_t send_group_mod_message (const rofl::cauxid &auxid, const rofl::openflow::cofgroupmod &groupmod)
 Sends OpenFlow Group-Mod message to attached datapath element. More...
 
uint32_t send_table_mod_message (const rofl::cauxid &auxid, uint8_t table_id, uint32_t config)
 Sends OpenFlow Table-Mod message to attached datapath element. More...
 
uint32_t send_port_mod_message (const rofl::cauxid &auxid, uint32_t port_no, const rofl::caddress_ll &hwaddr, uint32_t config, uint32_t mask, uint32_t advertise)
 Sends OpenFlow Port-Mod message to attached datapath element. More...
 
uint32_t send_set_config_message (const rofl::cauxid &auxid, uint16_t flags, uint16_t miss_send_len)
 Sends OpenFlow Set-Config message to attached datapath element. More...
 
uint32_t send_queue_get_config_request (const rofl::cauxid &auxid, uint32_t port, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Queue-Get-Config-Request message to attached datapath element. More...
 
uint32_t send_get_async_config_request (const rofl::cauxid &auxid, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Get-Async-Config-Request message to attached datapath element. More...
 
uint32_t send_set_async_config_message (const rofl::cauxid &auxid, const rofl::openflow::cofasync_config &async_config)
 Sends OpenFlow Set-Async-Config message to attached datapath element. More...
 
uint32_t send_meter_mod_message (const rofl::cauxid &auxid, uint16_t command, uint16_t flags, uint32_t meter_id, const rofl::openflow::cofmeter_bands &meter_bands)
 Sends OpenFlow Meter-Mod message to attached datapath element. More...
 
void send_error_message (const rofl::cauxid &auxid, uint32_t xid, uint16_t type, uint16_t code, uint8_t *data=NULL, size_t datalen=0)
 Sends OpenFlow Error message to attached datapath element. More...
 
uint32_t send_experimenter_message (const rofl::cauxid &auxid, uint32_t exp_id, uint32_t exp_type, uint8_t *body=NULL, size_t bodylen=0, const rofl::cclock &timeout=rofl::cclock(DEFAULT_REQUEST_TIMEOUT))
 Sends OpenFlow Experimenter message to attached datapath element. More...
 
- Public Member Functions inherited from rofl::crofchan_env
 crofchan_env ()
 crofchan_env constructor
 
virtual ~crofchan_env ()
 crofchan_env destructor
 
- 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...
 

Static Public Member Functions

static rofl::crofdptget_dpt (const rofl::cdptid &dptid)
 Returns reference to rofl::crofdpt instance identified by rofl-common's internal identifier. More...
 
static rofl::crofdptget_dpt (const rofl::cdpid &dpid)
 Returns reference to rofl::crofdpt instance identified by OpenFlow's datapath identifier. More...
 

Friends

std::ostream & operator<< (std::ostream &os, const crofdpt &dpt)
 

Additional Inherited Members

- 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.
 

Detailed Description

Class representing a remote datapath element.

This class encapsulates properties of a single remote datapath element including the OpenFlow control channel, its lists of ports and tables, and general configuration. Its public API offers methods to manage the OpenFlow control channel, i.e. CRUD methods for individual control connections. Once the OpenFlow control channel has been established, rofl::crofdpt will query the datapath element for its internal configuration (ports, tables and general configuration) and exposes these data to any higher logic. Note that no periodic updates on these data is done by this instance and re-querying the datapath must be initiated by higher logic.

rofl::crofdpt expects an instance of class rofl::crofdpt_env as surrounding environment and sends various notifications via this interface. Class rofl::crofbase implements this interface and may be used as base class for advanced applications. However, you may implement rofl::crofdpt_env directly as well.

Inheritance diagram for rofl::crofdpt:
rofl::crofchan_env rofl::ctransactions_env rofl::ciosrv rofl::ctimer_env

Constructor & Destructor Documentation

rofl::crofdpt::crofdpt ( rofl::crofdpt_env env,
const rofl::cdptid dptid,
bool  remove_on_channel_close,
const rofl::openflow::cofhello_elem_versionbitmap versionbitmap,
const rofl::cdpid dpid = rofl::cdpid(0) 
)
inline

crofdpt constructor

Parameters
envpointer to rofl::crofdpt_env instance defining the environment for this object
dptidrofl-common's internal identifier for this instance
remove_on_channel_closewhen set to true, this indicates to remove this object after the control channel has been terminated
versionbitmapOpenFlow version bitmap
dpidOpenFlow datapath element identifier (optional)
virtual rofl::crofdpt::~crofdpt ( )
inlinevirtual

crofdpt destructor

Closes all control connections and does a general clean-up.

Member Function Documentation

void rofl::crofdpt::add_connection ( crofconn conn)
inline

Add an existing rofl::crofconn instance created on heap to this object.

This method is used for attaching an already existing rofl::crofconn instance to this rofl::crofdpt instance. Do not call this method, unless you know what you are doing.

Parameters
connpointer to rofl::crofconn instance allocated on heap
void rofl::crofdpt::connect ( const rofl::cauxid auxid,
enum rofl::csocket::socket_type_t  socket_type,
const rofl::cparams socket_params 
)
inline

Establishes a new control connection to a remote datapath element with the given control connection identifier.

An already existing control connection with the specified control connection identifier is replaced by this new control connection instance. If the main control connection (auxid: 0) is reconnected, this rofl::crofdpt instance drops all collected state including pending transactions. You may select any arbitrary control connection identifier. However, care must be taken for the main connection (auxid: 0): (Re-)Connecting the main connection leads to an implicit termination of all existing control connections in OpenFlow.

Parameters
auxidcontrol connection identifier
socket_typeone of the socket types defined in rofl::csocket
socket_paramsa set of parameters for the selected socket type
void rofl::crofdpt::disconnect ( rofl::cauxid  auxid)
inline

Terminates an existing control connection with given identifier.

When the main control connection (auxid: 0) is closed, this also terminates all other existing control connections.

Parameters
auxidcontrol connection identifier
void rofl::crofdpt::drop_buffer ( const rofl::cauxid auxid,
uint32_t  buffer_id,
uint32_t  inport = rofl::openflow::OFPP_CONTROLLER 
)
inline

Drops packet identified by buffer-id from the attached datapath element.

Drops a packet stored on the datapath element identified by the given buffer-id by sending a Packet-Out message with an empty action list.

Parameters
auxidcontrol connection identifier
buffer_ididentifier of the packet slot to be removed
inportfield of the Packet-Out message sent to the datapath element
void crofdpt::flow_mod_reset ( )

Removes all flow-table entries from the attached datapath element.

Sends a Flow-Mod-Delete message to the attached datapath element for removing all flow-table entries.

uint32_t rofl::crofdpt::get_capabilities ( ) const
inline

Returns the datapath element's capabilities.

Returns
capabilities
uint16_t rofl::crofdpt::get_config ( ) const
inline

Returns the datapath element's configuration.

Returns
config
std::list<rofl::cauxid> rofl::crofdpt::get_conn_index ( ) const
inline

Returns a list of connection identifiers of all existing control connections.

The list contains all connections independent from their current status.

Returns
list of connection identifiers
const rofl::cdpid& rofl::crofdpt::get_dpid ( ) const
inline

Returns OpenFlow datapath identifier for this instance.

Returns
OpenFlow datapath identifier
crofdpt & crofdpt::get_dpt ( const rofl::cdptid dptid)
static

Returns reference to rofl::crofdpt instance identified by rofl-common's internal identifier.

Parameters
dptidrofl-common's internal datapath identifier
Exceptions
eRofDptNotFoundwhen no object matches the datapath identifier
Returns
reference to rofl::crofdpt instance for given identifier
crofdpt & crofdpt::get_dpt ( const rofl::cdpid dpid)
static

Returns reference to rofl::crofdpt instance identified by OpenFlow's datapath identifier.

Parameters
dpidOpenFlow datapath identifier
Exceptions
eRofDptNotFoundwhen no object matches the datapath identifier
Returns
reference to rofl::crofdpt instance for given identifier
const rofl::cdptid& rofl::crofdpt::get_dptid ( ) const
inline

Returns rofl-common's internal rofl::cdptid identifier for this instance.

Returns
internal datapath element identifier (not DPID)
const rofl::caddress_ll& rofl::crofdpt::get_hwaddr ( ) const
inline

Returns the datapath element's hardware address.

Returns
hwaddr
uint16_t rofl::crofdpt::get_miss_send_len ( ) const
inline

Returns the datapath element's current miss_send_len parameter.

Returns
miss_send_len
uint32_t rofl::crofdpt::get_n_buffers ( ) const
inline

Returns the datapath element's number of buffers for storing data packets.

Returns
n_buffers
uint8_t rofl::crofdpt::get_n_tables ( ) const
inline

Returns the datapath element's number of tables in the OpenFlow pipeline.

Returns
n_tables
uint32_t rofl::crofdpt::get_next_idle_group_id ( )
inline

Returns the next idle group table identifier.

Todo:
There is no overflow checking implemented yet.
Returns
group table identifier
rofl::caddress rofl::crofdpt::get_peer_addr ( const rofl::cauxid auxid) const
inline

Returns caddress of connected remote entity for given connection identifier.

Returns
caddress object obtained from this->socket
const rofl::openflow::cofports& rofl::crofdpt::get_ports ( ) const
inline

Returns const reference to the datapath element's port list.

The ports list is updated by this rofl::crofdpt instance whenever a Port-Status or Port-Desc-Stats-Reply message is received. However, rofl-common won't send periodic Port-Desc-Stats-Request messages, so it is up to the higher layer logic to emit such messages.

Returns
const reference to ports list
const rofl::openflow::coftables& rofl::crofdpt::get_tables ( ) const
inline

Returns const reference to the datapath element's tables list.

The tables list is updated by this rofl::crofdpt instance whenever a Table-Stats-Reply (OFP v1.2) or Table-Features-Stats-Reply (OFP v1.3) message is received. However, rofl-common won't send periodic requests, so it is up to the higher layer logic to emit such messages.

Returns
const reference to tables list
uint8_t rofl::crofdpt::get_version_negotiated ( ) const
inline

Returns the OpenFlow protocol version used for this control connection.

Returns
OpenFlow version used for this control connection
const rofl::openflow::cofhello_elem_versionbitmap& rofl::crofdpt::get_versions_available ( ) const
inline

Returns the defined OpenFlow version bitmap for this instance.

Returns
OpenFlow version bitmap
void crofdpt::group_mod_reset ( )

Removes all group-table entries from the attached datapath element.

Sends a Group-Mod-Delete message to the attached datapath element for removing all group-table entries.

void rofl::crofdpt::release_group_id ( uint32_t  group_id)
inline

Releases a previously allocated group table identifier.

Parameters
group_idgroup table identifier to be returned to pool of idle identifiers
uint32_t crofdpt::send_aggr_stats_request ( const rofl::cauxid auxid,
uint16_t  flags,
const rofl::openflow::cofaggr_stats_request aggr_stats_request,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Aggregate-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
aggr_stats_requestOpenFlow Aggregate-Stats-Request payload
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_barrier_request ( const rofl::cauxid auxid,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Barrier-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_desc_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Desc-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
void crofdpt::send_error_message ( const rofl::cauxid auxid,
uint32_t  xid,
uint16_t  type,
uint16_t  code,
uint8_t *  data = NULL,
size_t  datalen = 0 
)

Sends OpenFlow Error message to attached datapath element.

Parameters
auxidcontroller connection identifier
xidOpenFlow transaction identifier
typeOpenFlow error type
codeOpenFlow error code
datastart of error message payload
datalenlength of error message payload
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_experimenter_message ( const rofl::cauxid auxid,
uint32_t  exp_id,
uint32_t  exp_type,
uint8_t *  body = NULL,
size_t  bodylen = 0,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Experimenter message to attached datapath element.

Parameters
auxidcontroller connection identifier
exp_idOpenFlow experimenter identifier
exp_typeOpenFlow experimenter type
bodystart of experimenter message payload
bodylenlength of experimenter message payload
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_experimenter_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
uint32_t  exp_id,
uint32_t  exp_type,
const cmemory body,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Experimenter-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
exp_idOpenFlow experimenter identifier
exp_typeOpenFlow experimenter type
bodyexperimenter statistics payload
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_features_request ( const rofl::cauxid auxid,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Features-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_flow_mod_message ( const rofl::cauxid auxid,
const rofl::openflow::cofflowmod flowmod 
)

Sends OpenFlow Flow-Mod message to attached datapath element.

Parameters
auxidcontroller connection identifier
flowmodOpenFlow flow mod entry
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_flow_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::openflow::cofflow_stats_request flow_stats_request,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Flow-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_get_async_config_request ( const rofl::cauxid auxid,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Get-Async-Config-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_get_config_request ( const rofl::cauxid auxid,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Get-Config-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_group_desc_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags = 0,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Group-Desc-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_group_features_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Group-Features-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_group_mod_message ( const rofl::cauxid auxid,
const rofl::openflow::cofgroupmod groupmod 
)

Sends OpenFlow Group-Mod message to attached datapath element.

Parameters
auxidcontroller connection identifier
groupmodOpenFlow group mod entry
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_group_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::openflow::cofgroup_stats_request group_stats_request,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Group-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
group_stats_requestOpenFlow Group-Stats-Request payload
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_meter_config_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::openflow::cofmeter_config_request meter_config_stats_request,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Meter-Config-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
meter_config_stats_requestOpenFlow Meter-Config-Stats-Request payload
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_meter_features_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Meter-Features-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_meter_mod_message ( const rofl::cauxid auxid,
uint16_t  command,
uint16_t  flags,
uint32_t  meter_id,
const rofl::openflow::cofmeter_bands meter_bands 
)

Sends OpenFlow Meter-Mod message to attached datapath element.

Parameters
auxidcontroller connection identifier
commandOpenFlow Meter-Mod command
flagsOpenFlow Meter-Mod flags
meter_idOpenFlow Meter-Mod identifier
meter_bandsOpenFlow meterbands
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_meter_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::openflow::cofmeter_stats_request meter_stats_request,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Meter-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
meter_stats_requestOpenFlow Meter-Stats-Request payload
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_packet_out_message ( const rofl::cauxid auxid,
uint32_t  buffer_id,
uint32_t  in_port,
const rofl::openflow::cofactions actions,
uint8_t *  data = NULL,
size_t  datalen = 0 
)

Sends OpenFlow Packet-Out message to attached datapath element.

Parameters
auxidcontroller connection identifier
buffer_idOpenFlow packet buffer identifier
in_portincoming port for OpenFlow matches
actionsOpenFlow actions list
datastart of packet frame
datalenlength of packet frame
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_port_desc_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Port-Desc-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_port_mod_message ( const rofl::cauxid auxid,
uint32_t  port_no,
const rofl::caddress_ll hwaddr,
uint32_t  config,
uint32_t  mask,
uint32_t  advertise 
)

Sends OpenFlow Port-Mod message to attached datapath element.

Parameters
auxidcontroller connection identifier
portnoOpenFlow port number
hwaddrhardware address assigned to this port
configOpenFlow port configuration
maskOpenFlow port mask
OpenFlowport advertise field
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_port_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::openflow::cofport_stats_request port_stats_request,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Port-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
port_stats_requestOpenFlow Port-Stats-Request payload
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_queue_get_config_request ( const rofl::cauxid auxid,
uint32_t  port,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Queue-Get-Config-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
portnoOpenFlow port number
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_queue_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::openflow::cofqueue_stats_request queue_stats_request,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Queue-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
queue_stats_requestOpenFlow Queue-Stats-Request payload
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_role_request ( const rofl::cauxid auxid,
const rofl::openflow::cofrole role,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Role-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
roleOpenFlow role definition
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_set_async_config_message ( const rofl::cauxid auxid,
const rofl::openflow::cofasync_config async_config 
)

Sends OpenFlow Set-Async-Config message to attached datapath element.

Parameters
auxidcontroller connection identifier
async_configOpenFlow async_config payload
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_set_config_message ( const rofl::cauxid auxid,
uint16_t  flags,
uint16_t  miss_send_len 
)

Sends OpenFlow Set-Config message to attached datapath element.

Parameters
auxidcontroller connection identifier
flagsOpenFlow datapath element's flags
miss_send_lenOpenFlow miss_send_len parameter
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_type,
uint16_t  stats_flags,
uint8_t *  body = NULL,
size_t  bodylen = 0,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_typeOpenFlow statistics subtype
stats_flagsOpenFlow statistics flags
bodystart of message payload
bodylenlength of message payload
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_table_features_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Table-Features-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_table_mod_message ( const rofl::cauxid auxid,
uint8_t  table_id,
uint32_t  config 
)

Sends OpenFlow Table-Mod message to attached datapath element.

Parameters
auxidcontroller connection identifier
table_idOpenFlow table identifier
configOpenFlow table configuration
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested
uint32_t crofdpt::send_table_stats_request ( const rofl::cauxid auxid,
uint16_t  stats_flags = 0,
const rofl::cclock timeout = rofl::cclock(DEFAULT_REQUEST_TIMEOUT) 
)

Sends OpenFlow Table-Stats-Request message to attached datapath element.

Parameters
auxidcontroller connection identifier
stats_flagsOpenFlow statistics flags
timeoutuntil this request expires
Returns
OpenFlow transaction ID assigned to this request
Exceptions
rofl::eRofBaseNotConnected
rofl::eRofBaseCongested

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