1 /* |
|
2 * Copyright (c) 2007-2008 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: Login Request to the Network Server. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef _COSSPROTOCOLLOGINREQUEST_H_ |
|
21 #define _COSSPROTOCOLLOGINREQUEST_H_ |
|
22 |
|
23 // INCLUDES |
|
24 #include <e32base.h> |
|
25 #include <e32std.h> |
|
26 #include <ximpbase.h> |
|
27 |
|
28 #include "ossprotocloliterals.h" |
|
29 // FORWARD DECLARATIONS |
|
30 |
|
31 class MOSSProtocolConnectionManager; |
|
32 |
|
33 class COSSProtocolConnectionManager; |
|
34 |
|
35 |
|
36 const TInt KImpsMaxResourceIdLen = 64; // maximum Resource ID, this is not sure! |
|
37 |
|
38 /** |
|
39 * COSSProtocolLoginRequest |
|
40 * |
|
41 * Issue Login Request to the Network Server |
|
42 * |
|
43 * @lib ?library |
|
44 * @since S60 v4.0 |
|
45 */ |
|
46 NONSHARABLE_CLASS ( COSSProtocolLoginRequest ) : public CActive |
|
47 |
|
48 |
|
49 { |
|
50 |
|
51 public: |
|
52 |
|
53 static COSSProtocolLoginRequest* NewLC ( MOSSProtocolConnectionManager& aConnMan, |
|
54 TXIMPRequestId aRequestId ); |
|
55 static COSSProtocolLoginRequest* NewL ( MOSSProtocolConnectionManager& aConnMan, |
|
56 TXIMPRequestId aRequestId ); |
|
57 virtual ~COSSProtocolLoginRequest(); |
|
58 |
|
59 |
|
60 private: |
|
61 |
|
62 COSSProtocolLoginRequest ( MOSSProtocolConnectionManager& aConnMan, |
|
63 TXIMPRequestId aRequestId ); |
|
64 void ConstructL(); |
|
65 |
|
66 |
|
67 private: // from CActive |
|
68 |
|
69 void DoCancel(); |
|
70 /* |
|
71 * RunL() function also deletes the request object once the activity is done |
|
72 * |
|
73 */ |
|
74 void RunL(); |
|
75 TInt RunError ( TInt aError ); |
|
76 |
|
77 private: // new methods |
|
78 |
|
79 /** |
|
80 * Resource Id Generator |
|
81 * Leaves with KErrNotFound if no value |
|
82 * @return ResourceId |
|
83 */ |
|
84 TPtrC GenResourceId( const TDesC& aResourceId ); |
|
85 public: |
|
86 |
|
87 /** |
|
88 * Issue login request to the isolation server |
|
89 */ |
|
90 void IssueLoginRequestL(); |
|
91 |
|
92 |
|
93 private: // data |
|
94 |
|
95 /** |
|
96 * OWN:Request Id from PrFw |
|
97 */ |
|
98 TXIMPRequestId iRequestId; |
|
99 /** |
|
100 * Send data request to pure data handler generates the id |
|
101 */ |
|
102 TInt iSendId; |
|
103 /* OSS Protocol Plugin Connection Manager |
|
104 * Not own. |
|
105 */ |
|
106 MOSSProtocolConnectionManager& iConnMan; |
|
107 |
|
108 |
|
109 TBuf<KImpsMaxResourceIdLen> iResourceId; // Resource ID Implementation |
|
110 }; |
|
111 |
|
112 |
|
113 #endif // _COSSPROTOCOLLOGINREQUEST_H_ |
|
114 |
|