Fawkes API
Fawkes Development Version
|
Initializer/finalizer for the VisionMasterAspect. More...
#include <>>
Public Member Functions | |
VisionMasterAspectIniFin () | |
Constructor. More... | |
virtual void | init (Thread *thread) |
Initialize thread. More... | |
virtual void | finalize (Thread *thread) |
Finalize thread. More... | |
virtual bool | prepare_finalize (Thread *thread) |
Default finalize preparation. More... | |
firevision::VisionMaster * | vision_master () |
Get vision master. More... | |
void | add_vision_thread (VisionAspect *thread) |
Add a vision thread. More... | |
void | remove_vision_thread (VisionAspect *thread) |
Remove a vision thread. More... | |
bool | can_remove_vision_thread (VisionAspect *thread) |
Query if vision thread can be removed. More... | |
![]() | |
AspectIniFin (const char *aspect_name) __attribute__((nonnull)) | |
Constructor. More... | |
virtual | ~AspectIniFin () |
Virtual empty destructor. More... | |
const char * | get_aspect_name () const |
Get aspect name. More... | |
Initializer/finalizer for the VisionMasterAspect.
Definition at line 41 of file vision_master.h.
fawkes::VisionMasterAspectIniFin::VisionMasterAspectIniFin | ( | ) |
Constructor.
Definition at line 40 of file vision_master.cpp.
void fawkes::VisionMasterAspectIniFin::add_vision_thread | ( | VisionAspect * | thread | ) |
Add a vision thread.
thread | thread to add |
Definition at line 122 of file vision_master.cpp.
Referenced by fawkes::VisionAspectIniFin::init().
bool fawkes::VisionMasterAspectIniFin::can_remove_vision_thread | ( | VisionAspect * | thread | ) |
Query if vision thread can be removed.
thread | thread to query for |
Definition at line 141 of file vision_master.cpp.
Referenced by fawkes::VisionAspectIniFin::prepare_finalize().
|
virtual |
Finalize thread.
The aspect for the given thread must be initialized. Use dynamic_cast to cast the thread into the expected aspect class. An exception must be thrown if this fails. If anything fails during initialization of the aspect an Exception must be thrown. This will not prevent the thread from being removed. Use prepare_finalize() to report problems that should prevent the thread from being unloaded.
thread | thread to finalize |
Implements fawkes::AspectIniFin.
Definition at line 87 of file vision_master.cpp.
References fawkes::Exception::append(), and fawkes::Thread::name().
|
virtual |
Initialize thread.
The aspect for the given thread must be initialized. Use dynamic_cast to cast the thread into the expected aspect class. An exception must be thrown if this fails. If anything fails during initialization of the aspect an Exception must be thrown.
thread | thread to initialize |
Implements fawkes::AspectIniFin.
Definition at line 47 of file vision_master.cpp.
References fawkes::Exception::append(), and fawkes::Thread::name().
|
virtual |
Default finalize preparation.
This is a default implementation that assumes that finalization is always safe. Override it if you need to make more fine-grained decisions.
thread | thread to prepare for finalization |
Reimplemented from fawkes::AspectIniFin.
Definition at line 69 of file vision_master.cpp.
void fawkes::VisionMasterAspectIniFin::remove_vision_thread | ( | VisionAspect * | thread | ) |
Remove a vision thread.
thread | thread to remove |
Definition at line 131 of file vision_master.cpp.
Referenced by fawkes::VisionAspectIniFin::finalize().
firevision::VisionMaster * fawkes::VisionMasterAspectIniFin::vision_master | ( | ) |
Get vision master.
Definition at line 112 of file vision_master.cpp.
Referenced by fawkes::VisionAspectIniFin::init().