CeresEngine 0.2.0
A game development framework
Loading...
Searching...
No Matches
CeresEngine::AppleFileWatcher Class Referencefinal

File watcher for the local file system for the Windows platform. More...

#include <CeresEngine/Platform/Apple/AppleFileWatcher.hpp>

Inheritance diagram for CeresEngine::AppleFileWatcher:
CeresEngine::IFileWatcher

Public Member Functions

 AppleFileWatcher (AppleFileSystem &fs, ExecutionContext &executionContext, const FileHandle &directory, const FileEvents &events, bool recursive)
 Creates a new AppleFileWatcher instance.
 
 AppleFileWatcher (AppleFileWatcher &&) noexcept=delete
 
AppleFileWatcher & operator= (AppleFileWatcher &&) noexcept=delete
 
 ~AppleFileWatcher () final
 
IFileSystem * getFileSystem () const final
 Gets file system that this watcher watches for.
 
void start () final
 Starts the file watching operation.
 
void stop () final
 Stops the file watching operation.
 
- Public Member Functions inherited from CeresEngine::IFileWatcher
 IFileWatcher ()
 
virtual ~IFileWatcher ()
 

Private Attributes

RC< AppleFileSystem > mFileSystem
 File system that created this watcher.
 

Additional Inherited Members

- Protected Member Functions inherited from CeresEngine::IFileWatcher
void onFileEvent (const FileHandle &handle, FileEvent event)
 Called on file event.
 
- Protected Attributes inherited from CeresEngine::IFileWatcher
FileWatcher * mFileWatcher
 File watcher that owns the implementation.
 

Detailed Description

File watcher for the local file system for the Windows platform.

Constructor & Destructor Documentation

◆ AppleFileWatcher() [1/2]

CeresEngine::AppleFileWatcher::AppleFileWatcher ( AppleFileSystem &  fs,
ExecutionContext &  executionContext,
const FileHandle &  directory,
const FileEvents &  events,
bool  recursive 
)
explicit

Creates a new AppleFileWatcher instance.

Parameters
fileSystemThe file system that created this watcher.

◆ AppleFileWatcher() [2/2]

CeresEngine::AppleFileWatcher::AppleFileWatcher ( AppleFileWatcher &&  )
deletenoexcept

◆ ~AppleFileWatcher()

CeresEngine::AppleFileWatcher::~AppleFileWatcher ( )
final

Member Function Documentation

◆ getFileSystem()

IFileSystem * CeresEngine::AppleFileWatcher::getFileSystem ( ) const
finalvirtual

Gets file system that this watcher watches for.

Returns
The watched file system (can be null).

Implements CeresEngine::IFileWatcher.

◆ operator=()

AppleFileWatcher & CeresEngine::AppleFileWatcher::operator= ( AppleFileWatcher &&  )
deletenoexcept

◆ start()

void CeresEngine::AppleFileWatcher::start ( )
finalvirtual

Starts the file watching operation.

Note
This function begins to watch the file system on a background thread. On every event, onFileEvent() is called using the watcher execution context with the typeof the event and a file handle to the file or directory. To stop listening, call stop().

Implements CeresEngine::IFileWatcher.

◆ stop()

void CeresEngine::AppleFileWatcher::stop ( )
finalvirtual

Stops the file watching operation.

Implements CeresEngine::IFileWatcher.

Member Data Documentation

◆ mFileSystem

RC<AppleFileSystem> CeresEngine::AppleFileWatcher::mFileSystem
private

File system that created this watcher.


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