Case 1:
If you have saved: a:04165191666, b:5191666, the call number is: 04165191666
Because it is a 7-bit match, both A and B can match, but the best match is a, and the last shows A;
Call 5191666 is matched to B.
Case 2:
Save a:04165191666 only,
Call 5191666 or 04165191666 matches a.
Case 3:
Save b:5191666 only,
The call 5191666 or 04165191666 matches B.
On the basis of 7 match, the matching number match can be further filtered.
First, you need to modify the Min_match to 7-bit matching, please modify the following two files to ensure that return Min_match are 7
"Bfore KK1"
(1). Modify OldPhoneNumberUtils.cpp (alps\external\sqlite\android), Getminmatch () return value
2, Phonenumberutils.java (Alps\frameworks\base\telephony\java\android\telephony) in the Min_match;
"After KK1"
(1). Modify OldPhoneNumberUtils.cpp (alps\external\sqlite\android), Getminmatch () return value
(2). Modify the Phonenumberext.java (Mediatek\frameworks\base\op\java\com\mediatek\op\telephony) in the
Getminmatch () return value
In addition, please modify the Dialersearchutils.java (alps\packages\providers\contactsprovider\src\com\android\providers\contacts) in the
public static cursor findnumberexactmatchedcursor (cursor cursor, String normalizednumber) method
Here's a description:
This method is based on the number matching, then filters the exact number and returns
Input parameters:
The cursor is the data returned after all 7-bit matches, followed by an exact match from the face.
Normalizednumber is the number used by Call/mms
Output:
If the return is already matched, the
Matrixcursor exactcursor = matrixcursorfromcursorrow (cursor, cursor.getposition ());
Cursor.close ();
return exactcursor;
If there is no match, then
return null;
Two other numbers, please explain:
Normalizednumber is the number used by Call/mms
Data1 is the full number found in the database.
Android phone Thin first 10-bit match, if not match, then replaced by 7-bit match