Fawkes API  Fawkes Development Version
fawkes::FamListener Class Referenceabstract

File Alteration Monitor Listener. More...

#include <>>

Inheritance diagram for fawkes::FamListener:

Public Member Functions

virtual ~FamListener ()
 Virtual empty destructor. More...
 
virtual void fam_event (const char *filename, unsigned int mask)=0
 Event has been raised. More...
 

Static Public Attributes

static const unsigned int FAM_ACCESS = 0x00000001
 File was accessed. More...
 
static const unsigned int FAM_MODIFY = 0x00000002
 File was modified. More...
 
static const unsigned int FAM_ATTRIB = 0x00000004
 Metadata changed. More...
 
static const unsigned int FAM_CLOSE_WRITE = 0x00000008
 Writtable file was closed. More...
 
static const unsigned int FAM_CLOSE_NOWRITE = 0x00000010
 Unwrittable file closed. More...
 
static const unsigned int FAM_CLOSE = (FAM_CLOSE_WRITE | FAM_CLOSE_NOWRITE)
 Close. More...
 
static const unsigned int FAM_OPEN = 0x00000020
 File was opened. More...
 
static const unsigned int FAM_MOVED_FROM = 0x00000040
 File was moved from X. More...
 
static const unsigned int FAM_MOVED_TO = 0x00000080
 File was moved to Y. More...
 
static const unsigned int FAM_MOVE = (FAM_MOVED_FROM | FAM_MOVED_TO)
 Moves. More...
 
static const unsigned int FAM_CREATE = 0x00000100
 Subfile was created. More...
 
static const unsigned int FAM_DELETE = 0x00000200
 Subfile was deleted. More...
 
static const unsigned int FAM_DELETE_SELF = 0x00000400
 Self was deleted. More...
 
static const unsigned int FAM_MOVE_SELF = 0x00000800
 Self was moved. More...
 
static const unsigned int FAM_UNMOUNT = 0x00002000
 Backing fs was unmounted. More...
 
static const unsigned int FAM_Q_OVERFLOW = 0x00004000
 Event queued overflowed. More...
 
static const unsigned int FAM_IGNORED = 0x00008000
 File was ignored. More...
 
static const unsigned int FAM_ONLYDIR = 0x01000000
 Only watch the path if it is a directory. More...
 
static const unsigned int FAM_DONT_FOLLOW = 0x02000000
 Do not follow a sym link. More...
 
static const unsigned int FAM_MASK_ADD = 0x20000000
 Add to the mask of an already existing watch. More...
 
static const unsigned int FAM_ISDIR = 0x40000000
 Event occurred against dir. More...
 
static const unsigned int FAM_ONESHOT = 0x80000000
 Only send event once. More...
 
static const unsigned int FAM_ALL_EVENTS
 All events which a program can wait on. More...
 

Detailed Description

File Alteration Monitor Listener.

Listener called by FileAlterationMonitor for events.

Author
Tim Niemueller

Definition at line 35 of file fam.h.

Constructor & Destructor Documentation

◆ ~FamListener()

fawkes::FamListener::~FamListener ( )
virtual

Virtual empty destructor.

Definition at line 451 of file fam.cpp.

Member Function Documentation

◆ fam_event()

fawkes::FamListener::fam_event ( const char *  filename,
unsigned int  mask 
)
pure virtual

Event has been raised.

Parameters
filenamename of the file that triggered the event
maskmask indicating the event. Currently inotify event flags are used, see inotify.h.

Implemented in fawkes::LuaContext, fawkes::YamlConfiguration, fawkes::PluginManager, NavGraphThread, and LuaAgentContinuousExecutionThread.

Member Data Documentation

◆ FAM_ACCESS

const unsigned int fawkes::FamListener::FAM_ACCESS = 0x00000001
static

File was accessed.

Definition at line 40 of file fam.h.

◆ FAM_ALL_EVENTS

const unsigned int fawkes::FamListener::FAM_ALL_EVENTS
static
Initial value:

All events which a program can wait on.

Definition at line 65 of file fam.h.

◆ FAM_ATTRIB

const unsigned int fawkes::FamListener::FAM_ATTRIB = 0x00000004
static

Metadata changed.

Definition at line 42 of file fam.h.

◆ FAM_CLOSE

