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

Flow Table of active flows. More...

#include <cflowtable.h>

Public Member Functions

Methods for CRUD operations on active flow entries.
void clear ()
 Deletes all entries stored in this cflowtable instance.
 
cflowentryadd_flow_entry (const rofl::caddress_ll &src, const rofl::caddress_ll &dst, uint32_t portno)
 Returns reference to empty cflowentry instance for given hardware address. More...
 
cflowentryset_flow_entry (const rofl::caddress_ll &src, const rofl::caddress_ll &dst, uint32_t portno)
 Returns reference to existing cflowentry instance for given hardware address. More...
 
cflowentryset_flow_entry (const rofl::caddress_ll &src, const rofl::caddress_ll &dst)
 Returns reference to existing cflowentry instance for given hardware address. More...
 
const cflowentryget_flow_entry (const rofl::caddress_ll &src, const rofl::caddress_ll &dst) const
 Returns const reference to existing cflowentry instance for given hardware address. More...
 
void drop_flow_entry (const rofl::caddress_ll &src, const rofl::caddress_ll &dst)
 Removes an existing cflowentry for given source and destination hardware address. More...
 
bool has_flow_entry (const rofl::caddress_ll &src, const rofl::caddress_ll &dst) const
 Checks whether a cflowentry exists for given source and destination hardware address. More...
 
- Public Member Functions inherited from rofl::examples::ethswctld::cflowentry_env
virtual ~cflowentry_env ()
 cflowentry_env destructor
 

Static Public Member Functions

Methods for managing Active Flow Tables
static cflowtableadd_flowtable (const rofl::cdptid &dptid)
 Returns reference to new or existing and resetted cflowtable instance. More...
 
static cflowtableset_flowtable (const rofl::cdptid &dptid)
 Returns reference to existing cflowtable instance or creates a new empty one. More...
 
static const cflowtableget_flowtable (const rofl::cdptid &dptid)
 Returns const reference to existing cflowtable instance or throws exception. More...
 
static void drop_flowtable (const rofl::cdptid &dptid)
 Removes an existing cflowtable instance. More...
 
static bool has_flowtable (const rofl::cdptid &dptid)
 Checks existence of cflowtable for given identifier. More...
 

Friends

std::ostream & operator<< (std::ostream &os, cflowtable const &flowtable)
 

Additional Inherited Members

Detailed Description

Flow Table of active flows.

This class stores all active flows created on a given datapath element. Class cflowentry defines the container for an active flow. Class cflowtable defines two groups of methods:

  1. Static methods on CRUD operations for instances of class cflowtable
  2. Methods on CRUD operations for instances of class cflowentry in a cflowtable instance
See Also
cflowentry
cflowentry_env
Inheritance diagram for rofl::examples::ethswctld::cflowtable:
rofl::examples::ethswctld::cflowentry_env

Member Function Documentation

cflowentry& rofl::examples::ethswctld::cflowtable::add_flow_entry ( const rofl::caddress_ll src,
const rofl::caddress_ll dst,
uint32_t  portno 
)
inline

Returns reference to empty cflowentry instance for given hardware address.

Creates a new cflowentry instance or resets an already existing one for the given identifier.

Parameters
srcethernet hardware address for source station of flow
dstethernet hardware address for destination station of flow
portnooutgoing port for this flow
Exceptions
eFlowInvalhardware address validation failed
static cflowtable& rofl::examples::ethswctld::cflowtable::add_flowtable ( const rofl::cdptid dptid)
inlinestatic

Returns reference to new or existing and resetted cflowtable instance.

This method creates a new or resets an existing instance of class cflowtable for the given datapath handle.

Parameters
dptidrofl-common's internal handle for datapath element
void rofl::examples::ethswctld::cflowtable::drop_flow_entry ( const rofl::caddress_ll src,
const rofl::caddress_ll dst 
)
inline

Removes an existing cflowentry for given source and destination hardware address.

Parameters
srcethernet hardware address for source station of flow
dstethernet hardware address for destination station of flow
static void rofl::examples::ethswctld::cflowtable::drop_flowtable ( const rofl::cdptid dptid)
inlinestatic

Removes an existing cflowtable instance.

Parameters
dptidrofl-common's internal handle for datapath element
const cflowentry& rofl::examples::ethswctld::cflowtable::get_flow_entry ( const rofl::caddress_ll src,
const rofl::caddress_ll dst 
) const
inline

Returns const reference to existing cflowentry instance for given hardware address.

Returns reference to existing cflowentry for given identifier or throw exception, if none exists.

Parameters
srcethernet hardware address for source station of flow
dstethernet hardware address for destination station of flow
Exceptions
eFlowInvalhardware address validation failed
eFlowNotFoundflow destination address not found
static const cflowtable& rofl::examples::ethswctld::cflowtable::get_flowtable ( const rofl::cdptid dptid)
inlinestatic

Returns const reference to existing cflowtable instance or throws exception.

This method returns a const reference to an existing cflowtable instance. If no instance for the given identifier is found, an exception of type eFibNotFound is thrown.

Parameters
dptidrofl-common's internal handle for datapath element
Exceptions
eFibNotFound
bool rofl::examples::ethswctld::cflowtable::has_flow_entry ( const rofl::caddress_ll src,
const rofl::caddress_ll dst 
) const
inline

Checks whether a cflowentry exists for given source and destination hardware address.

Parameters
srcethernet hardware address for source station of flow
dstethernet hardware address for destination station of flow
static bool rofl::examples::ethswctld::cflowtable::has_flowtable ( const rofl::cdptid dptid)
inlinestatic

Checks existence of cflowtable for given identifier.

Parameters
dptidrofl-common's internal handle for datapath element
cflowentry& rofl::examples::ethswctld::cflowtable::set_flow_entry ( const rofl::caddress_ll src,
const rofl::caddress_ll dst,
uint32_t  portno 
)
inline

Returns reference to existing cflowentry instance for given hardware address.

Returns reference to existing cflowentry for given identifier or creates new one if non exists yet.

Parameters
srcethernet hardware address for source station of flow
dstethernet hardware address for destination station of flow
portnooutgoing port for this flow
Exceptions
eFlowInvalhardware address validation failed
cflowentry& rofl::examples::ethswctld::cflowtable::set_flow_entry ( const rofl::caddress_ll src,
const rofl::caddress_ll dst 
)
inline

Returns reference to existing cflowentry instance for given hardware address.

Returns reference to existing cflowentry for given identifier or throw exception, if none exists.

Parameters
srcethernet hardware address for source station of flow
dstethernet hardware address for destination station of flow
Exceptions
eFlowInvalhardware address validation failed
eFlowNotFoundflow destination address not found
static cflowtable& rofl::examples::ethswctld::cflowtable::set_flowtable ( const rofl::cdptid dptid)
inlinestatic

Returns reference to existing cflowtable instance or creates a new empty one.

This method returns a reference to an existing cflowtable instance. If no instance for the given identifier is found, a new instance is created.

Parameters
dptidrofl-common's internal handle for datapath element

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