class NextHopResolver


 
LOGO
 Annotated List  Files  Globals  Hierarchy  Index  Top

Public Methods

Protected Members


Detailed Description

 NextHopResolver (XrlStdRouter *xrl_router, EventLoop& eventloop, BGPMain& bgp)

NextHopResolver

 ~NextHopResolver ()

~NextHopResolver

[virtual]

void  add_decision (DecisionTable<A> *decision)

add_decision

Add decision.

Pass a pointer to the decision table into the next hop resolver. This pointer is used to notify the decision table when a next hop metric changes.

Parameters:

decisionPointer to the decision table.
bool  register_ribname (const string& r)

register_ribname

Set the rib's name, allows for having a dummy rib or not having a RIB at all.

bool  register_nexthop (A nexthop, IPNet<A> net_from_route, NhLookupTable<A> *requester)

register_nexthop

[virtual]

Register interest in this nexthop.

Parameters:

nexthopNexthop.
net_from_routeThe net that is associated with this nexthop in the NextHopLookupTable. Treated as an opaque id.
requesterOnce the registration with the RIB suceeds the requester is called back.

Returns: True if the registration succeed.

void  deregister_nexthop (A nexthop, IPNet<A> net_from_route, NhLookupTable<A> *requester)

deregister_nexthop

[virtual]

De-Register interest in this nexthop.

Parameters:

nexthopNexthop.
net_from_routeThe net that is associated with this nexthop in the NextHopLookupTable. Treated as an opaque id.
requesterOriginal requester, not used.

Returns: True if the registration succeed.

bool  lookup (const A nexthop, bool& resolvable, uint32_t& metric)

lookup

[const virtual]

Lookup next hop.

If a "register_nexthop" request has been made and callback has taken place via the "requester" pointer, then the lookup is guaranteed to work.

Parameters:

nexthopNext hop.
resolvableIs this route resolvable.
metricIf this route is resolvable the metric of this route.

Returns: True if this next hop is found.

bool  rib_client_route_info_changed (const A& addr, const uint32_t& prefix_len, const A& nexthop, const uint32_t& metric)

rib_client_route_info_changed

Call from the RIB to notify us that a metric has changed.

bool  rib_client_route_info_invalid (const A& addr, const uint32_t& prefix_len)

rib_client_route_info_invalid

Call from the RIB to notify us that any registrations with this address and prefix_len are now invalid.

void  next_hop_changed (A nexthop)

next_hop_changed

Next hop changed.

Whenever a next hop changes this method should be called and the change will be rippled up to the decision process.

Parameters:

nexthopThe next hop that has changed.
void  next_hop_changed (A nexthop, bool old_resolves, uint32_t old_metric)

next_hop_changed

Next hop changed.

Whenever a next hop changes this method should be called and the change will be rippled up to the decision process. However if a change occurs but the metrics don't change don't bother to ripple up the change there is no point.

Parameters:

nexthopThe next hop that has changed.
old_resolvesThe old resolve value.
old_metricThe old metric value.
NextHopRibRequest<A> * get_next_hop_rib_request ()

get_next_hop_rib_request

Get NextHopRibRequest pointer.

Used for testing.

EventLoop&  eventloop ()

eventloop

Get a reference to the main timer list

list<DecisionTable<A> *> _decision

_decision

[protected]


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