Commit Graph

3425 Commits

Author SHA1 Message Date
Chen Xu
b71c76036c Merge "A test api to override carrier information" into pi-dev 2018-04-03 01:14:24 +00:00
TreeHugger Robot
93e11759d6 Merge changes from topic "planz" into pi-dev
* changes:
  Tests for SubscriptionManager APIs.
  Obtain NPMS through helper method.
2018-04-02 21:56:59 +00:00
TreeHugger Robot
7bedbabd0b Merge "Make changes to MBMS API following recs" into pi-dev 2018-03-31 04:17:41 +00:00
Xiangyu/Malcolm Chen
17d19b7d52 Merge "Adding debug message inside NetworkServiceCallback." into pi-dev 2018-03-31 00:02:10 +00:00
Hall Liu
c21bf59665 Make changes to MBMS API following recs
* Change all error handling logic to return an error code via the async
callback
* Add an UNKNOWN code for errors for future backwards compatibility, and
prohibit the middleware from sending this code.
* Add IntDef for errors through the async callback
* Amend documentation for download()
* Implement support for arranging downloaded files into a hierarchy
following that of the server.

Change-Id: I4d5c8f6229b216d9aa84397e628e62279033cc74
Fixes: 76449215
Test: CTS
2018-03-30 16:38:14 -07:00
Brad Ebinger
77fcc0da3b Merge "Unhide @SystemApi Constructor" into pi-dev 2018-03-30 21:36:35 +00:00
Jeff Sharkey
003d3e61e6 Tests for SubscriptionManager APIs.
Ensure that new SubscriptionManager APIs behave as documented.  Test
based on device claiming FEATURE_TELEPHONY, and require that we have
a valid getDefaultDataSubscriptionId() to run our tests against.

Test: atest android.telephony.cts.SubscriptionManagerTest
Bug: 77327990, 71816837
Change-Id: Ib90ceeacf546c9b36ecf69694442cb661a62d353
2018-03-30 15:31:27 -06:00
Jeff Sharkey
a435ab5124 Obtain NPMS through helper method.
Regression from an earlier partial revert, grr.

Test: manual
Bug: 77327990
Change-Id: I6193a1c3e213c8db145b19232e435f09c92def20
2018-03-30 13:25:20 -06:00
Malcolm Chen
5b51830764 Adding debug message inside NetworkServiceCallback.
Adding debug message inside NetworkServiceCallback when mCallback
is null.

Bug: 76392715
Test: existing test
Change-Id: Icd27d4082e1e4b60efe65abfff99c4165717fd4a
2018-03-29 19:05:12 -07:00
fionaxu
5b509b81a0 A test api to override carrier information
This API should only be used for testing purpose e.g., CTS/GTS/SL4A
By overriding carrier information, we could force a particular carrier id,
carrier's config, but also any country or carrier overlays to be loaded
when using a test SIM with a call box.

Bug: 72332597
Test: atest CtsTelephonyTestCases:CarrierIdentificationTest

Change-Id: Icd5804375ef9334c9f6c382cc6a774b9c9c15213
2018-03-29 12:30:09 -07:00
Brad Ebinger
37121d467c Unhide @SystemApi Constructor
There are a few small classes that never got properly
exposed as @SystemApi. These classes were not caught
because vendors currently build against the source
directly and have access to hidden APIs. We can not
change the vendor code at this point (different vendor
code for each year for all supported devices), but
we can start pulling back the API for new devices.

1) Keep all public mutable fields @hide and put
todo (and file bug b/74402619) to make fields
private or final.

2) Add public constructor that populates all fields
so that @hide public mutable fields can be set to
private/final in the future.

3) Provide getters for fields that will not be
public in the future.

In this way, we can make minimal API changes for P,
support new vendor/3rd party ImsServices, and phase
out old ImsService implementations that still build
against the source instead of using the correct
@SystemApi.

Bug: 77278031
Bug: 74402619
Test: Manual
Change-Id: Ifa3b6d0cbdb12e92efc699b760ca874768a89a7c
2018-03-29 11:36:28 -07:00
TreeHugger Robot
d63c009d5f Merge "Add additional logging for EMBMS edge cases" into pi-dev 2018-03-29 03:01:34 +00:00
TreeHugger Robot
a210ef2687 Merge "Add constants for reporting criteria" into pi-dev 2018-03-29 00:23:37 +00:00
Hall Liu
7c94698cfa Add additional logging for EMBMS edge cases
Add logging when failing to delete temp files or write download
tokens.

