19 #define PBK2ADDRESSTOOLS_H |
19 #define PBK2ADDRESSTOOLS_H |
20 |
20 |
21 #include "TPbk2ContactEditorParams.h" |
21 #include "TPbk2ContactEditorParams.h" |
22 #include <Pbk2FieldProperty.hrh> |
22 #include <Pbk2FieldProperty.hrh> |
23 #include <VPbkFieldType.hrh> |
23 #include <VPbkFieldType.hrh> |
|
24 #include <MVPbkFieldType.h> |
24 #include <e32hashtab.h> |
25 #include <e32hashtab.h> |
25 |
26 |
26 class MVPbkStoreContact; |
27 class MVPbkStoreContact; |
27 |
28 |
28 class Pbk2AddressTools |
29 class Pbk2AddressTools |
111 */ |
112 */ |
112 IMPORT_C static void GetAddressShortPreviewLC( |
113 IMPORT_C static void GetAddressShortPreviewLC( |
113 MVPbkStoreContact& aContact, |
114 MVPbkStoreContact& aContact, |
114 TPbk2FieldGroupId aAddressGroup, |
115 TPbk2FieldGroupId aAddressGroup, |
115 RBuf& aText ); |
116 RBuf& aText ); |
|
117 |
|
118 /** |
|
119 * Maps VPbkFieldType to field group |
|
120 * |
|
121 * @param aVPbkFieldType Type of virtual phonebook field type |
|
122 * @return Suitable group id ( TPbk2FieldGroupId ) |
|
123 */ |
|
124 IMPORT_C static TPbk2FieldGroupId MapVPbkFieldTypeToAddressGroupId( |
|
125 const MVPbkFieldType* aVPbkFieldType ); |
|
126 |
|
127 /** |
|
128 * Judge whether the address preview of one contact is empty |
|
129 * Address preview include the following four fields: |
|
130 * EVPbkVersitSubFieldStreet, EVPbkVersitSubFieldLocality, |
|
131 * EVPbkVersitSubFieldRegion and EVPbkVersitSubFieldCountry. |
|
132 * If the four fields are all empty, return ETrue; Otherwise, return EFalse. |
|
133 * |
|
134 * @param aContact contact |
|
135 * @param aAddressGroup field group |
|
136 * @return If address preview is empty, return ETrue; Otherwiase, EFalse |
|
137 */ |
|
138 IMPORT_C static TBool IsAddressPreviewEmptyL( |
|
139 MVPbkStoreContact& aContact, |
|
140 TPbk2FieldGroupId aAddressGroup ); |
116 }; |
141 }; |
117 |
142 |
118 #endif // PBK2ADDRESSTOOLS_H |
143 #endif // PBK2ADDRESSTOOLS_H |
119 |
144 |
120 // End of File |
145 // End of File |