libraries/iosrv/server/session.h
changeset 0 7f656887cf89
equal deleted inserted replaced
-1:000000000000 0:7f656887cf89
       
     1 // session.h
       
     2 // 
       
     3 // Copyright (c) 2006 - 2010 Accenture. All rights reserved.
       
     4 // This component and the accompanying materials are made available
       
     5 // under the terms of the "Eclipse Public License v1.0"
       
     6 // which accompanies this distribution, and is available
       
     7 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 // 
       
     9 // Initial Contributors:
       
    10 // Accenture - Initial contribution
       
    11 //
       
    12 
       
    13 #ifndef __SESSION_H__
       
    14 #define __SESSION_H__
       
    15 
       
    16 #include <e32base.h>
       
    17 #include "readwrite.h"
       
    18 
       
    19 class CIoServer;
       
    20 
       
    21 #ifdef EKA2
       
    22 class CIoSession : public CSession2
       
    23 #else
       
    24 class CIoSession : public CSharableSession
       
    25 #endif
       
    26 	{
       
    27 public:
       
    28 	CIoSession();
       
    29 #ifdef EKA2
       
    30 	void CreateL();
       
    31 #else
       
    32 	void CreateL(const CServer& aServer);
       
    33 #endif
       
    34 private:
       
    35 	~CIoSession();
       
    36 	CIoServer& Server();
       
    37 	void ServiceL(const RMsg& aMessage);
       
    38 	void CreateHandleL(CObject& aObject, TBool aDoPop, const RMsg& aMessage);
       
    39 	CIoObject& FindObjectL(TInt aHandle);
       
    40 	CIoEndPoint& FindEndPointL(TInt aHandle, const RMsg& aMessage);
       
    41 	CIoPipe& FindPipeL(TInt aHandle, const RMsg& aMessage);
       
    42 	CIoConsole& FindConsoleL(TInt aHandle, const RMsg& aMessage);
       
    43 	CIoPersistentConsole& FindPersistentConsoleL(TInt aHandle, const RMsg& aMessage);
       
    44 	CIoReadWriteObject& FindReadWriteObjectL(TInt aHandle, const RMsg& aMessage);
       
    45 	CIoReadObject& FindReadObjectL(TInt aHandle, const RMsg& aMessage);
       
    46 	CIoWriteObject& FindWriteObjectL(TInt aHandle, const RMsg& aMessage);
       
    47 	void Complete(const RMsg& aMessage, TInt aError);
       
    48 	
       
    49 private:
       
    50 	CObjectIx* iHandles;
       
    51 #ifdef IOSRV_LOGGING
       
    52 	TName iName;
       
    53 #endif
       
    54 	RIoHandle::TType iFindByNameType;
       
    55 	TInt iFindByNameHandle;
       
    56 	HBufC* iFindByNameMatch;
       
    57 	};
       
    58 
       
    59 #endif // __SESSION_H__