fawkes::NetworkAspect Class Reference
[Fawkes Thread Aspects]

Thread aspect for network communication. More...

#include <aspect/network.h>

Inheritance diagram for fawkes::NetworkAspect:

[legend]
List of all members.

Public Member Functions

virtual ~NetworkAspect ()
 Virtual empty Destructor.
void init_NetworkAspect (NetworkNameResolver *resolver, ServicePublisher *service_publisher, ServiceBrowser *service_browser)
 Init network aspect.

Protected Attributes

NetworkNameResolvernnresolver
 Network name resolver to lookup IP addresses of hostnames and vice versa.
ServicePublisherservice_publisher
 Service publisher to publish services on the network.
ServiceBrowserservice_browser
 Service browser to browse services on the network.

Detailed Description

Thread aspect for network communication.

Give this aspect to your thread if you want to implement custom network communication. With this aspect you get access to the central network name resolver and you may publish service on the network and browse for existing services (for example using mDNS-SD via Avahi).

It is guaranteed that if used properly from within plugins that initNetworkAspect() is called before the thread is started.

Author:
Tim Niemueller

Definition at line 33 of file network.h.


Constructor & Destructor Documentation

fawkes::NetworkAspect::~NetworkAspect (  )  [virtual]

Virtual empty Destructor.

Definition at line 62 of file network.cpp.


Member Function Documentation

void fawkes::NetworkAspect::init_NetworkAspect ( NetworkNameResolver resolver,
ServicePublisher service_publisher,
ServiceBrowser service_browser 
)

Init network aspect.

It is guaranteed that this is called for a thread having the netwok aspect before Thread::start() is called (when running regularly inside Fawkes).

Parameters:
resolver network name resolver
service_publisher service publisher
service_browser service browser

Definition at line 76 of file network.cpp.

References nnresolver, service_browser, and service_publisher.

Referenced by fawkes::AspectIniFin::init().


Member Data Documentation

NetworkNameResolver fawkes::NetworkAspect::nnresolver [protected]

Network name resolver to lookup IP addresses of hostnames and vice versa.

The nnresolver will remain valid for the whole lifetime of the thread.

Definition at line 43 of file network.h.

Referenced by XmlRpcThread::init(), WebviewThread::init(), WorldModelNetworkThread::init(), FountainThread::init(), and init_NetworkAspect().

NetworkNameResolver fawkes::NetworkAspect::service_browser [protected]

Service browser to browse services on the network.

The service_browser will remain valid for the whole lifetime of the thread.

Definition at line 45 of file network.h.

Referenced by WebviewThread::finalize(), WebviewThread::init(), and init_NetworkAspect().

NetworkNameResolver fawkes::NetworkAspect::service_publisher [protected]

Service publisher to publish services on the network.

The service_publisher will remain valid for the whole lifetime of the thread.

Definition at line 44 of file network.h.

Referenced by XmlRpcThread::finalize(), WebviewThread::finalize(), FountainThread::finalize(), XmlRpcThread::init(), WebviewThread::init(), FountainThread::init(), and init_NetworkAspect().


The documentation for this class was generated from the following files:
Generated on Tue Feb 22 13:32:45 2011 for Fawkes API by  doxygen 1.4.7