ariba::AribaModule Class Reference

#include <source/ariba/AribaModule.h>

Inherits ariba::Module.

Collaboration diagram for ariba::AribaModule:

Collaboration graph
[legend]

List of all members.

Classes

class  BootstrapInfo
class  BootstrapNode

Public Member Functions

 AribaModule ()
virtual ~AribaModule ()
string getBootstrapHints (const Name &spoVNetName=Name::UNSPECIFIED) const
void addBootstrapHints (string bootinfo)
void registerSideportListener (SideportListener *sideport)
void initialize ()
void start ()
void stop ()
string getName () const
void setProperty (string key, string value)
const string getProperty (string key) const
const vector< string > getProperties () const
const string getLocalEndpoints ()

Protected Member Functions

void addBootstrapNode (const Name &spovnet, communication::EndpointDescriptor *desc)
const
communication::EndpointDescriptor
getBootstrapNode (const Name &spovnet) const

Protected Attributes

string bootstrapFile
string endpoints
bool started
communication::BaseCommunicationbase_comm
SideportListenersideport_sniffer

Private Member Functions

 use_logging_h (AribaModule)

Private Attributes

vector< BootstrapInfobootstrapNodes

Friends

class Node


Detailed Description

This class implements a container class for ariba base services. Each node is a running using this base-module. It also manages Bootstrap information in a abstract simple way.

+---+ +---+ |N1 | |N2 | +--| |---| |--+ | +---+ +---+ | | | | AribaModule | +-----------------+

N1, N2 are nodes.

Author:
Sebastian Mies <mies@tm.uka.de>

Christoph Mayer <mayer@tm.uka.de>

Definition at line 87 of file AribaModule.h.


Constructor & Destructor Documentation

ariba::AribaModule::AribaModule (  ) 

Constructor of the ariba underlay module

Definition at line 61 of file AribaModule.cpp.

References endpoints.

ariba::AribaModule::~AribaModule (  )  [virtual]

Destructor of the ariba underlay module

Definition at line 71 of file AribaModule.cpp.


Member Function Documentation

void ariba::AribaModule::addBootstrapHints ( string  bootinfo  ) 

Adds bootstrap hints to the local database. The format of the string must is the same as returned by getBootstrapInfo.

Parameters:
bootinfo A string containing bootstrap information.

Definition at line 89 of file AribaModule.cpp.

References addBootstrapNode(), logging_debug, ariba::utility::string_format::robject_data, ariba::utility::string_format::robject_id, ariba::utility::string_format::robjects, and ariba::communication::EndpointDescriptor::toString().

Referenced by setProperty().

void ariba::AribaModule::addBootstrapNode ( const Name spovnet,
communication::EndpointDescriptor desc 
) [protected]

string ariba::AribaModule::getBootstrapHints ( const Name spoVNetName = Name::UNSPECIFIED  )  const

Returns all known bootstrap endpoints to this ariba module in a human-readable string. This information can be used by other nodes for bootstraping. It may also be used to publish this info to other nodes via the web, for example.

Parameters:
The name of the spovnet
Returns:
A human-readable string containing all known bootstrap information known to this module.

Definition at line 74 of file AribaModule.cpp.

References bootstrapNodes, ariba::AribaModule::AribaModule::BootstrapNode::desc, ariba::AribaModule::AribaModule::BootstrapInfo::nodes, ariba::AribaModule::AribaModule::BootstrapInfo::spovnetName, ariba::communication::EndpointDescriptor::toString(), and ariba::Name::toString().

Referenced by addBootstrapNode(), and getProperty().

const communication::EndpointDescriptor * ariba::AribaModule::getBootstrapNode ( const Name spovnet  )  const [protected]

const string ariba::AribaModule::getLocalEndpoints (  ) 

string ariba::AribaModule::getName (  )  const [virtual]

See also:
Module.h

Reimplemented from ariba::Module.

Definition at line 191 of file AribaModule.cpp.

const vector< string > ariba::AribaModule::getProperties (  )  const [virtual]

See also:
Module.h

Reimplemented from ariba::Module.

Definition at line 208 of file AribaModule.cpp.

const string ariba::AribaModule::getProperty ( string  key  )  const [virtual]

See also:
Module.h

Reimplemented from ariba::Module.

Definition at line 202 of file AribaModule.cpp.

References endpoints, and getBootstrapHints().

void ariba::AribaModule::initialize (  )  [virtual]

Module Property information:

ip.addr = preferred ip address (otherwise bind to all) tcp.port = preferred tcp port (or use default value) udp.port = preferred udp port (or use default value) bootstrap.hints = used bootstrap hints bootstrap.file = used file for bootstrap information

See also:
Module.h

Reimplemented from ariba::Module.

Definition at line 156 of file AribaModule.cpp.

References base_comm, and started.

void ariba::AribaModule::registerSideportListener ( SideportListener sideport  ) 

Register a sideport for sniffing on communication events and get advanced information. The sniffer is attached to every node that is created on the module. Only one such sniffer can be active system-wide, a new call to this register function will only attach the sniffer to nodes created after the registration call.

Parameters:
sideport The SideportListener to integrate

Definition at line 151 of file AribaModule.cpp.

References sideport_sniffer.

void ariba::AribaModule::setProperty ( string  key,
string  value 
) [virtual]

See also:
Module.h

Reimplemented from ariba::Module.

Definition at line 196 of file AribaModule.cpp.

References addBootstrapHints(), and endpoints.

Referenced by ariba::application::pingpong::PingPong::startup().

void ariba::AribaModule::start (  )  [virtual]

void ariba::AribaModule::stop (  )  [virtual]

See also:
Module.h

Reimplemented from ariba::Module.

Definition at line 179 of file AribaModule.cpp.

References base_comm, and started.

Referenced by ariba::application::pingpong::PingPong::shutdown().

ariba::AribaModule::use_logging_h ( AribaModule   )  [private]


Friends And Related Function Documentation

friend class Node [friend]

Definition at line 88 of file AribaModule.h.


Member Data Documentation

Definition at line 194 of file AribaModule.h.

Definition at line 190 of file AribaModule.h.

Referenced by addBootstrapNode(), getBootstrapHints(), and getBootstrapNode().

string ariba::AribaModule::endpoints [protected]

Definition at line 195 of file AribaModule.h.

Referenced by AribaModule(), getProperty(), setProperty(), and start().

Definition at line 205 of file AribaModule.h.

Referenced by ariba::Node::bind(), and registerSideportListener().

bool ariba::AribaModule::started [protected]

Definition at line 196 of file AribaModule.h.

Referenced by initialize(), start(), and stop().


The documentation for this class was generated from the following files:

Generated on Fri Aug 14 23:39:09 2009 for Ariba by  doxygen 1.5.8