|
S60 3rd Edition SDK for Symbian OS Example Applications Guide |
#include <SIPExSocketReader.h>
Public Member Functions | |
| ~CSIPExSocketReader () | |
| void | Read () |
Static Public Member Functions | |
| static CSIPExSocketReader * | NewL (RSocket &aSocket, MSIPExReaderNotifier &aNotifier) |
| static CSIPExSocketReader * | NewLC (RSocket &aSocket, MSIPExReaderNotifier &aNotifier) |
Protected Member Functions | |
| void | DoCancel () |
| void | RunL () |
Private Member Functions | |
| CSIPExSocketReader (RSocket &aSocket, MSIPExReaderNotifier &aNotifier) | |
| void | ConstructL () |
Private Attributes | |
| MSIPExReaderNotifier & | iNotifier |
| RSocket & | iSocket |
| TBuf8< 1 > | iBuffer |
| TBuf8< 256 > | iMessage |
Definition at line 29 of file SIPExSocketReader.h.
|
|
~CSIPExSocketReader Destructor Definition at line 70 of file SIPExSocketReader.cpp.
|
|
||||||||||||
|
CSIPExSocketReader Constructor
Definition at line 55 of file SIPExSocketReader.cpp. 00058 : CActive(CActive::EPriorityStandard), 00059 iNotifier( aNotifier ), 00060 iSocket( aSocket ) 00061 { 00062 CActiveScheduler::Add(this); 00063 }
|
|
||||||||||||
|
NewL Static constructor
Definition at line 26 of file SIPExSocketReader.cpp. References NewLC(). 00029 { 00030 CSIPExSocketReader* self = NewLC( aSocket, aNotifier ); 00031 CleanupStack::Pop(self); 00032 return self; 00033 }
|
|
||||||||||||
|
NewLC Static constructor. On return the instance is left to the CleanupStack.
Definition at line 40 of file SIPExSocketReader.cpp. References CSIPExSocketReader(). 00043 { 00044 CSIPExSocketReader* self = new (ELeave) CSIPExSocketReader( aSocket, aNotifier ); 00045 CleanupStack::PushL(self); 00046 self->ConstructL(); 00047 return self; 00048 }
|
|
|
Read Asynchronous function. Starts the asynchronous reading. Definition at line 127 of file SIPExSocketReader.cpp. 00128 { 00129 if( !IsActive() ) 00130 { 00131 iSocket.Read( iBuffer, iStatus ); 00132 SetActive(); 00133 } 00134 }
|
|
|
From CActive Definition at line 89 of file SIPExSocketReader.cpp. References iSocket. 00090 { 00091 iSocket.CancelRead(); 00092 }
|
|
|
From CActive Definition at line 100 of file SIPExSocketReader.cpp. References iBuffer, iMessage, iNotifier, and MSIPExReaderNotifier::MessageReceived(). 00101 { 00102 if( iStatus.Int() == KErrNone ) 00103 { 00104 iMessage.Append( iBuffer ); 00105 iBuffer.Zero(); 00106 if( iMessage.Length() == 4 ) 00107 { 00108 iNotifier.MessageReceived( iMessage ); 00109 iMessage.Zero(); 00110 } 00111 Read(); 00112 } 00113 else 00114 { 00115 iMessage.FillZ(); 00116 iMessage.Zero(); 00117 iNotifier.ErrorInReading( iStatus.Int() ); 00118 } 00119 }
|
|
|
ConstructL Symbian 2nd phase constructor that might leave Definition at line 80 of file SIPExSocketReader.cpp.
|
|
© Nokia 2006 |