|
1 /* |
|
2 * Copyright (c) 2006 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: MsvEmailConnectionProgressProvider.h |
|
15 * |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 // Email Connection Related Utilities |
|
21 |
|
22 #ifndef __MSVEMAILCONNECTIONPROGRESSPROVIDER_H__ |
|
23 #define __MSVEMAILCONNECTIONPROGRESSPROVIDER_H__ |
|
24 |
|
25 #include <msvapi.h> |
|
26 #include <eikdialg.h> |
|
27 #include <ImumInternalApi.h> // CImumInternalApi |
|
28 #include "Imas.hrh" // For KImasPasswordLength, KImasImailServiceNameLength |
|
29 |
|
30 |
|
31 // |
|
32 // TMsvEmailConnectionProgress |
|
33 // |
|
34 // Email connection progress struct. |
|
35 // Provides additional state information on the connection, beyond that provided |
|
36 // by messaging GT components. |
|
37 // |
|
38 class TMsvEmailConnectionProgress |
|
39 { |
|
40 public: |
|
41 enum TConnectState |
|
42 { |
|
43 EInitialising, |
|
44 EConnectNetwork, |
|
45 EConnectMailbox |
|
46 }; |
|
47 public: |
|
48 TInt iType; |
|
49 TInt iErrorCode; |
|
50 TMsvId iService; |
|
51 TConnectState iState; |
|
52 TBuf<50> iName; |
|
53 }; |
|
54 |
|
55 |
|
56 // |
|
57 // CMsvEmailConnectionProgressProvider |
|
58 // |
|
59 // Provides progress for a connection. |
|
60 // Intended to be owned by a connection operation, such that it is destroyed, when no longer needed. |
|
61 // |
|
62 class CMsvEmailConnectionProgressProvider : public CBase |
|
63 { |
|
64 public: |
|
65 static CMsvEmailConnectionProgressProvider* NewL( |
|
66 const TDesC& aIapName, TMsvId aService); |
|
67 virtual ~CMsvEmailConnectionProgressProvider(); |
|
68 const TDesC8& GetConnectionProgressL(TInt aErrorCode=KErrNone); |
|
69 private: |
|
70 CMsvEmailConnectionProgressProvider(const TDesC& aIapName, |
|
71 TMsvId aService); |
|
72 private: |
|
73 // RGenericAgent iGenericAgent; |
|
74 TPckgBuf<TMsvEmailConnectionProgress> iProgressBuf; |
|
75 }; |
|
76 |
|
77 |
|
78 #endif // __MSVEMAILCONNECTIONPROGRESSPROVIDER_H__ |