|
1 /* |
|
2 * Copyright (c) 2007 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 "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: Engine for content harvester server |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef C_CONTENTHARVESTERSESSION_H |
|
20 #define C_CONTENTHARVESTERSESSION_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32base.h> |
|
24 |
|
25 // FORWARD DECLARATIONS |
|
26 class CContentHarvesterServer; |
|
27 |
|
28 // CLASS DECLARATION |
|
29 |
|
30 /** |
|
31 An instance of class CContentHarvesterSession is created for each client |
|
32 */ |
|
33 class CContentHarvesterSession : public CSession2 |
|
34 { |
|
35 |
|
36 public: |
|
37 // New methods |
|
38 |
|
39 /** |
|
40 * Create a CContentHarvesterSession object using two phase construction, |
|
41 * and return a pointer to the created object |
|
42 * @param aServer CContentHarvesterServer |
|
43 * @return pointer to new session |
|
44 */ |
|
45 static CContentHarvesterSession* NewL( CContentHarvesterServer* aServer ); |
|
46 |
|
47 /** |
|
48 * Create a CContentHarvesterSession object using two phase construction, |
|
49 * and return a pointer to the created object |
|
50 * @param aServer CContentHarvesterServer |
|
51 * @return pointer to new session |
|
52 */ |
|
53 static CContentHarvesterSession* NewLC( CContentHarvesterServer* aServer ); |
|
54 |
|
55 /** |
|
56 * Destroy the object and release all memory objects |
|
57 */ |
|
58 virtual ~CContentHarvesterSession(); |
|
59 |
|
60 public: |
|
61 // From CSession |
|
62 /** |
|
63 * Called after a service request from client; from class CSession |
|
64 * @param aMessage message from client (containing requested operation and any data) |
|
65 */ |
|
66 void ServiceL( const RMessage2& aMessage ); |
|
67 |
|
68 private: |
|
69 // New methods |
|
70 |
|
71 /** |
|
72 * Perform the first phase of two phase construction |
|
73 * @param aServer CContentHarvesterServer |
|
74 */ |
|
75 CContentHarvesterSession( CContentHarvesterServer* aServer ); |
|
76 |
|
77 /** |
|
78 * Perform the second phase construction of a CContentHarvesterSession object |
|
79 */ |
|
80 void ConstructL(); |
|
81 |
|
82 private: |
|
83 |
|
84 /** |
|
85 * CP Active Data Server container |
|
86 * Own. |
|
87 */ |
|
88 CContentHarvesterServer* iContentHarvesterServer; |
|
89 }; |
|
90 |
|
91 #endif // C_CONTENTHARVESTERSESSION_H |