|
1 /* |
|
2 * Copyright (c) 2003 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: Etel references |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef ETELAPDU_H |
|
21 #define ETELAPDU_H |
|
22 |
|
23 // INCLUDES |
|
24 #include <rmmcustomapi.h> // For CustomAPI services |
|
25 |
|
26 // CONSTANTS |
|
27 // For logging |
|
28 #ifdef _DEBUG |
|
29 _LIT( KSwimReaderLogDir, "Scard" ); |
|
30 _LIT( KSwimReaderLogFileName, "Log.txt" ); |
|
31 #endif |
|
32 |
|
33 // FORWARD DECLARATIONS |
|
34 class RTelServer; |
|
35 |
|
36 |
|
37 // CLASS DECLARATION |
|
38 |
|
39 /** |
|
40 * Functionality to send Apdus through Etel |
|
41 * |
|
42 * |
|
43 * @lib SwimReader.lib |
|
44 * @since Series60 2.1 |
|
45 */ |
|
46 class RApdu : public RTelSubSessionBase |
|
47 { |
|
48 public: // Constructors and destructor |
|
49 |
|
50 /** |
|
51 * C++ default constructor. |
|
52 */ |
|
53 RApdu(); |
|
54 |
|
55 public: // New functions |
|
56 |
|
57 /** |
|
58 * Open Etel connection |
|
59 * @param aSession RTelServer session |
|
60 * @param aName Name of the phone |
|
61 * @return S60 error code |
|
62 */ |
|
63 TInt Open( RTelServer& aSession, const TDesC& aName ); |
|
64 |
|
65 /** |
|
66 * Close connection to Etel server |
|
67 * @return void |
|
68 */ |
|
69 void Close(); |
|
70 |
|
71 /** |
|
72 * Transmit message through Etel (via CustomAPI) |
|
73 * @param aStatus Request's status |
|
74 * @param aMsg Message to be transmitted |
|
75 * @return void |
|
76 */ |
|
77 void APDUReq( TRequestStatus& aStatus, RMmCustomAPI::TApdu& aMsg ); |
|
78 |
|
79 /** |
|
80 * Cancel transmit message through Etel (via CustomAPI) |
|
81 * @return void |
|
82 */ |
|
83 void CancelAPDUReq(); |
|
84 |
|
85 private: |
|
86 |
|
87 /** |
|
88 * Symbian 2nd phase constructor |
|
89 */ |
|
90 void ConstructL(); |
|
91 |
|
92 /** |
|
93 * Destruct |
|
94 * @return void |
|
95 */ |
|
96 void Destruct(); |
|
97 |
|
98 private: // Data |
|
99 //pointer to customAPI instance. Owned. |
|
100 RMmCustomAPI* iCustomApi; |
|
101 RMobilePhone iPhone; |
|
102 }; |
|
103 |
|
104 #endif // ETELAPDU_H |
|
105 |
|
106 // End of File |