#include <utils/system/fam_thread.h>
Inheritance diagram for fawkes::FamThread:
Public Member Functions | |
FamThread (RefPtr< FileAlterationMonitor > fam=RefPtr< FileAlterationMonitor >()) | |
Constructor. | |
RefPtr< FileAlterationMonitor > | get_fam () |
Get FileAlterationMonitor. | |
virtual void | loop () |
Code to execute in the thread. | |
Protected Member Functions | |
virtual void | run () |
Stub to see name in backtrace for easier debugging. |
This thread wraps a FileAlterationMonitor and runs it continuously possibly causing FAM events in this thread context. This thread is useful if you have no good place to call FileAlterationMonitor::process_events() in your part.
Definition at line 35 of file fam_thread.h.
fawkes::FamThread::FamThread | ( | RefPtr< FileAlterationMonitor > | fam = RefPtr<FileAlterationMonitor>() |
) |
Constructor.
fam | optional RefPtr to FileAlterationMonitor. If none is given one is instantiated by the FamThread instance. |
Definition at line 45 of file fam_thread.cpp.
RefPtr< FileAlterationMonitor > fawkes::FamThread::get_fam | ( | ) |
Definition at line 58 of file fam_thread.cpp.
void fawkes::FamThread::loop | ( | ) | [virtual] |
Code to execute in the thread.
Implement this method to hold the code you want to be executed continously. If you do not implement this method, the default is that the thread will exit. This is useful if you choose to only implement once().
Reimplemented from fawkes::Thread.
Definition at line 65 of file fam_thread.cpp.
virtual void fawkes::FamThread::run | ( | ) | [inline, protected, virtual] |
Stub to see name in backtrace for easier debugging.
Reimplemented from fawkes::Thread.
Definition at line 45 of file fam_thread.h.