Public Member Functions

fawkes::AspectIniFin Class Reference

Fawkes Aspect Initializer/Finalizer. More...

#include <>>

Inheritance diagram for fawkes::AspectIniFin:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 AspectIniFin (BlackBoard *blackboard, ThreadCollector *collector, Configuration *config, Logger *logger, Clock *clock)
 Constructor.
virtual ~AspectIniFin ()
 Destructor.
virtual void init (Thread *thread)
 Initialize thread.
virtual void finalize (Thread *thread)
 Finalize thread.
virtual bool prepare_finalize (Thread *thread)
void set_fnet_hub (FawkesNetworkHub *fnethub)
 Set Fawkes Network Hub.
void set_mainloop_employer (MainLoopEmployer *employer)
 Set Fawkes MainLoopEmployer.
void set_logger_employer (LoggerEmployer *employer)
 Set Fawkes LoggerEmployer.
void set_blocked_timing_executor (BlockedTimingExecutor *btexec)
 Set Fawkes BlockedTimingExecutor.
void set_network_members (NetworkNameResolver *nnresolver, ServicePublisher *service_publisher, ServiceBrowser *service_browser)
 Set Fawkes Network Hub.
void set_plugin_manager (PluginManager *manager)
 Set plugin manager.
virtual bool thread_started (Thread *thread) throw ()
 Thread started successfully.
virtual bool thread_init_failed (Thread *thread) throw ()
 Thread initialization failed.

Detailed Description

Fawkes Aspect Initializer/Finalizer.

Initializes certain thread aspects. All aspects defined in the Fawkes tree are supported and properly initialized such that guarantees are met.

See also:
Fawkes Thread Aspects
Author:
Tim Niemueller

Definition at line 60 of file inifin.h.


Constructor & Destructor Documentation

fawkes::AspectIniFin::AspectIniFin ( BlackBoard blackboard,
ThreadCollector collector,
Configuration config,
Logger logger,
Clock clock 
)

Constructor.

Parameters:
blackboard BlackBoard
collector Thread collector
config Configuration
logger Logger
clock Clock

Definition at line 67 of file inifin.cpp.

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

Destructor.

Definition at line 88 of file inifin.cpp.


Member Function Documentation

void fawkes::AspectIniFin::finalize ( Thread thread  )  [virtual]
void fawkes::AspectIniFin::init ( Thread thread  )  [virtual]
void fawkes::AspectIniFin::set_blocked_timing_executor ( BlockedTimingExecutor btexec  ) 

Set Fawkes BlockedTimingExecutor.

Use this to set the Fawkes blocked timing executor.

Parameters:
btexec blocked timing executor instance

Definition at line 135 of file inifin.cpp.

Referenced by FawkesMainThread::FawkesMainThread().

void fawkes::AspectIniFin::set_fnet_hub ( FawkesNetworkHub fnethub  ) 

Set Fawkes Network Hub.

Use this to set the Fawkes Network Hub. If you do not use the Fawkes Network you do not need to call this function to set a hub. In that case threads that demand the hub will cause an exception to be thrown that the thread cannot be initialized.

Parameters:
fnethub Fawkes Network Hub

Definition at line 101 of file inifin.cpp.

Referenced by FawkesMainThread::FawkesMainThread().

void fawkes::AspectIniFin::set_logger_employer ( LoggerEmployer employer  ) 

Set Fawkes LoggerEmployer.

Parameters:
employer logger employer

Definition at line 124 of file inifin.cpp.

Referenced by FawkesMainThread::FawkesMainThread().

void fawkes::AspectIniFin::set_mainloop_employer ( MainLoopEmployer employer  ) 

Set Fawkes MainLoopEmployer.

Use this to set the Fawkes main loop employer. The main loop employer is used to set a new main loop of a plugin with the MainLoopAspect. Uniqueness is quaranteed such that only a single main loop exists at any given time.

Parameters:
employer main loop employer

Definition at line 114 of file inifin.cpp.

Referenced by FawkesMainThread::FawkesMainThread().

void fawkes::AspectIniFin::set_network_members ( NetworkNameResolver nnresolver,
ServicePublisher service_publisher,
ServiceBrowser service_browser 
)

Set Fawkes Network Hub.

Use this to initialize the NetworkAspect. If you do not use the Network Aspect you do not need to call this function to set a hub. In that case threads that demand this aspect will cause an exception to be thrown that the thread cannot be initialized.

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

Definition at line 151 of file inifin.cpp.

Referenced by FawkesMainThread::FawkesMainThread().

void fawkes::AspectIniFin::set_plugin_manager ( PluginManager manager  ) 

Set plugin manager.

Parameters:
manager PluginManager instance

Definition at line 165 of file inifin.cpp.

Referenced by FawkesMainThread::FawkesMainThread().

bool fawkes::AspectIniFin::thread_init_failed ( Thread thread  )  throw () [virtual]

Thread initialization failed.

This method is called by ThreadList if one of the threads in the list failed to initialize. This is not necessarily the thread that you registered the notification for. However, the argument is always the thread that you registered for, no matter which thread in the list failed.

Parameters:
thread thread that you registered for
Returns:
true to stay registered for further thread notifications, false to unregister.

Implements fawkes::ThreadNotificationListener.

Definition at line 456 of file inifin.cpp.

References fawkes::Thread::name().

bool fawkes::AspectIniFin::thread_started ( Thread thread  )  throw () [virtual]

Thread started successfully.

This is called by the thread itself when the thread started successfully.

Parameters:
thread thread that started successfully
Returns:
true to stay registered for further thread notifications, false to unregister.

Implements fawkes::ThreadNotificationListener.

Definition at line 439 of file inifin.cpp.


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