114 // Creates contact match strategy. |
114 // Creates contact match strategy. |
115 // --------------------------------------------------------------------------- |
115 // --------------------------------------------------------------------------- |
116 // |
116 // |
117 MPhCntContactMatchStrategy* CPhCntContactManager::CreateContactMatchStrategyL( |
117 MPhCntContactMatchStrategy* CPhCntContactManager::CreateContactMatchStrategyL( |
118 MVPbkContactFindObserver& aObserver, |
118 MVPbkContactFindObserver& aObserver, |
119 TDuplicateRemovalStrategy aStrategy ) |
119 TDuplicateRemovalStrategy aRemoveDuplicatesStrategy ) |
120 { |
120 { |
121 const TUint32 removeDuplicatesStrategyFlag = |
121 |
122 CVPbkPhoneNumberMatchStrategy::EVPbkDuplicatedContactsMatchFlag | |
|
123 CVPbkPhoneNumberMatchStrategy::EVPbkBestMatchingFlag; |
|
124 const TUint32 dontRemoveDuplicatesStrategyFlag = |
|
125 CVPbkPhoneNumberMatchStrategy::EVPbkBestMatchingFlag; |
|
126 |
|
127 return CPhCntContactMatchStrategy::NewL( |
122 return CPhCntContactMatchStrategy::NewL( |
128 *iContactManager, |
123 *iContactManager, |
129 *iContactStoreUris, |
124 *iContactStoreUris, |
130 aObserver, |
125 aObserver, |
131 aStrategy == ERemoveDuplicates ? |
126 aRemoveDuplicatesStrategy ); |
132 removeDuplicatesStrategyFlag : dontRemoveDuplicatesStrategyFlag ); |
|
133 } |
127 } |
134 |
128 |
135 // --------------------------------------------------------------------------- |
129 // --------------------------------------------------------------------------- |
136 // From MPhCntContactManager |
130 // From MPhCntContactManager |
137 // Converts contact ids to contact links. |
131 // Converts contact ids to contact links. |