Test: logging only
Bug: 77237200
Change-Id: Id7836f3660d37d8cd94580d221c95b2c15c2cb68
2018-03-28 22:38:48 +00:00
Andy Chou
a547a51818 Merge "Specifies the carrier's default voicemail number for roaming network." into pi-dev 2018-03-28 08:28:53 +00:00
Jiuyu Sun
a78a764fe3 Merge "Address comments from API Review." into pi-dev 2018-03-28 04:18:51 +00:00
Svet Ganov
33b1509375 Throw on revoked location permission - framework
When we fixed proper handling of location permisison gating
sensitive telephony calls we stopped throwing a security
exception when the permission is not held by the caller.
While this is not a security issue there is no reason to
change this behavior which is checked by CTS. This CL starts
throwing a security exception if the permission is not held.

Test: atest android.permission.cts.NoLocationPermissionTest

bug: 74074103

Change-Id: Ic891d62b408c692f84a345f24503f7f25d583e35
2018-03-28 00:43:55 +00:00
Xiangyu/Malcolm Chen
2fc8197b4d Merge "Clean new TelephonyManager API." into pi-dev 2018-03-27 22:42:58 +00:00
Eric Schwarzenbach
702f0a8ce6 Add constants for reporting criteria
Adds RILConstants and TelephonyManager constants for reporting and
setting indication filter bits.

Bug: 72117365
Test: make
Change-Id: Ia52ffdbc9ea2499893ece518aba4a99c6fe4ee90
(cherry picked from commit 7ff6e14cf4)
2018-03-27 14:00:45 -07:00
Holly Jiuyu Sun
59159c437a Address comments from API Review.
Bug: 74975825
Bug: 74976716
Bug: 74976875
Test: test on phone
Change-Id: I5417e5dd95c75fd3fd9fa98d7559511bd0fcd8a0
2018-03-27 12:31:56 -07:00
Meng Wang
d5e1af54e3 Revert "Unhide enable_apps carrier config key."
This reverts commit 4793b28d3f.

Reason for revert: This is not intended as a public API.

Bug: 62907095
Test: make
Change-Id: Id79f91c72eac3929fa5ee7ac1cdd9df8671a1eb1
(cherry picked from commit f47a426206)
2018-03-27 17:28:19 +00:00
TreeHugger Robot
c2bdecb8c8 Merge "Move alpha long/short to the base CellIdentity according API Review." into pi-dev 2018-03-27 06:40:37 +00:00
Chen Xu
17aa751907 Merge "throw runtimeException for applicable TM APIs" into pi-dev 2018-03-26 23:39:56 +00:00
Hall Liu
8404d082c4 Merge "Modify LocationAccessPolicy to use LocationManager" into pi-dev 2018-03-26 20:59:58 +00:00
SongFerngWang
310f6d06d1 Specifies the carrier's default voicemail number for roaming network.
Configure voicemail number for roaming network.

BUG: 74022701
Test: Build success.
Change-Id: I9fa5543847abad4a40c1345c52475f416ce5031b
2018-03-26 09:58:41 +08:00
Malcolm Chen
636fdbccce Clean new TelephonyManager API.
This is to apply API council's review opinion on a previous commit.

We are reverting previous change, which renamed isDataEnabled and
setDataEnabled to isUserMobileDataEnabled and setUserMobileDataEnabled.
So this commit will remove the new APIs isUserMobileDataEnabled and
setUserMobileDataEnabled, and also rename hidden API isMobileDataEnabled
to isDataCapable.

Bug: 71584593
Test: unittest
Change-Id: I84d65776874e7a7f6e3a9af9ff7ec7dcbd715c2c
2018-03-23 18:51:29 -07:00
TreeHugger Robot
4f2e53fe48 Merge "Unhide ImsReasonInfo Constructor" into pi-dev 2018-03-24 01:12:49 +00:00
Brad Ebinger
2d108c3747 Merge "Parse SMS locally upon error to get message ref" into pi-dev 2018-03-23 23:19:26 +00:00
Hall Liu
ecd4709573 Merge "Split the DownloadStateCallback class into two" into pi-dev 2018-03-23 23:11:46 +00:00
fionaxu
f20f0d916f throw runtimeException for applicable TM APIs
1. This CL revert some API change from ag/3710629.
2. throw runtime exception when running in a non-1000 UID.
3. throw for methods that persist some sort of state and readers could continue to
return placeholder values.
4. for rest of TelephonyManager API cleanup b/74401420.

Bug: 74016743
Test: Build
Change-Id: I2846efc11eebce4a923762f56f09daaf37c44763
2018-03-23 12:04:22 -07:00
Hall Liu
5e35b2d00b Modify LocationAccessPolicy to use LocationManager
Remove the direct settings lookup since it's been deprecated.

Bug: 72886046
Test: run CTS
Change-Id: I00f11f46f20f86e91147b1232263b6c9a5d8c6b4
(cherry picked from commit d7a1c9dd76)
2018-03-23 18:37:07 +00:00
Eric Schwarzenbach
9b29e5caa0 Merge "Change null behavior of getCellBandwidths" into pi-dev 2018-03-23 18:31:43 +00:00
Cassie
21ed3c58e8 Move alpha long/short to the base CellIdentity according API Review.
Bug: 74831568
Test: Telephony sanity
Change-Id: I0ef69e3f18fca111191e1c6329ae13c0860869ba
2018-03-23 11:07:18 -07:00
Brad Ebinger
d4285ad123 Parse SMS locally upon error to get message ref
Parse the SMS locally to get the message ref when
onSmsReceived fails due to the platform being
unavailable. This allows the correct message ref
to be sent back via acknowledgeSms, instead of
the incorrect "0" value.

