689 User::LeaveIfError( plugin.GetRemotePartyName( aRemotePartyName ) ); |
689 User::LeaveIfError( plugin.GetRemotePartyName( aRemotePartyName ) ); |
690 |
690 |
691 RBuf parsedAddress; |
691 RBuf parsedAddress; |
692 CleanupClosePushL( parsedAddress ); |
692 CleanupClosePushL( parsedAddress ); |
693 TInt digitsformatching( 0 ); |
693 TInt digitsformatching( 0 ); |
694 TBool allowUserNameMatch( EFalse ); |
694 User::LeaveIfError( plugin.GetAddressForMatching( parsedAddress, digitsformatching ) ); |
695 User::LeaveIfError( plugin.GetAddressForMatching( |
695 |
696 parsedAddress, digitsformatching, allowUserNameMatch ) ); |
|
697 |
|
698 CDesCArray* array = new ( ELeave ) CDesC16ArrayFlat( 1 ); |
696 CDesCArray* array = new ( ELeave ) CDesC16ArrayFlat( 1 ); |
699 CleanupStack::PushL( array ); |
697 CleanupStack::PushL( array ); |
700 User::LeaveIfError( plugin.GetContactStoreUris( *array ) ); |
698 User::LeaveIfError( plugin.GetContactStoreUris( *array ) ); |
701 |
699 |
702 TEFLOGSTRING2( KTAINT, "CNT Extension Plugin > remoteParty: %S", &aRemotePartyName ) |
700 TEFLOGSTRING2( KTAINT, "CNT Extension Plugin > remoteParty: %S", &aRemotePartyName ) |
704 &parsedAddress, digitsformatching ) |
702 &parsedAddress, digitsformatching ) |
705 TEFLOGSTRING2( KTAINT, "CNT Extension Plugin > array count: %d", array->MdcaCount() ) |
703 TEFLOGSTRING2( KTAINT, "CNT Extension Plugin > array count: %d", array->MdcaCount() ) |
706 |
704 |
707 // Digits for matching. Supported range is between 4-20. |
705 // Digits for matching. Supported range is between 4-20. |
708 // If not valid value use whole address length for matching. |
706 // If not valid value use whole address length for matching. |
709 if ( digitsformatching != 0 && |
707 digitsformatching = ( digitsformatching < KMinValueOfMeaningfulDigits || |
710 ( digitsformatching < KMinValueOfMeaningfulDigits || |
708 digitsformatching > KMaxValueOfMeaningfulDigits ) ? |
711 digitsformatching > KMaxValueOfMeaningfulDigits ) ) |
709 parsedAddress.Length() : digitsformatching; |
712 { |
710 |
713 digitsformatching = parsedAddress.Length(); |
|
714 } |
|
715 |
|
716 // Use service specific parameters for matching. |
711 // Use service specific parameters for matching. |
717 TEFLOGSTRING3( KTAINT, "CNT MatchWithVoipAddressUsingExtensionL >\ |
712 TEFLOGSTRING3( KTAINT, "CNT MatchWithVoipAddressUsingExtensionL >\ |
718 CPhCntMatcher::MatchVoipNumber, NUMBER: %S, CALL ID: %d", |
713 CPhCntMatcher::MatchVoipNumber, NUMBER: %S, CALL ID: %d", |
719 &remoteNumber, aCallId ) |
714 &remoteNumber, aCallId ) |
720 iContactMatcher->MatchVoipNumber( aMatch, |
715 iContactMatcher->MatchVoipNumber( aMatch, |
721 parsedAddress.Left( Min( parsedAddress.Length(), KPEPhoneNumberMaxLength ) ), |
716 parsedAddress.Left( Min( parsedAddress.Length(), KPEPhoneNumberMaxLength ) ), |
722 allowUserNameMatch, array, digitsformatching ); |
717 ETrue, array, digitsformatching ); |
723 |
718 |
724 CleanupStack::PopAndDestroy( array ); |
719 CleanupStack::PopAndDestroy( array ); |
725 CleanupStack::PopAndDestroy( &parsedAddress ); |
720 CleanupStack::PopAndDestroy( &parsedAddress ); |
726 } |
721 } |
727 |
722 |