class DebugIO

The DebugIO class realizes the interface IO. More...

 
LOGO
 Annotated List  Files  Globals  Hierarchy  Index  Top

Public Methods


Detailed Description

It is used for OLSR regression tests.

 DebugIO (TestInfo& info, EventLoop& eventloop)

DebugIO

 ~DebugIO ()

~DebugIO

[virtual]

void  pp (const string& which, int level, const string& interface, const string& vif, IPv4 dst, uint16_t dport, IPv4 src, uint16_t sport, uint8_t* data, uint32_t len)

pp

int  startup ()

startup

Reimplemented from ServiceBase.

int  shutdown ()

shutdown

Reimplemented from ServiceBase.

bool  enable_address (const string& interface, const string& vif, const IPv4& address, const uint16_t& port, const IPv4& all_nodes_address)

enable_address

Reimplemented from IO.

bool  disable_address (const string& interface, const string& vif, const IPv4& address, const uint16_t& port)

disable_address

Reimplemented from IO.

bool  is_interface_enabled (const string& interface)

is_interface_enabled

[const]

Test whether this interface is enabled.

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

Reimplemented from IO.

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

is_vif_enabled

[const]

Test whether this interface/vif is enabled.

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

Reimplemented from IO.

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

is_vif_broadcast_capable

Reimplemented from IO.

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

is_vif_multicast_capable

Reimplemented from IO.

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

is_vif_loopback

Reimplemented from IO.

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

is_address_enabled

[const]

Test whether this interface/vif/address is enabled.

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

Reimplemented from IO.

bool  get_addresses (const string& interface, const string& vif, list<IPv4>& addresses)

get_addresses

[const]

Get all addresses associated with this interface/vif.

Parameters:

interfacethe name of the interface
vifthe name of the vif
addresses(out argument) list of associated addresses

Returns: true if there are no errors.

Reimplemented from IO.

bool  get_broadcast_address (const string& interface, const string& vif, const IPv4& address, IPv4& bcast_address)

get_broadcast_address

[const]

Get the broadcast address associated with this IPv4 address.

Parameters:

interfacethe name of the interface
vifthe name of the vif
addressthe IPv4 interface address
bcast_address(out argument) the IPv4 broadcast address

Returns: true if there are no errors.

Reimplemented from IO.

bool  get_interface_id (const string& interface, uint32_t& interface_id)

get_interface_id

Returns: the interface id for this interface, as seen by libfeaclient.

Reimplemented from IO.

uint32_t  get_mtu (const string& interface)

get_mtu

Returns: the mtu for this interface.

Reimplemented from IO.

inline int  packets ()

packets

[const]

Returns: the number of packets which have transited this interface.

bool  send (const string& interface, const string& vif, const IPv4 & src, const uint16_t & sport, const IPv4 & dst, const uint16_t & dport, uint8_t* data, const uint32_t & len)

send

Send a UDP datagram from src:sport to dst:dport, preferably on the given link.

Reimplemented from IO.

void  receive (const string& interface, const string& vif, const IPv4 & dst, const uint16_t& dport, const IPv4 & src, const uint16_t& sport, uint8_t* data, const uint32_t & len)

receive

Receive frames. Specific to DebugIo.

bool  register_forward (const string& interface, const string& vif, IO::ReceiveCallback cb)

register_forward

Register where datagrams should be forwarded. Specific to DebugIo.

void  unregister_forward (const string& interface, const string& vif)

unregister_forward

Unregister an existing callback registered with register_forward(). Specific to DebugIo.

bool  add_route (IPv4Net net, IPv4 nexthop, uint32_t nexthop_id, uint32_t metric, const PolicyTags& policytags)

add_route

Reimplemented from IO.

bool  replace_route (IPv4Net net, IPv4 nexthop, uint32_t nexthop_id, uint32_t metric, const PolicyTags & policytags)

replace_route

Reimplemented from IO.

bool  delete_route (IPv4Net net)

delete_route

Reimplemented from IO.

void  routing_table_empty ()

routing_table_empty

uint32_t  routing_table_size ()

routing_table_size

bool  routing_table_verify (IPv4Net net, IPv4 nexthop, uint32_t metric)

routing_table_verify

Verify that this route is in the routing table.

void  routing_table_dump (ostream& o)

routing_table_dump

Dump the routing table contents to the given ostream (not necessarily what's in the TestInfo).


Generated by: pavlin on kobe.xorp.net on Wed Jan 7 19:11:15 2009, using kdoc 2.0a54+XORP.