Main MRPT website > C++ reference for MRPT 1.5.6
List of all members | Classes | Public Types | Public Member Functions | Private Attributes
mrpt::system::CFileSystemWatcher Class Reference

Detailed Description

This class subscribes to notifications of file system changes, thus it can be used to efficiently stay informed about changes in a directory tree.

Definition at line 28 of file CFileSystemWatcher.h.

#include <mrpt/system/CFileSystemWatcher.h>

Classes

struct  TFileSystemChange
 Each of the changes detected by utils::CFileSystemWatcher. More...
 

Public Types

typedef std::deque
< TFileSystemChange
TFileSystemChangeList
 

Public Member Functions

 CFileSystemWatcher (const std::string &path)
 Creates the subscription to a specified path. More...
 
virtual ~CFileSystemWatcher ()
 Destructor. More...
 
void getChanges (TFileSystemChangeList &out_list)
 Call this method sometimes to get the list of changes in the watched directory. More...
 

Private Attributes

std::string m_watchedDirectory
 Ended in "/". More...
 

Member Typedef Documentation

Definition at line 53 of file CFileSystemWatcher.h.

Constructor & Destructor Documentation

CFileSystemWatcher::CFileSystemWatcher ( const std::string path)

Creates the subscription to a specified path.

Parameters
pathThe file or directory to watch.

Definition at line 41 of file CFileSystemWatcher.cpp.

References ASSERT_, mrpt::system::createThreadFromObjectMethod(), HANDLE(), m_watchedDirectory, MRPT_END, MRPT_START, and THROW_EXCEPTION.

CFileSystemWatcher::~CFileSystemWatcher ( )
virtual

Destructor.

Definition at line 97 of file CFileSystemWatcher.cpp.

References HANDLE(), and mrpt::system::terminateThread().

Member Function Documentation

void CFileSystemWatcher::getChanges ( TFileSystemChangeList out_list)

Member Data Documentation

std::string mrpt::system::CFileSystemWatcher::m_watchedDirectory
private

Ended in "/".

Definition at line 70 of file CFileSystemWatcher.h.

Referenced by CFileSystemWatcher(), and getChanges().




Page generated by Doxygen 1.8.6 for MRPT 1.5.6 Git: 4c65e84 Tue Apr 24 08:18:17 2018 +0200 at mar abr 24 08:26:17 CEST 2018