|
1 /* |
|
2 * Copyright (c) 2005-2007 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: Phonebook 2 store info item. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef CPBK2STOREINFOITEM_H |
|
20 #define CPBK2STOREINFOITEM_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32base.h> |
|
24 #include <bamdesca.h> |
|
25 #include <Pbk2StoreInfo.hrh> |
|
26 |
|
27 // FORWARD DECLARATIONS |
|
28 class TResourceReader; |
|
29 |
|
30 // CLASS DECLARATION |
|
31 |
|
32 /** |
|
33 * Phonebook 2 store info item. |
|
34 */ |
|
35 NONSHARABLE_CLASS(CPbk2StoreInfoItem) : public CBase |
|
36 { |
|
37 public: // Constructors and destructor |
|
38 |
|
39 /** |
|
40 * Creates a new instance of this class. |
|
41 * |
|
42 * @param aReader A resource reader pointed to a |
|
43 * PHONEBOOK2_STORE_INFO_ITEM resource. |
|
44 * @return A new instance of this class. |
|
45 */ |
|
46 IMPORT_C static CPbk2StoreInfoItem* NewLC( |
|
47 TResourceReader& aReader ); |
|
48 |
|
49 /** |
|
50 * Destructor. |
|
51 */ |
|
52 virtual ~CPbk2StoreInfoItem(); |
|
53 |
|
54 public: // Interface |
|
55 |
|
56 /** |
|
57 * Returns the type of the item that is the link |
|
58 * to the function in Virtual Phonebook store info interface. |
|
59 * |
|
60 * @return Type of the item. |
|
61 */ |
|
62 IMPORT_C TInt ItemType() const; |
|
63 |
|
64 /** |
|
65 * Returns the item text. |
|
66 * |
|
67 * @return Item text or KNullDesC. |
|
68 */ |
|
69 IMPORT_C const TDesC& ItemTextSingular() const; |
|
70 |
|
71 /** |
|
72 * Returns the item text in plural form. |
|
73 * |
|
74 * @return Item text in plural form or KNullDesC. |
|
75 */ |
|
76 IMPORT_C const TDesC& ItemTextPlural() const; |
|
77 |
|
78 /** |
|
79 * Returns the item text type. |
|
80 * |
|
81 * @return Item text type. |
|
82 */ |
|
83 IMPORT_C TPbk2StoreInfoItemTextType TextType() const; |
|
84 |
|
85 /** |
|
86 * Returns item flags. |
|
87 * |
|
88 * @see Pbk2StoreProperty.hrh. |
|
89 * @return Item flags. |
|
90 */ |
|
91 IMPORT_C TUint32 Flags() const; |
|
92 |
|
93 private: // Implementation |
|
94 CPbk2StoreInfoItem(); |
|
95 void ConstructL( |
|
96 TResourceReader& aReader ); |
|
97 |
|
98 private: // Data |
|
99 /// Own: Info item type |
|
100 TInt iItemType; |
|
101 /// Own: Item text |
|
102 HBufC* iItemTextSingular; |
|
103 /// Own: Item text in plural form |
|
104 HBufC* iItemTextPlural; |
|
105 /// Own: Info item text type |
|
106 TPbk2StoreInfoItemTextType iTextType; |
|
107 /// Own: Flags |
|
108 TUint32 iFlags; |
|
109 }; |
|
110 |
|
111 #endif // CPBK2STOREINFOITEM_H |
|
112 |
|
113 // End of File |