Retail products


Traffic interception SDK

Control every TCP/IP network connection

  • Route connections via proxy
  • Redirect connections and modify the data
  • Block connections and applications
SSL interception SDK

View SSL in plaintext and modify it

  • View the SSL stream decrypted in plaintext
  • Redirect SSL connection and modify decrypted data
  • Browser shows "SSL lock" without warnings

Documentation


CWaitList Class Reference

#include <WaitList.h>

Collaboration diagram for CWaitList:

List of all members.


Public Member Functions

void Release ()
void SetAutoRelease (BOOL bRelease)
BOOL Wait (BOOL bWaitAll, DWORD &dwSignaledObject, unsigned long ulTimeout=INFINITE)
void AddObject (CWaitableObject *pObject, BOOL bNoRelease=FALSE)
CWaitListoperator<< (CWaitableObject *pObject)
 CWaitList ()
virtual ~CWaitList ()

Detailed Description

Definition at line 50 of file WaitList.h.


Constructor & Destructor Documentation

KOMODIA_NAMESPACE_START CWaitList::CWaitList (  ) 

Definition at line 51 of file WaitList.cpp.

00051                      : m_ulWaitCount(0),
00052                          m_bAutoRelease(FALSE),
00053                          m_ppRelease(NULL)
00054 {
00055 }

CWaitList::~CWaitList (  )  [virtual]

Definition at line 57 of file WaitList.cpp.

00058 {
00059     Release();
00060 }


Member Function Documentation

void CWaitList::AddObject ( CWaitableObject pObject,
BOOL  bNoRelease = FALSE 
)

Definition at line 105 of file WaitList.cpp.

00107 {
00108     if (m_ulWaitCount==MAXIMUM_WAIT_OBJECTS)
00109         return;
00110 
00111     //And put the object
00112     m_aHandles[m_ulWaitCount]=pObject->GetHandle();
00113     m_aObjects[m_ulWaitCount]=pObject;
00114     m_bRelease[m_ulWaitCount]=!bNoRelease;
00115 
00116     //Increase the count
00117     ++m_ulWaitCount;
00118 }

CWaitList & CWaitList::operator<< ( CWaitableObject pObject  ) 

Definition at line 120 of file WaitList.cpp.

00121 {
00122     //Add the data
00123     AddObject(pObject);
00124 
00125     //Done
00126     return *this;
00127 }

void CWaitList::Release (  ) 

Definition at line 179 of file WaitList.cpp.

00180 {
00181     if (m_ppRelease)
00182     {
00183         //Iterate it
00184         CWaitableObjectAutoRelease** ppBackup;
00185         ppBackup=m_ppRelease;
00186 
00187         while (*ppBackup)
00188         {
00189             //Delete the data
00190             delete *ppBackup;
00191 
00192             //Increase our position
00193             ++ppBackup;
00194         }
00195 
00196         //Delete it all
00197         delete [] m_ppRelease;
00198         m_ppRelease=NULL;
00199     }
00200 }

void CWaitList::SetAutoRelease ( BOOL  bRelease  ) 

Definition at line 129 of file WaitList.cpp.

00130 {
00131     m_bAutoRelease=bRelease;
00132 }

BOOL CWaitList::Wait ( BOOL  bWaitAll,
DWORD dwSignaledObject,
unsigned long  ulTimeout = INFINITE 
)

Definition at line 62 of file WaitList.cpp.

00065 {
00066     //Put invalid value in the signaled object
00067     dwSignaledObject=MAXIMUM_WAIT_OBJECTS;
00068 
00069     //Check we have objects
00070     if (!m_ulWaitCount)
00071         return FALSE;
00072     
00073     //And wait
00074     DWORD dwResult;
00075     dwResult=WaitForMultipleObjects(m_ulWaitCount,
00076                                     m_aHandles,
00077                                     bWaitAll,
00078                                     ulTimeout);
00079 
00080     //check why we exited
00081     if (dwResult==WAIT_TIMEOUT)
00082         return TRUE;
00083 
00084     //Check which object
00085     if (dwResult<=WAIT_OBJECT_0+m_ulWaitCount-1)
00086     {
00087         //Set the signaled object
00088         dwSignaledObject=dwResult-WAIT_OBJECT_0;
00089 
00090         //Do we need to build a list ?
00091         if (m_bAutoRelease)
00092             if (bWaitAll)
00093                 BuildAutoRelease(0);
00094             else
00095                 BuildAutoRelease(dwSignaledObject+1);
00096 
00097         //Exit
00098         return FALSE;
00099     }
00100 
00101     //Abandon stuff, don't need it
00102     return FALSE;
00103 }


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