This class helps DtVrfMessageInterface handle big messages.
More...
Public Member Functions |
| | DtSplitContentTimer () |
| | Contructor.
|
| virtual | ~DtSplitContentTimer () |
| | destructor
|
| virtual void | addTimeoutEntry (const DtSplitMessageKey &key, DtTime startTime) |
| | Start a timer for the given key.
|
| virtual void | clear () |
| | remove all entries.
|
| virtual void | evaluateTimeouts (DtTime timeNow, DtSplitContentExpiredFcn pFcn, void *pUsr) |
| | Walk through the DtTimeoutMap, invoke DtSplitContentExpiredFcn for things needing to be purged.
|
| virtual bool | findEntry (const DtSplitMessageKey &key, DtTime &retTime) |
| | returns true if entry found, with expiration time returned in retTime.
|
| virtual void | removeTimeoutEntry (const DtSplitMessageKey &key) |
| | searches for an entry matching key, removes it.
|
|
| virtual DtTime | lastTimeoutCheckTime () const |
| | returns the last time a full check was made.
|
| virtual void | setLastTimeoutCheckTime (DtTime nTime) |
| | returns the last time a full check was made.
|
|
| virtual DtTime | timeoutCheckInterval () const |
| | time, in seconds, that the collection should be revisited for evaluation.
|
| virtual void | setTimeoutCheckInterval (DtTime nSecs) |
| | time, in seconds, that the collection should be revisited for evaluation.
|
|
| virtual DtTime | timeoutDuration () const |
| | time, in seconds, before an entry is considered expired.
|
| virtual void | setTimeoutDuration (DtTime nSecs) |
| | time, in seconds, before an entry is considered expired.
|
Detailed Description
This class helps DtVrfMessageInterface handle big messages.
DtSplitContentTimer is a simple class that helps track when messages should be purged. Classes like DtVrfMessageInterface and DtSignalMessageTransporter gather multiple chunks of message content. DtSplitContentTimer is used to track when those chunks first arrive. If a full sequence of content fails to arrive by expiration time, DtSplitContentTimer will signal the expiration of those content chunks.
Member Typedef Documentation
A collection of message ID and timeout time pairs.
Constructor & Destructor Documentation
| DtSplitContentTimer::DtSplitContentTimer |
( |
| ) |
|
| virtual DtSplitContentTimer::~DtSplitContentTimer |
( |
| ) |
|
|
virtual |
Member Function Documentation
| virtual void DtSplitContentTimer::addTimeoutEntry |
( |
const DtSplitMessageKey & |
key, |
|
|
DtTime |
startTime |
|
) |
| |
|
virtual |
Start a timer for the given key.
Starts a timer for the given key. Expiration time is computed as startTime + myTimeoutDuration
| virtual void DtSplitContentTimer::clear |
( |
| ) |
|
|
virtual |
Walk through the DtTimeoutMap, invoke DtSplitContentExpiredFcn for things needing to be purged.
Caller should pass a valid DtSplitContentExpiredFcn to pFcn, and (this) to pUsr. It's up to the caller to invoke removeTimeoutEntry(). Note, if timeNow is not >= myLastTimeoutCheckTime+myTimeoutCheckInterval, the call will be ignored.
returns true if entry found, with expiration time returned in retTime.
| DtTime DtSplitContentTimer::lastTimeoutCheckTime |
( |
| ) |
const |
|
inlinevirtual |
| void DtSplitContentTimer::setLastTimeoutCheckTime |
( |
DtTime |
nTime | ) |
|
|
inlinevirtual |
| DtTime DtSplitContentTimer::timeoutCheckInterval |
( |
| ) |
const |
|
inlinevirtual |
| void DtSplitContentTimer::setTimeoutCheckInterval |
( |
DtTime |
nSecs | ) |
|
|
inlinevirtual |
| DtTime DtSplitContentTimer::timeoutDuration |
( |
| ) |
const |
|
inlinevirtual |
time, in seconds, before an entry is considered expired.
References myTimeoutDuration.
| void DtSplitContentTimer::setTimeoutDuration |
( |
DtTime |
nSecs | ) |
|
|
inlinevirtual |
time, in seconds, before an entry is considered expired.
References myTimeoutDuration.
| virtual void DtSplitContentTimer::removeTimeoutEntry |
( |
const DtSplitMessageKey & |
key | ) |
|
|
virtual |
searches for an entry matching key, removes it.
Member Data Documentation
| DtTime DtSplitContentTimer::myLastTimeoutCheckTime |
|
protected |
| DtTime DtSplitContentTimer::myTimeoutCheckInterval |
|
protected |
| DtTime DtSplitContentTimer::myTimeoutDuration |
|
protected |
| const DtTime DtSplitContentTimer::theDefaultTimeoutCheckInterval |
|
staticprotected |
| const DtTime DtSplitContentTimer::theDefaultTimeoutDuration |
|
staticprotected |
The documentation for this class was generated from the following file: