class IPRouteEntry

Routing Table Entry. More...

 
LOGO
 Annotated List  Files  Globals  Hierarchy  Index  Top

Public Methods

Protected Members


Detailed Description

This class stores a regular RIB routing table entry for either an IPv4 or an IPv6 route. It is a template class, where A is either a the IPv4 class or the IPv6 class.

 IPRouteEntry (const IPNet<A>& net, Vif* vif, NextHop* nexthop, const Protocol& protocol, uint16_t metric)

IPRouteEntry

Constructor for IPRouteEntry.

Parameters:

netthe Subnet (address and mask) of the routing table entry.
vifthe Virtual Interface on which packets matching this routing table entry should be forwarded.
nexthopthe NextHop router to which packets matching this entry should be forwarded.
protocolthe routing protocol that originated this route.
metricthe routing protocol metric for this route.
 IPRouteEntry (const IPNet<A>& net, Vif* vif, NextHop* nexthop, const Protocol& protocol, uint16_t metric, const PolicyTags& policytags)

IPRouteEntry

Constructor for IPRouteEntry.

Parameters:

netthe Subnet (address and mask) of the routing table entry.
vifthe Virtual Interface on which packets matching this routing table entry should be forwarded.
nexthopthe NextHop router to which packets matching this entry should be forwarded.
protocolthe routing protocol that originated this route.
metricthe routing protocol metric for this route.
policytagsthe policy-tags for this route.
 ~IPRouteEntry ()

~IPRouteEntry

Destructor for Routing Table Entry

inline const IPNet<A>&  net ()

net

[const]

Get the route entry's subnet addres.

Returns: the route entry's subnet address.

inline size_t  prefix_len ()

prefix_len

[const]

Get the prefix length of the route entry's subnet address.

Returns: the prefix length (in bits) of the route entry's subnet address.

inline const A&  nexthop_addr ()

nexthop_addr

[const]

Get the route entry's next-hop router address.

Returns: the route entry's next-hop router address. If there is no next-hop router, then the return value is IPv4#ZERO() or IPv6#ZERO().

inline const PolicyTags&  policytags ()

policytags

[const]

Get the policy-tags for this route.

Returns: the policy-tags for this route.

inline void  set_policytags (const PolicyTags& ptags)

set_policytags

Replace policy-tags in the route.

Parameters:

ptagsThe new policy-tags for this route.
string  str ()

str

[const]

Get the route entry as a string for debugging purposes.

Returns: a human readable representation of the route entry.

Reimplemented from RouteEntry.

IPNet<A> _net

_net

[protected]

PolicyTags _policytags

_policytags

[protected]


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