You.i Engine
yi::deprecated::CYIFileWatcher Class Reference

Detailed Description

Monitor one or more directories for changes in their files.

The file watcher class will monitor one or more directories for changes and will signal any defined slots when that resource has been modified, removed, or created. The notification method is very fast and does not use polling, but does require the user to make a quick check for the notification.

Deprecated:
This class has been deprecated and may be removed in a future release as it is not in use and not available for many platforms.

#include <deprecated/YiFileWatcher.h>

Public Member Functions

 CYIFileWatcher ()
 
 ~CYIFileWatcher ()
 
YI_FILEWATCHID AddWatch (const CYIString &filePath)
 
void RemoveWatch (YI_FILEWATCHID id)
 
void UpdateAsyncHandler ()
 

Public Attributes

CYISignal< const CYIString & > Modified
 
CYISignal< const CYIString & > Deleted
 
CYISignal< const CYIString & > Created
 

Constructor & Destructor Documentation

◆ CYIFileWatcher()

yi::deprecated::CYIFileWatcher::CYIFileWatcher ( )

Default constructor.

◆ ~CYIFileWatcher()

yi::deprecated::CYIFileWatcher::~CYIFileWatcher ( )

Destructor.

Member Function Documentation

◆ AddWatch()

YI_FILEWATCHID yi::deprecated::CYIFileWatcher::AddWatch ( const CYIString filePath)

Adds a file watch for the given file path and returns a file watch id, which is a unique number that refers to the watched file or directory.

◆ RemoveWatch()

void yi::deprecated::CYIFileWatcher::RemoveWatch ( YI_FILEWATCHID  id)

Removes the file or directory watch using the file watch id.

◆ UpdateAsyncHandler()

void yi::deprecated::CYIFileWatcher::UpdateAsyncHandler ( )

Updates the various system dependent file watch methods. This should be called as often as possible.

Member Data Documentation

◆ Created

CYISignal<const CYIString &> yi::deprecated::CYIFileWatcher::Created

This signal is emitted when the watched file or directory has been created.

◆ Deleted

CYISignal<const CYIString &> yi::deprecated::CYIFileWatcher::Deleted

This signal is emitted when the watched file or directory has been deleted.

◆ Modified

CYISignal<const CYIString &> yi::deprecated::CYIFileWatcher::Modified

This signal is emitted when the watched file or directory has been modified.


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