| Public Types | |
| enum | TDriverState { EStateUnknown, EDriverLoaded, ELogicalChannelOpened, ESendingData, ELogicalChannelClosed, EDriverUnloaded } | 
| Public Member Functions | |
| ~CThreadServer () | |
| CSession2 * | NewSessionL (const TVersion &aVersion, const RMessage2 &aMessage) const | 
| void | IncrementRefCount () | 
| void | DecrementRefCount () | 
| TInt | LoadDevice () | 
| TInt | UnloadDevice () | 
| TInt | OpenLogicalChannel () | 
| void | CloseLogicalChannel () | 
| TInt | SendDataToDevice (TRequestStatus &aStatus, const TDesC8 &aData) | 
| void | CancelSendData () | 
| void | UpdateDriverState (TDriverState aState) | 
| Static Public Member Functions | |
| static IMPORT_C TInt | StartThread (TAny *aPointer) | 
| static void | NewLC () | 
Server interface for thread server.
Definition at line 46 of file threadserver.h.
Enumeration of the driver states.
Definition at line 52 of file threadserver.h.
| CThreadServer::~CThreadServer | ( | ) | 
Destructor. The device driver will be unloaded when the server destructor is called.
Destructor
Definition at line 65 of file threadserver.cpp.
| EXPORT_C TInt CThreadServer::StartThread | ( | TAny * | aPointer | ) |  [static] | 
Thread entry function.
Thread entry-point function. The ThreadServerStart object is passed as the thread parameter
Definition at line 39 of file threadserverstart.cpp.
| void CThreadServer::NewLC | ( | ) |  [static] | 
First and second phase constructor.
Starts two phase construction
Definition at line 42 of file threadserver.cpp.
| CSession2 * CThreadServer::NewSessionL | ( | const TVersion & | aVersion, | |
| const RMessage2 & | aMessage | |||
| ) | const | 
Create a server-side session object.
Create a new server-side session
| aVersion | Version argument | |
| aMessage | The message to process | 
Definition at line 81 of file threadserver.cpp.
| void CThreadServer::IncrementRefCount | ( | ) | 
Increase reference count and cancel shutdown timer. This function is called when a new session is created.
Increment the count of the number of clients connected
Definition at line 96 of file threadserver.cpp.
| void CThreadServer::DecrementRefCount | ( | ) | 
Decrease reference count and start shutdown timer. This function is called when a session is destroyed.
Decrement the count of the number of clients connected
Definition at line 104 of file threadserver.cpp.
| TInt CThreadServer::LoadDevice | ( | ) | 
Load device, including sample PDD and LDD.
Load both LDD and PDD
Definition at line 132 of file threadserver.cpp.
| TInt CThreadServer::UnloadDevice | ( | ) | 
Unload device, including sample LDD and PDD.
Unload both LDD and PDD
Definition at line 153 of file threadserver.cpp.
| TInt CThreadServer::OpenLogicalChannel | ( | ) | 
Open device logical channel.
Open LDD
Definition at line 179 of file threadserver.cpp.
| void CThreadServer::CloseLogicalChannel | ( | ) | 
| TInt CThreadServer::SendDataToDevice | ( | TRequestStatus & | aStatus, | |
| const TDesC8 & | aData | |||
| ) | 
Send data to device. It is an asynchronous request.
Send data to LDD device
| aStatus | ||
| aData | Data to be sent | 
Definition at line 207 of file threadserver.cpp.
| void CThreadServer::CancelSendData | ( | ) | 
Cancel send data operation to device driver.
Cancel sending data
Definition at line 224 of file threadserver.cpp.
| void CThreadServer::UpdateDriverState | ( | TDriverState | aState | ) | 
Update device state.
Update the states of the driver
| aState | State of the driver to be updated | 
Definition at line 233 of file threadserver.cpp.
 1.6.2
 1.6.2