Bug: 74551838
Test: Manual
Change-Id: I2f8128d8ff4e07bb3720a344cee70fa5fd5d7535
2018-03-23 09:58:27 -07:00
Eric Schwarzenbach
c119a86350 Change null behavior of getCellBandwidths
Returns empty array instead of null when there are
no cell bandwidths.

Bug: 73751023
Test: make, runtest
Change-Id: Idc3f034bbea8f6c3f11dcd125f760b121d2c91d9
2018-03-22 16:51:19 -07:00
Ying Xu
812319dc7d Merge "Add more comments for the isConfigForIdentifiedCarrier()" into pi-dev 2018-03-22 21:14:32 +00:00
yinxu
349b644db3 Add more comments for the isConfigForIdentifiedCarrier()
This is a clean cherry-pick from:
https://android-review.git.corp.google.com/c/platform/frameworks/base/+/642231

Bug:74945742
Test: Compile
Change-Id: Ife3fdf797ca8877ec495d61a8aeed56fa20282a7
Merged-in: Ife3fdf797ca8877ec495d61a8aeed56fa20282a7
(cherry picked from commit cea0d8d488)
2018-03-22 12:08:51 -07:00
Mohamed Abdalkader
ca0c1ac304 Unhide ImsReasonInfo Constructor
Test: builds
Bug: 76033384
Change-Id: If1101b82f92e45cd417f34356545363f6f9bf322
2018-03-22 00:40:01 +00:00
Hall Liu
7953997160 Split the DownloadStateCallback class into two
Use individually-registered DownloadStatusListener and
DownloadProgressListener instead to listen for download status and
progress, respectively.

Bug: 74409377
Test: cts
Change-Id: Ifd5289038ffd66eef8bd7916f5256205b49be5f9
2018-03-21 23:39:07 +00:00
Brad Ebinger
025cb0c392 Merge "Define phone process as a constant" into pi-dev 2018-03-21 20:38:00 +00:00
Brad Ebinger
fb241e2250 Merge "Added Locking for MmTelFeature" into pi-dev 2018-03-21 18:56:00 +00:00
Brad Ebinger
1078b3a36b Define phone process as a constant
Test: Manual
Bug: 72645729
Merged-In: I8086e4efa15d74bd61c55b72c7b14be4705fcd58
Change-Id: If07728ea2cc0128113ebe947a154f80ff45a7d9d
2018-03-21 09:59:05 -07:00
TreeHugger Robot
9b50f67fff Merge "Use AsyncTask.SERIAL_EXECUTOR as the default executor for scan" into pi-dev 2018-03-21 02:05:12 +00:00
TreeHugger Robot
5d5d6aa28a Merge "Better javadoc and rename several methods in ApnSetting." into pi-dev 2018-03-20 23:38:10 +00:00
Nathan Harold
7eec8e9635 Merge "Add alpha Strings to CellIdentityTdscdma" into pi-dev 2018-03-20 23:35:58 +00:00
Jiuyu Sun
b8651f6fba Merge "Mark eraseSubscriptions as @SystemApi." into pi-dev 2018-03-20 22:53:31 +00:00
Nathan Harold
0acd7eeed4 Add alpha Strings to CellIdentityTdscdma
Add equivalent alphaLong and alphaShort to
TD-SCDMA so that it's equivalent to LTE, WCDMA,
GSM, etc.

Bug: 75980473
Test: compilation
Change-Id: Ibaa8a7daafb44f7fc94f0fd6aaa193b67793eea4
2018-03-20 22:37:45 +00:00
Xi Han
cd6bb7242c Merge "Add @Nullable annotations to getOperatorAlphaLong and getOperatorAlphaShort to CellIdentity." into pi-dev 2018-03-20 20:49:13 +00:00
Amit Mahajan
cfa8591779 Merge "Revert "TelephonyManager System APIs process"" into pi-dev 2018-03-20 19:27:10 +00:00
yuemingw
7e1298f1a4 Better javadoc and rename several methods in ApnSetting.
Test: runtest -x frameworks/base/services/tests/servicestests/src/com/android/server/devicepolicy/DevicePolicyManagerTest.java
run cts --module CtsDevicePolicyManagerTestCases --test com.android.cts.devicepolicy.DeviceOwnerTest#testOverrideApn

Bug: 73087996
Change-Id: I5232c92a44ab505946956f81965a205f170aa52b
2018-03-20 18:15:25 +00:00