RefreshingFileReader Class Reference

#include <RefreshingFileReader.h>

Inheritance diagram for RefreshingFileReader:

OrbitFileReader

List of all members.

Public Member Functions

 RefreshingFileReader ()
void setFileName (const UtlString *fileName)
 Set the file name, or clear it with NULL or "".
virtual ~RefreshingFileReader ()
 Destructor.
virtual OsStatus refresh ()
 Check to see if the file has changed, and if so, call initialize().

Static Public Attributes

static const unsigned long sTimeCheckInvalid = 0
 This value has the type of mFileLastModTimeCheck, and can never be returned by OsDateTime::getSecsSinceEpoch().
static const OsTime sModTimeInvalid
 These values have the type of mFileModTime, and can never be returnd by OsFileInfo::getModifiedTime().
static const OsTime sModTimeNoFileName
static const OsTime sModTimeFileNotExist

Protected Member Functions

void reinitialize_state ()
 Reset the state variables to force the file to be re-read.
virtual OsStatus initialize ()=0
 (Re-)read the file and (re)initialize the object.

Protected Attributes

UtlString mFileName
unsigned long mFileLastModTimeCheck
OsTime mFileModTime

Private Member Functions

 RefreshingFileReader (const RefreshingFileReader &rRefreshingFileReader)
RefreshingFileReaderoperator= (const RefreshingFileReader &rRefreshingFileReader)


Constructor & Destructor Documentation

~RefreshingFileReader (  )  [virtual]

Destructor.

RefreshingFileReader ( const RefreshingFileReader rRefreshingFileReader  )  [private]


Member Function Documentation

void setFileName ( const UtlString fileName  ) 

Set the file name, or clear it with NULL or "".

OsStatus refresh (  )  [virtual]

Check to see if the file has changed, and if so, call initialize().

void reinitialize_state (  )  [protected]

Reset the state variables to force the file to be re-read.

virtual OsStatus initialize (  )  [protected, pure virtual]

(Re-)read the file and (re)initialize the object.

Implemented in OrbitFileReader.

RefreshingFileReader& operator= ( const RefreshingFileReader rRefreshingFileReader  )  [private]


Member Data Documentation

const unsigned long sTimeCheckInvalid = 0 [static]

This value has the type of mFileLastModTimeCheck, and can never be returned by OsDateTime::getSecsSinceEpoch().

const OsTime sModTimeInvalid [static]

These values have the type of mFileModTime, and can never be returnd by OsFileInfo::getModifiedTime().

They must all be distinct, because we must re-process the file any time there is a transition between the states they represent.

const OsTime sModTimeNoFileName [static]

const OsTime sModTimeFileNotExist [static]

UtlString mFileName [protected]

unsigned long mFileLastModTimeCheck [protected]

OsTime mFileModTime [protected]


Online Library Docs

sipXecs home page

Version 4.2.1-018930 2010-07-31T01:13:23 build16 abuild