OSDN Git Service

Addition of 'XorEqualsString' method for comparing String
authoryoonjeong Jang <yjeong.jang@samsung.com>
Mon, 28 Oct 2019 05:40:01 +0000 (14:40 +0900)
committeryoonjeong Jang <yjeong.jang@samsung.com>
Tue, 29 Oct 2019 04:00:28 +0000 (13:00 +0900)
commitbc97964aad6cdaad92336a64684058cb780a6896
treeb54fc791a887bf79d1d325b6b8d6b9bdf16bd9c1
parentfde6b837f94210ecb1161e12c2559025c8493971
Addition of 'XorEqualsString' method for comparing String

Previously, ApnSetting compared two APNs using String with 'XorEqual' method
and the result of it used for 'dedupeApnSettings' for DcTracker.
For instance, a MMS APN for the specific operator shall be merged with
the default(Internet) APN of the same operator's(mccmnc) APN once the result of 'similar' is true.
But recently, it didn't merge two similar APNs properly due to 'UNSPECIFIED_STRING' case.
So we've added XorEquals for String(XorEqualsString) case.

The Issue will happen in the circumstance below.
 1.A network operator's similar APNs are saved separately at the APN database(apns-conf.xml)
    For instance, Add two APNs like below and check the result of merging APNs at DcTracker.
        <apn carrier="SKT LTE INTERNET"
          mcc="450"
          mnc="05"
          apn="lte.sktelecom.com"
          type="default,supl,fota,cbs"
          protocol="IPV4V6"
         />
        <apn carrier="SKT LTE INTERNET"
          mcc="450"
          mnc="05"
          apn="lte.sktelecom.com"
          type="mms"
          mmsc="http://omms.nate.com:9082/oma_mms"
          mmsproxy="smart.nate.com"
          mmsport="9093"
          protocol="IPV4V6"
         />:q
 2. Two similar APNs shall be merged on the result of ApnSetting's 'similar' method.
         P  => merged
         Q  => not merged

Test: Manual

Change-Id: I0584310765e246ef16163201282d7db48c44e451
Signed-off-by: yoonjeong Jang <yjeong.jang@samsung.com>
telephony/java/android/telephony/data/ApnSetting.java