class IO

An abstract class that defines packet reception and transmission. More...

 
LOGO
 Annotated List  Files  Globals  Hierarchy  Index  Top

Public Types

Public Methods

Protected Members


Detailed Description

An abstract class that defines packet reception and transmission. The details of how packets are received or transmitted are therefore hidden from the internals of the OSPF code.

 IO ()

IO

 ~IO ()

~IO

[virtual]

uint16_t  get_ip_protocol_number ()

get_ip_protocol_number

[const]

Get OSPF protocol number.

bool  send (const string& interface, const string& vif, A dst, A src, uint8_t* data, uint32_t len)

send

[pure virtual]

Send Raw frames.

bool  set_ip_router_alert (bool alert)

set_ip_router_alert

Send router alerts in IP packets?

bool  get_ip_router_alert ()

get_ip_router_alert

[const]

Get router alert state.

typedef XorpCallback6<void, const string&, const string&, A, A, uint8_t*, uint32_t>::RefPtr ReceiveCallback

ReceiveCallback

void  register_receive (ReceiveCallback cb)

register_receive

Register for receiving raw frames.

bool  enable_interface_vif (const string& interface, const string& vif)

enable_interface_vif

[pure virtual]

Enable the interface/vif to receive frames.

bool  disable_interface_vif (const string& interface, const string& vif)

disable_interface_vif

[pure virtual]

Disable this interface/vif from receiving frames.

bool  is_interface_enabled (const string& interface)

is_interface_enabled

[const pure virtual]

Test whether this interface is enabled.

Returns: true if it exists and is enabled, otherwise false.

bool  is_vif_enabled (const string& interface, const string& vif)

is_vif_enabled

[const pure virtual]

Test whether this interface/vif is enabled.

Returns: true if it exists and is enabled, otherwise false.

bool  is_address_enabled (const string& interface, const string& vif, const A& address)

is_address_enabled

[const pure virtual]

Test whether this interface/vif/address is enabled.

Returns: true if it exists and is enabled, otherwise false.

typedef XorpCallback2<void, const string&, bool>::RefPtr InterfaceStatusCb

InterfaceStatusCb

typedef XorpCallback3<void, const string&, const string&, bool>::RefPtr VifStatusCb

VifStatusCb

typedef XorpCallback4<void, const string&, const string&, A, bool>::RefPtr AddressStatusCb

AddressStatusCb

void  register_interface_status (InterfaceStatusCb cb)

register_interface_status

Add a callback for tracking the interface status.

The callback will be invoked whenever the status of the interface is changed from disabled to enabled or vice-versa.

Parameters:

cbthe callback to register.
void  register_vif_status (VifStatusCb cb)

register_vif_status

Add a callback for tracking the interface/vif status.

The callback will be invoked whenever the status of the interface/vif is changed from disabled to enabled or vice-versa.

Parameters:

cbthe callback to register.
void  register_address_status (AddressStatusCb cb)

register_address_status

Add a callback for tracking the interface/vif/address status.

The callback will be invoked whenever the status of the tuple (interface, vif, address) is changed from disabled to enabled or vice-versa.

Parameters:

cbthe callback to register.
uint32_t  get_prefix_length (const string& interface, const string& vif, A address)

get_prefix_length

[pure virtual]

Returns: prefix length for this address.

uint32_t  get_mtu (const string& interface)

get_mtu

[pure virtual]

Returns: the mtu for this interface.

bool  join_multicast_group (const string& interface, const string& vif, A mcast)

join_multicast_group

[pure virtual]

On the interface/vif join this multicast group.

bool  leave_multicast_group (const string& interface, const string& vif, A mcast)

leave_multicast_group

[pure virtual]

On the interface/vif leave this multicast group.

bool  add_route (IPNet<A> net, A nexthop, uint32_t metric, bool equal, bool discard, const PolicyTags& policytags)

add_route

[pure virtual]

Add route

Parameters:

netnetwork
metricto network
equaltrue if this in another route to the same destination.
discardtrue if this is a discard route.
policytagspolicy info to the RIB.
bool  replace_route (IPNet<A> net, A nexthop, uint32_t metric, bool equal, bool discard, const PolicyTags& policytags)

replace_route

[pure virtual]

Replace route

Parameters:

netnetwork
metricto network
equaltrue if this in another route to the same destination.
discardtrue if this is a discard route.
policytagspolicy info to the RIB.
bool  delete_route (IPNet<A> net)

delete_route

[pure virtual]

Delete route

ReceiveCallback _receive_cb

_receive_cb

[protected]

InterfaceStatusCb _interface_status_cb

_interface_status_cb

[protected]

VifStatusCb _vif_status_cb

_vif_status_cb

[protected]

AddressStatusCb _address_status_cb

_address_status_cb

[protected]

bool _ip_router_alert

_ip_router_alert

[protected]


Generated by: pavlin on possum.icir.org on Thu Mar 9 04:43:44 2006, using kdoc $.