omegalib  13.1
omicron::AssetCacheManager Class Reference

The asset cache manager connects to a remote cache service and synchronizes a list of files with it. More...

#include <AssetCacheManager.h>

Public Member Functions

 AssetCacheManager ()
 
virtual ~AssetCacheManager ()
 
void setCacheName (const String &value)
 Set the name of the cache handled by this manager. More...
 
String cacheName ()
 
void addCacheHost (const String &)
 Sets the hostname of the machine running the cache service Must be done before starting a sync. More...
 
void clearCacheHosts ()
 
void setCachePort (uint value)
 Sets the listening port of the cache service. More...
 
uint getCachePort ()
 
void addFileToCacheList (const String &file)
 Add a file name to the list of files that need to be synchronized. More...
 
void clearCacheFileList ()
 
void setForceOverwrite (bool value)
 When set to true, forces overwriting of files in the cache. More...
 
bool isForceOverwriteEnabled ()
 
void sync ()
 Start synching. More...
 
void startSync ()
 Start synching. More...
 
bool isSynching ()
 
void setVerbose (bool value)
 When set to true, output detailed messages about synching. More...
 
bool isVerbose ()
 
- Public Member Functions inherited from omicron::ReferenceType
 ReferenceType ()
 
virtual ~ReferenceType ()
 
void ref ()
 
void unref ()
 
long refCount ()
 

Friends

class CacheSyncThread
 
class CacheConnection
 

Additional Inherited Members

- Static Public Member Functions inherited from omicron::ReferenceType
static void printObjCounts ()
 
- Static Protected Attributes inherited from omicron::ReferenceType
static List< ReferenceType * > mysObjList
 

Detailed Description

The asset cache manager connects to a remote cache service and synchronizes a list of files with it.

+ Inheritance diagram for omicron::AssetCacheManager:

Constructor & Destructor Documentation

omicron::AssetCacheManager::AssetCacheManager ( )
virtual omicron::AssetCacheManager::~AssetCacheManager ( )
virtual

Member Function Documentation

void omicron::AssetCacheManager::addCacheHost ( const String )

Sets the hostname of the machine running the cache service Must be done before starting a sync.

void omicron::AssetCacheManager::addFileToCacheList ( const String file)

Add a file name to the list of files that need to be synchronized.

Must be done before starting a sync.

String omicron::AssetCacheManager::cacheName ( )
inline
void omicron::AssetCacheManager::clearCacheFileList ( )
void omicron::AssetCacheManager::clearCacheHosts ( )
uint omicron::AssetCacheManager::getCachePort ( )
inline
bool omicron::AssetCacheManager::isForceOverwriteEnabled ( )
inline
bool omicron::AssetCacheManager::isSynching ( )
inline
bool omicron::AssetCacheManager::isVerbose ( )
inline
void omicron::AssetCacheManager::setCacheName ( const String value)
inline

Set the name of the cache handled by this manager.

Must be done before starting a sync.

void omicron::AssetCacheManager::setCachePort ( uint  value)
inline

Sets the listening port of the cache service.

Must be done before starting a sync.

void omicron::AssetCacheManager::setForceOverwrite ( bool  value)
inline

When set to true, forces overwriting of files in the cache.

Useful for replacing cache contents. Must be done before starting a sync.

void omicron::AssetCacheManager::setVerbose ( bool  value)
inline

When set to true, output detailed messages about synching.

void omicron::AssetCacheManager::startSync ( )

Start synching.

This call is nonblocking and will return immediately. Use isSynching to check for completion.

void omicron::AssetCacheManager::sync ( )

Start synching.

This is a blocking call. It will not return until synching is done.

Friends And Related Function Documentation

friend class CacheConnection
friend
friend class CacheSyncThread
friend

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