equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of the License "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 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * testutil - server classes |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 /** |
|
23 @file |
|
24 @test |
|
25 @internalComponent |
|
26 */ |
|
27 |
|
28 #include <e32base.h> |
|
29 #include <f32file.h> |
|
30 #include "testutilssessioncommon.h" |
|
31 |
|
32 class CTestUtilServer : public CServer2 |
|
33 { |
|
34 public: |
|
35 static CServer2* NewLC(); |
|
36 virtual ~CTestUtilServer(); |
|
37 void AddSession(); |
|
38 void DropSession(); |
|
39 void Send(const TDesC& aMessage); |
|
40 inline RFs& FS(); |
|
41 inline CFileMan& FileMan(); |
|
42 private: |
|
43 CTestUtilServer(); |
|
44 void ConstructL(); |
|
45 CSession2* NewSessionL(const TVersion& aVersion, const RMessage2& aMessage) const; |
|
46 private: |
|
47 TInt iSessionCount; |
|
48 RFs iFs; |
|
49 CFileMan* iFileMan; |
|
50 CTestUtilSessionCommon* iTestUtilSessionCommon; |
|
51 }; |
|
52 |
|
53 // CTestUtilServer inlines |
|
54 inline CTestUtilServer::CTestUtilServer() |
|
55 :CServer2(0,ESharableSessions) |
|
56 {} |
|
57 |
|
58 inline RFs& CTestUtilServer::FS() |
|
59 { |
|
60 return iFs; |
|
61 } |
|
62 |
|
63 inline CFileMan& CTestUtilServer::FileMan() |
|
64 { |
|
65 return *iFileMan; |
|
66 } |