|
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 "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: It is parser for emergency numbers. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef CPHONEGSMEMERGENCYNUMBERPARSER_H |
|
20 #define CPHONEGSMEMERGENCYNUMBERPARSER_H |
|
21 |
|
22 // INCLUDES |
|
23 #include "CPhoneGsmParserBase.h" |
|
24 #include <PhCltTypes.h> |
|
25 |
|
26 // FORWARD DECLARATIONS |
|
27 class CPhoneGsmOptionContainer; |
|
28 |
|
29 // CONSTANTS |
|
30 |
|
31 /* |
|
32 * EMERGENCY NUMBER UIDS |
|
33 */ |
|
34 const TUint32 KPhoneUidEmergencyNumber = |
|
35 PHONE_MAKE_UID( KPhoneGsmUidDialEmergencyNumber, 0 ); |
|
36 |
|
37 // CLASS DECLARATION |
|
38 |
|
39 /** |
|
40 * It is parser for emergency numbers. |
|
41 * |
|
42 * @since S60 5.0 |
|
43 * @lib phoneparser.lib |
|
44 */ |
|
45 NONSHARABLE_CLASS( CPhoneGsmEmergencyNumberParser ) |
|
46 : public CPhoneGsmParserBase |
|
47 { |
|
48 public: // Constructors and destructor |
|
49 |
|
50 /** |
|
51 * Two-phased constructor. |
|
52 */ |
|
53 static CPhoneGsmEmergencyNumberParser* NewLC(); |
|
54 |
|
55 public: // Functions from base classes |
|
56 |
|
57 /** |
|
58 * From CPhoneGsmParserBase. |
|
59 * Parse string. |
|
60 * |
|
61 * @param aString It is string to be parsed. |
|
62 * @param aResult It will contain result. |
|
63 * @param aOptions It indicates operation options. |
|
64 * @return It returns boolean value indicating success of parsing. |
|
65 */ |
|
66 TBool ParseL( |
|
67 const TDesC& aString, |
|
68 CPhoneGsmParserResult& aResult, |
|
69 CPhoneGsmOptionContainerBase& aOptions ); |
|
70 |
|
71 private: |
|
72 |
|
73 /** |
|
74 * C++ default constructor. |
|
75 */ |
|
76 CPhoneGsmEmergencyNumberParser(); |
|
77 |
|
78 /** |
|
79 * Parse. |
|
80 */ |
|
81 TBool DoParseL( |
|
82 const TDesC& aString, |
|
83 CPhoneGsmParserResult& aResult, |
|
84 CPhoneGsmOptionContainer& aOptions ); |
|
85 |
|
86 private: // Data |
|
87 |
|
88 // Emergency number. |
|
89 TPhCltTelephoneNumber iEmergencyPhoneNumber; |
|
90 |
|
91 }; |
|
92 |
|
93 #endif // CPHONEGSMEMERGENCYNUMBERPARSER_H |
|
94 |
|
95 // End of File |