|
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: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef C_HNMDBOOLEANKEY_H |
|
21 #define C_HNMDBOOLEANKEY_H |
|
22 |
|
23 #include <e32base.h> |
|
24 |
|
25 #include "hnmdbasekey.h" |
|
26 |
|
27 /** |
|
28 * Defines particular key type which is bool. |
|
29 * |
|
30 * @lib hierarchynavigatorengine |
|
31 * @since S60 v5.0 |
|
32 * @ingroup group_hnutilities |
|
33 */ |
|
34 NONSHARABLE_CLASS( CHnMdBooleanKey ) : public CHnMdBaseKey |
|
35 { |
|
36 friend class HnMdKeyFactory; |
|
37 |
|
38 public: |
|
39 |
|
40 /** |
|
41 * Standard factory method. |
|
42 * |
|
43 * @return Fully constructed object. |
|
44 */ |
|
45 static CHnMdBooleanKey* NewL(); |
|
46 |
|
47 /** |
|
48 * Standard factory method. |
|
49 * |
|
50 * @return Fully constructed object. |
|
51 */ |
|
52 static CHnMdBooleanKey* NewLC(); |
|
53 |
|
54 /** |
|
55 * Standard factory method. |
|
56 * |
|
57 * @param aKey Reference key. |
|
58 * @return Fully constructed object. |
|
59 */ |
|
60 static CHnMdBooleanKey* NewL( const CHnMdBooleanKey* aKey ); |
|
61 |
|
62 /** |
|
63 * Standard factory method. |
|
64 * |
|
65 * @param aKey Reference key. |
|
66 * @return Fully constructed object. |
|
67 */ |
|
68 static CHnMdBooleanKey* NewLC( const CHnMdBooleanKey* aKey ); |
|
69 |
|
70 /** |
|
71 * Standard destructor. |
|
72 */ |
|
73 virtual ~CHnMdBooleanKey(); |
|
74 |
|
75 /** |
|
76 * Gets key boolean value. |
|
77 * |
|
78 * @since S60 v5.0 |
|
79 * @return Boolean value represented by the key. |
|
80 */ |
|
81 TBool GetBooleanValueL() const;//Only in CHnMdBooleanKey |
|
82 |
|
83 // from base class CHnMdBaseKey |
|
84 |
|
85 /** |
|
86 * Factory method. |
|
87 * |
|
88 * since S60 v5.0 |
|
89 * @return Fully constructed object. |
|
90 */ |
|
91 virtual CHnMdBaseKey* CopyLC(); |
|
92 |
|
93 /** |
|
94 * Change to variant. |
|
95 * |
|
96 * @since S60 v5.0 |
|
97 * @param aRet Output variant. |
|
98 * |
|
99 */ |
|
100 virtual void ToVariantL( TLiwVariant& aRet ) const; |
|
101 |
|
102 |
|
103 protected: |
|
104 |
|
105 /** |
|
106 * Standard constructor. |
|
107 * |
|
108 * @since S60 v5.0 |
|
109 */ |
|
110 CHnMdBooleanKey(); |
|
111 |
|
112 /** |
|
113 * Symbian constructor for performing 2nd stage construction. |
|
114 * |
|
115 * @since S60 v5.0 |
|
116 */ |
|
117 void ConstructL(); |
|
118 |
|
119 /** |
|
120 * Symbian constructor for performing 2nd stage construction. |
|
121 * |
|
122 * @since S60 v5.0 |
|
123 * @param aKey Reference key. |
|
124 */ |
|
125 void ConstructL( const CHnMdBooleanKey* aKey ); |
|
126 |
|
127 }; |
|
128 |
|
129 #endif // C_HNMDBOOLEANKEY_H |