summaryrefslogtreecommitdiff
path: root/libphonenumber/src/com/google/i18n/phonenumbers/AlternateFormatsCountryCodeSet.java
diff options
context:
space:
mode:
authorNarayan Kamath <narayan@google.com>2014-12-18 11:56:40 +0000
committerNarayan Kamath <narayan@google.com>2014-12-23 12:32:44 +0000
commita77faddfc3b3e4cca8f585c82d669054aec221f4 (patch)
treeb3ca5eaf70be2df2a1a9cfc684532d1563d759a7 /libphonenumber/src/com/google/i18n/phonenumbers/AlternateFormatsCountryCodeSet.java
parenteec8af34d3129d0f37c45ff8a82b4212724a6d79 (diff)
downloadlibphonenumber-a77faddfc3b3e4cca8f585c82d669054aec221f4.tar.gz
Update libphonenumber to an unmodified copy of v7.0.1
Copied from upstream commit eb7f783d2fd7d222a10283a72d9e7 with no local modifications and a cherry-pick of commit 5b00cb5b2dc0582c29 (JAVA/JS: Documentation fix and added missing licences.) from upstream master. Added Android.mk to build the code for platform and unbundled use. Note that while we rename packages, we don't rename resources to make sure they're found. Change-Id: Idb886f1b5d7bca491b9f7f8d18574a88f08593ba
Diffstat (limited to 'libphonenumber/src/com/google/i18n/phonenumbers/AlternateFormatsCountryCodeSet.java')
-rw-r--r--libphonenumber/src/com/google/i18n/phonenumbers/AlternateFormatsCountryCodeSet.java79
1 files changed, 79 insertions, 0 deletions
diff --git a/libphonenumber/src/com/google/i18n/phonenumbers/AlternateFormatsCountryCodeSet.java b/libphonenumber/src/com/google/i18n/phonenumbers/AlternateFormatsCountryCodeSet.java
new file mode 100644
index 00000000..c07a1739
--- /dev/null
+++ b/libphonenumber/src/com/google/i18n/phonenumbers/AlternateFormatsCountryCodeSet.java
@@ -0,0 +1,79 @@
+/*
+ * Copyright (C) 2012 The Libphonenumber Authors
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/* This file is automatically generated by {@link BuildMetadataProtoFromXml}.
+ * Please don't modify it directly.
+ */
+
+package com.google.i18n.phonenumbers;
+
+import java.util.HashSet;
+import java.util.Set;
+
+public class AlternateFormatsCountryCodeSet {
+ // A set of all country codes for which data is available.
+ static Set<Integer> getCountryCodeSet() {
+ // The capacity is set to 57 as there are 43 different entries,
+ // and this offers a load factor of roughly 0.75.
+ Set<Integer> countryCodeSet = new HashSet<Integer>(57);
+
+ countryCodeSet.add(7);
+ countryCodeSet.add(27);
+ countryCodeSet.add(30);
+ countryCodeSet.add(31);
+ countryCodeSet.add(34);
+ countryCodeSet.add(36);
+ countryCodeSet.add(43);
+ countryCodeSet.add(44);
+ countryCodeSet.add(49);
+ countryCodeSet.add(54);
+ countryCodeSet.add(55);
+ countryCodeSet.add(58);
+ countryCodeSet.add(61);
+ countryCodeSet.add(62);
+ countryCodeSet.add(63);
+ countryCodeSet.add(66);
+ countryCodeSet.add(81);
+ countryCodeSet.add(84);
+ countryCodeSet.add(90);
+ countryCodeSet.add(91);
+ countryCodeSet.add(94);
+ countryCodeSet.add(95);
+ countryCodeSet.add(255);
+ countryCodeSet.add(350);
+ countryCodeSet.add(351);
+ countryCodeSet.add(352);
+ countryCodeSet.add(358);
+ countryCodeSet.add(359);
+ countryCodeSet.add(372);
+ countryCodeSet.add(373);
+ countryCodeSet.add(380);
+ countryCodeSet.add(381);
+ countryCodeSet.add(385);
+ countryCodeSet.add(505);
+ countryCodeSet.add(506);
+ countryCodeSet.add(595);
+ countryCodeSet.add(675);
+ countryCodeSet.add(676);
+ countryCodeSet.add(679);
+ countryCodeSet.add(855);
+ countryCodeSet.add(971);
+ countryCodeSet.add(972);
+ countryCodeSet.add(995);
+
+ return countryCodeSet;
+ }
+}