reSIProcate/DialogUsageManager  9694
Public Member Functions | Protected Attributes
RemoveIfRequired Class Reference
Collaboration diagram for RemoveIfRequired:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 RemoveIfRequired (UInt64 &now, unsigned int removeLingerSecs)
bool operator() (const ContactInstanceRecord &rec)
bool mustRemove (const ContactInstanceRecord &rec)

Protected Attributes

UInt64 mNow
unsigned int mRemoveLingerSecs

Detailed Description

Definition at line 10 of file InMemorySyncRegDb.cxx.


Constructor & Destructor Documentation

RemoveIfRequired::RemoveIfRequired ( UInt64 now,
unsigned int  removeLingerSecs 
) [inline]

Definition at line 16 of file InMemorySyncRegDb.cxx.

                                                                 :
       mNow(now),
       mRemoveLingerSecs(removeLingerSecs) {}

Member Function Documentation

bool RemoveIfRequired::mustRemove ( const ContactInstanceRecord rec) [inline]

Definition at line 23 of file InMemorySyncRegDb.cxx.

References DebugLog, resip::ContactInstanceRecord::mContact, resip::ContactInstanceRecord::mLastUpdated, and resip::ContactInstanceRecord::mRegExpires.

Referenced by contactsRemoveIfRequired().

    {
       if((rec.mRegExpires <= mNow) && ((mNow - rec.mLastUpdated) > mRemoveLingerSecs)) 
       {
          DebugLog(<< "ContactInstanceRecord removed after linger: " << rec.mContact);
          return true;
       }
      return false;
    }
bool RemoveIfRequired::operator() ( const ContactInstanceRecord rec) [inline]

Definition at line 19 of file InMemorySyncRegDb.cxx.

    {
       return mustRemove(rec);
    }

Member Data Documentation

Definition at line 13 of file InMemorySyncRegDb.cxx.

unsigned int RemoveIfRequired::mRemoveLingerSecs [protected]

Definition at line 14 of file InMemorySyncRegDb.cxx.


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