xorp

XrlProcessSpy Class Reference

Class that watches remote FEA and RIB processes. More...

#include <xrl_process_spy.hh>

Inheritance diagram for XrlProcessSpy:
ServiceBase BugCatcher

List of all members.

Public Member Functions

 XrlProcessSpy (XrlRouter &rtr)
int startup ()
 Register interest in FEA and RIB with Finder.
int shutdown ()
 Deregister interest in FEA and RIB with Finder.
bool fea_present () const
 Get indication of whether FEA is present.
bool rib_present () const
 Get indication of whether RIB is present.
void birth_event (const string &class_name, const string &instance_name)
 Inform instance about the birth of an Xrl Target instance within a class.
void death_event (const string &class_name, const string &instance_name)
 Inform instance about the death of a Xrl Target instance within a class.

Protected Member Functions

void send_register (uint32_t idx)
void register_cb (const XrlError &e, uint32_t idx)
void schedule_register_retry (uint32_t idx)
void send_deregister (uint32_t idx)
void deregister_cb (const XrlError &e, uint32_t idx)
void schedule_deregister_retry (uint32_t idx)

Protected Attributes

XrlRouter_rtr
string _cname [END_IDX]
string _iname [END_IDX]
XorpTimer _retry

Static Protected Attributes

static const uint32_t FEA_IDX = 0
static const uint32_t RIB_IDX = 1
static const uint32_t END_IDX = 2

Detailed Description

Class that watches remote FEA and RIB processes.

This class registers interest with the Finder in the FEA and RIB processes and reports whether the FEA and RIB are running to interested parties.


Member Function Documentation

void XrlProcessSpy::birth_event ( const string &  class_name,
const string &  instance_name 
)

Inform instance about the birth of an Xrl Target instance within a class.

Typically called by associated Xrl Target of running RIP.

Parameters:
class_nameclass of new born Xrl Target.
instance_nameinstance name of new born Xrl Target.
void XrlProcessSpy::death_event ( const string &  class_name,
const string &  instance_name 
)

Inform instance about the death of a Xrl Target instance within a class.

Typically called by associated Xrl Target of running RIP.

Parameters:
class_nameclass of recently deceased Xrl Target.
instance_nameinstance name of recently deceased Xrl Target.
bool XrlProcessSpy::fea_present ( ) const

Get indication of whether FEA is present.

Returns:
true if FEA is present, false if FEA is not present or run_status() is not in SERVICE_RUNNING state.
bool XrlProcessSpy::rib_present ( ) const

Get indication of whether RIB is present.

Returns:
true if RIB is present, false if RIB is not present or run_status() is not in SERVICE_RUNNING state.
int XrlProcessSpy::shutdown ( ) [virtual]

Deregister interest in FEA and RIB with Finder.

Returns:
XORP_OK on success, otherwise XORP_ERROR.

Implements ServiceBase.

int XrlProcessSpy::startup ( ) [virtual]

Register interest in FEA and RIB with Finder.

Returns:
XORP_OK on success, otherwise XORP_ERROR.

Implements ServiceBase.


The documentation for this class was generated from the following files:
 All Classes Namespaces Functions Variables Typedefs Enumerations