class Module

A class for managing router manager modules. More...

 
LOGO
 Annotated List  Files  Globals  Hierarchy  Index  Top

Public Methods


Detailed Description

 Module (ModuleManager& mmgr, const string& name, const string& path, const string& expath, bool verbose)

Module

Constructor.

Parameters:

mmgrthe module manager (ModuleManager) to use.
namethe module name.
paththe path to the executable program for this module.
expaththe expanded absolute path to the executable program for this module.
verboseif true, then output trace messages.
 ~Module ()

~Module

The default destructor.

void  new_status (ModuleStatus new_status)

new_status

Set new status for the module.

Parameters:

new_statusthe new status for the module.

Reimplemented from GenericModule.

string  str ()

str

[const]

Convert the module information to a string.

Returns: a string with the module information.

Reimplemented from GenericModule.

ModuleManager&  module_manager ()

module_manager

[const]

Get a reference to the module manager (ModuleManager).

Returns: a reference to the module manager.

const string&  expath ()

expath

[const]

Get the expanded absolute path to the executable program.

Returns: the expanded absolute path to the executable program.

int  execute (bool do_exec, bool is_verification, XorpCallback1<void, bool>::RefPtr cb)

execute

Execute the module.

Parameters:

do_execif true then indeed execute the executable program, otherwise just process the execution machinery.

Returns: XORP_OK on success, otherwise XORP_ERROR.

int  restart ()

restart

Restart the module.

Returns: XORP_OK on success, otherwise XORP_ERROR.

void  terminate (XorpCallback0<void>::RefPtr cb)

terminate

Terminate the module.

Parameters:

cbthe callback to execute after the module is terminated.
void  terminate_with_prejudice (XorpCallback0<void>::RefPtr cb)

terminate_with_prejudice

Terminate the module with prejudice.

Parameters:

cbthe callback to execute after the module is terminated.
void  module_exited (bool success, bool is_signal_terminated, int term_signal, bool is_coredumped)

module_exited

A method called when the corresponding process has exited.

Parameters:

successif true, the exit status of the process indicates success, otherwise failure.
is_signal_terminatedif true the process has been terminated by a signal.
term_signalif is_signal_terminated is true, this contains the terminating signal.
is_coredumpedif true the process has generated a coredump.
void  module_stopped (int stop_signal)

module_stopped

A method called when the corresponding process has been stopped.

Parameters:

stop_signalthe signal that has stopped the process.

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