summaryrefslogtreecommitdiffstats
path: root/telephony/java/android
diff options
context:
space:
mode:
authorYorke Lee <yorkelee@google.com>2014-06-05 22:23:03 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-06-05 22:23:03 +0000
commitf537259ec420052cae342c213579aec26c488055 (patch)
treef86d4c6dd1985cf16d496f6d09061a6c1f0c8ca2 /telephony/java/android
parent0622a4c8b80996258bfb7a3ca4effed32fcf18d3 (diff)
parent66c11e1f8478a3f436e31e315f9bbb43d6d5f021 (diff)
downloadframeworks_base-f537259ec420052cae342c213579aec26c488055.zip
frameworks_base-f537259ec420052cae342c213579aec26c488055.tar.gz
frameworks_base-f537259ec420052cae342c213579aec26c488055.tar.bz2
am 87d1dbc5: Merge "API changes to Telephony per API review" into lmp-preview-dev
* commit '87d1dbc52e473227b2b4bc0d95ca48cfb3363adc': API changes to Telephony per API review
Diffstat (limited to 'telephony/java/android')
-rw-r--r--telephony/java/android/telephony/DisconnectCause.java2
-rw-r--r--telephony/java/android/telephony/PhoneNumberUtils.java28
2 files changed, 13 insertions, 17 deletions
diff --git a/telephony/java/android/telephony/DisconnectCause.java b/telephony/java/android/telephony/DisconnectCause.java
index d2044be..604b895 100644
--- a/telephony/java/android/telephony/DisconnectCause.java
+++ b/telephony/java/android/telephony/DisconnectCause.java
@@ -18,6 +18,8 @@ package android.telephony;
/**
* Contains disconnect call causes generated by the framework and the RIL.
+ *
+ * @hide
*/
public class DisconnectCause {
diff --git a/telephony/java/android/telephony/PhoneNumberUtils.java b/telephony/java/android/telephony/PhoneNumberUtils.java
index 9da032a..6996659 100644
--- a/telephony/java/android/telephony/PhoneNumberUtils.java
+++ b/telephony/java/android/telephony/PhoneNumberUtils.java
@@ -1742,16 +1742,14 @@ public class PhoneNumberUtils
/**
* Checks if a given number is an emergency number for the country that the user is in.
- *
- * @param number the number to look up.
* @param context the specific context which the number should be checked against
+ * @param number the number to look up.
+ *
* @return true if the specified number is an emergency number for the country the user
* is currently in.
*/
- public static boolean isLocalEmergencyNumber(String number, Context context) {
- return isLocalEmergencyNumberInternal(number,
- context,
- true /* useExactMatch */);
+ public static boolean isLocalEmergencyNumber(Context context, String number) {
+ return isLocalEmergencyNumberInternal(context, number, true /* useExactMatch */);
}
/**
@@ -1767,27 +1765,24 @@ public class PhoneNumberUtils
* This method is intended for internal use by the phone app when
* deciding whether to allow ACTION_CALL intents from 3rd party apps
* (where we're required to *not* allow emergency calls to be placed.)
- *
- * @param number the number to look up.
* @param context the specific context which the number should be checked against
+ * @param number the number to look up.
+ *
* @return true if the specified number is an emergency number for a local country, based on the
* CountryDetector.
*
* @see android.location.CountryDetector
* @hide
*/
- public static boolean isPotentialLocalEmergencyNumber(String number, Context context) {
- return isLocalEmergencyNumberInternal(number,
- context,
- false /* useExactMatch */);
+ public static boolean isPotentialLocalEmergencyNumber(Context context, String number) {
+ return isLocalEmergencyNumberInternal(context, number, false /* useExactMatch */);
}
/**
* Helper function for isLocalEmergencyNumber() and
* isPotentialLocalEmergencyNumber().
- *
- * @param number the number to look up.
* @param context the specific context which the number should be checked against
+ * @param number the number to look up.
* @param useExactMatch if true, consider a number to be an emergency
* number only if it *exactly* matches a number listed in
* the RIL / SIM. If false, a number is considered to be an
@@ -1799,9 +1794,8 @@ public class PhoneNumberUtils
*
* @see android.location.CountryDetector
*/
- private static boolean isLocalEmergencyNumberInternal(String number,
- Context context,
- boolean useExactMatch) {
+ private static boolean isLocalEmergencyNumberInternal(Context context, String number,
+ boolean useExactMatch) {
String countryIso;
CountryDetector detector = (CountryDetector) context.getSystemService(
Context.COUNTRY_DETECTOR);