Wittyshare
0.2
|
handles the update of the FileSystemTree More...
#include <WsFsTreeUpdater.h>
Public Member Functions | |
WsFsTreeUpdater (const std::string &p, unsigned int delay, bool m=false) | |
constrictor More... | |
~WsFsTreeUpdater () | |
int | update () |
update the fsTree More... | |
FileSystemTreePtr | getLastTree () |
returns the last created tree More... | |
bool | isLastVersion (FileSystemTreePtr fs) |
checks whether the fs is the last version More... | |
Private Member Functions | |
int | startRegularUpdate () |
Starts the regular update of the tree. More... | |
int | threadUpdate () |
Updates the tree in a thread. More... | |
Private Attributes | |
std::string | m_rootPath |
RootPath. More... | |
bool | m_isMonitor |
Use Gamin or no. More... | |
WsAbstractMonitor * | m_monitor |
Pointer to the file monitoring class used. More... | |
unsigned int | m_delay |
Delay after which the FileSystemTree will be updated if changed occured. More... | |
FileSystemTreePtr | m_fsTree |
boost::mutex | m_lMutex |
boost::mutex | m_updateMutex |
bool | m_isLoaded |
handles the update of the FileSystemTree
Updates the FileSystemTree by launching Gamin or by regularly updating it
Definition at line 34 of file WsFsTreeUpdater.h.
WsFsTreeUpdater::WsFsTreeUpdater | ( | const std::string & | p, |
unsigned int | delay, | ||
bool | m = false |
||
) |
constrictor
p | the root path |
m | Monitor or not ? |
Definition at line 18 of file WsFsTreeUpdater.cpp.
WsFsTreeUpdater::~WsFsTreeUpdater | ( | ) |
Definition at line 27 of file WsFsTreeUpdater.cpp.
FileSystemTreePtr WsFsTreeUpdater::getLastTree | ( | ) |
returns the last created tree
Definition at line 34 of file WsFsTreeUpdater.cpp.
bool WsFsTreeUpdater::isLastVersion | ( | FileSystemTreePtr | fs | ) |
checks whether the fs is the last version
fs | the FilsSystemTree to check |
Definition at line 84 of file WsFsTreeUpdater.cpp.
|
private |
Starts the regular update of the tree.
This method must be called in a thread and only if Gamin is disabled
Definition at line 99 of file WsFsTreeUpdater.cpp.
|
private |
Updates the tree in a thread.
Definition at line 89 of file WsFsTreeUpdater.cpp.
int WsFsTreeUpdater::update | ( | ) |
update the fsTree
Definition at line 46 of file WsFsTreeUpdater.cpp.
|
private |
Delay after which the FileSystemTree will be updated if changed occured.
Definition at line 98 of file WsFsTreeUpdater.h.
|
private |
Definition at line 100 of file WsFsTreeUpdater.h.
|
private |
Definition at line 104 of file WsFsTreeUpdater.h.
|
private |
Use Gamin or no.
Definition at line 88 of file WsFsTreeUpdater.h.
|
private |
Definition at line 102 of file WsFsTreeUpdater.h.
|
private |
Pointer to the file monitoring class used.
Definition at line 93 of file WsFsTreeUpdater.h.
|
private |
RootPath.
Definition at line 83 of file WsFsTreeUpdater.h.
|
private |
Definition at line 103 of file WsFsTreeUpdater.h.