const unsigned int fawkes::FamListener::FAM_CLOSE = (FAM_CLOSE_WRITE | FAM_CLOSE_NOWRITE)
static

Close.

Definition at line 45 of file fam.h.

◆ FAM_CLOSE_NOWRITE

const unsigned int fawkes::FamListener::FAM_CLOSE_NOWRITE = 0x00000010
static

Unwrittable file closed.

Definition at line 44 of file fam.h.

◆ FAM_CLOSE_WRITE

const unsigned int fawkes::FamListener::FAM_CLOSE_WRITE = 0x00000008
static

Writtable file was closed.

Definition at line 43 of file fam.h.

◆ FAM_CREATE

const unsigned int fawkes::FamListener::FAM_CREATE = 0x00000100
static

Subfile was created.

Definition at line 50 of file fam.h.

Referenced by fawkes::PluginManager::fam_event().

◆ FAM_DELETE

const unsigned int fawkes::FamListener::FAM_DELETE = 0x00000200
static

Subfile was deleted.

Definition at line 51 of file fam.h.

Referenced by fawkes::PluginManager::fam_event().

◆ FAM_DELETE_SELF

const unsigned int fawkes::FamListener::FAM_DELETE_SELF = 0x00000400
static

Self was deleted.

Definition at line 52 of file fam.h.

◆ FAM_DONT_FOLLOW

const unsigned int fawkes::FamListener::FAM_DONT_FOLLOW = 0x02000000
static

Do not follow a sym link.

Definition at line 60 of file fam.h.

◆ FAM_IGNORED

const unsigned int fawkes::FamListener::FAM_IGNORED = 0x00008000
static

File was ignored.

Definition at line 57 of file fam.h.

Referenced by NavGraphThread::fam_event().

◆ FAM_ISDIR

const unsigned int fawkes::FamListener::FAM_ISDIR = 0x40000000
static

Event occurred against dir.

Definition at line 62 of file fam.h.

Referenced by fawkes::PluginManager::fam_event().

◆ FAM_MASK_ADD

const unsigned int fawkes::FamListener::FAM_MASK_ADD = 0x20000000
static

Add to the mask of an already existing watch.

Definition at line 61 of file fam.h.

◆ FAM_MODIFY

const unsigned int fawkes::FamListener::FAM_MODIFY = 0x00000002
static

File was modified.

Definition at line 41 of file fam.h.

Referenced by fawkes::PluginManager::fam_event(), and NavGraphThread::fam_event().

◆ FAM_MOVE

const unsigned int fawkes::FamListener::FAM_MOVE = (FAM_MOVED_FROM | FAM_MOVED_TO)
static

Moves.

Definition at line 49 of file fam.h.

◆ FAM_MOVE_SELF

const unsigned int fawkes::FamListener::FAM_MOVE_SELF = 0x00000800
static

Self was moved.

Definition at line 53 of file fam.h.

◆ FAM_MOVED_FROM

const unsigned int fawkes::FamListener::FAM_MOVED_FROM = 0x00000040
static

File was moved from X.

Definition at line 47 of file fam.h.

Referenced by fawkes::PluginManager::fam_event().

◆ FAM_MOVED_TO

const unsigned int fawkes::FamListener::FAM_MOVED_TO = 0x00000080
static

File was moved to Y.

Definition at line 48 of file fam.h.

Referenced by fawkes::PluginManager::fam_event().

◆ FAM_ONESHOT

const unsigned int fawkes::FamListener::FAM_ONESHOT = 0x80000000
static

Only send event once.

Definition at line 63 of file fam.h.

◆ FAM_ONLYDIR

const unsigned int fawkes::FamListener::FAM_ONLYDIR = 0x01000000
static

Only watch the path if it is a directory.

Definition at line 59 of file fam.h.

◆ FAM_OPEN

const unsigned int fawkes::FamListener::FAM_OPEN = 0x00000020
static

File was opened.

Definition at line 46 of file fam.h.

◆ FAM_Q_OVERFLOW

const unsigned int fawkes::FamListener::FAM_Q_OVERFLOW = 0x00004000
static

Event queued overflowed.

Definition at line 56 of file fam.h.

◆ FAM_UNMOUNT

const unsigned int fawkes::FamListener::FAM_UNMOUNT = 0x00002000
static

Backing fs was unmounted.

Definition at line 55 of file fam.h.


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