diff options
author | The Android Open Source Project <initial-contribution@android.com> | 2009-03-13 13:04:22 -0700 |
---|---|---|
committer | The Android Open Source Project <initial-contribution@android.com> | 2009-03-13 13:04:22 -0700 |
commit | ba87e3e6c985e7175152993b5efcc7dd2f0e1c93 (patch) | |
tree | ee35f76532767dc29411a8738a434d1d88d330f2 /core/java/android/text/util | |
parent | c39a6e0c51e182338deb8b63d07933b585134929 (diff) | |
download | frameworks_base-ba87e3e6c985e7175152993b5efcc7dd2f0e1c93.zip frameworks_base-ba87e3e6c985e7175152993b5efcc7dd2f0e1c93.tar.gz frameworks_base-ba87e3e6c985e7175152993b5efcc7dd2f0e1c93.tar.bz2 |
auto import from //branches/cupcake_rel/...@138607
Diffstat (limited to 'core/java/android/text/util')
-rw-r--r-- | core/java/android/text/util/Regex.java | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/core/java/android/text/util/Regex.java b/core/java/android/text/util/Regex.java index 4c128ad..a349b82 100644 --- a/core/java/android/text/util/Regex.java +++ b/core/java/android/text/util/Regex.java @@ -66,9 +66,9 @@ public class Regex { public static final Pattern WEB_URL_PATTERN = Pattern.compile( "((?:(http|https|Http|Https):\\/\\/(?:(?:[a-zA-Z0-9\\$\\-\\_\\.\\+\\!\\*\\'\\(\\)" - + "\\,\\;\\?\\&\\=]|(?:\\%[a-fA-F0-9]{2}))+(?:\\:(?:[a-zA-Z0-9\\$\\-\\_" - + "\\.\\+\\!\\*\\'\\(\\)\\,\\;\\?\\&\\=]|(?:\\%[a-fA-F0-9]{2}))+)?\\@)?)?" - + "((?:(?:[a-zA-Z0-9][a-zA-Z0-9\\-]*\\.)+" // named host + + "\\,\\;\\?\\&\\=]|(?:\\%[a-fA-F0-9]{2})){1,64}(?:\\:(?:[a-zA-Z0-9\\$\\-\\_" + + "\\.\\+\\!\\*\\'\\(\\)\\,\\;\\?\\&\\=]|(?:\\%[a-fA-F0-9]{2})){1,25})?\\@)?)?" + + "((?:(?:[a-zA-Z0-9][a-zA-Z0-9\\-]{0,64}\\.)+" // named host + "(?:" // plus top level domain + "(?:aero|arpa|asia|a[cdefgilmnoqrstuwxz])" + "|(?:biz|b[abdefghijmnorstvwyz])" @@ -122,12 +122,12 @@ public class Regex { public static final Pattern EMAIL_ADDRESS_PATTERN = Pattern.compile( - "[a-zA-Z0-9\\+\\.\\_\\%\\-]+" + + "[a-zA-Z0-9\\+\\.\\_\\%\\-]{1,256}" + "\\@" + - "[a-zA-Z0-9][a-zA-Z0-9\\-]*" + + "[a-zA-Z0-9][a-zA-Z0-9\\-]{0,64}" + "(" + "\\." + - "[a-zA-Z0-9][a-zA-Z0-9\\-]*" + + "[a-zA-Z0-9][a-zA-Z0-9\\-]{0,25}" + ")+" ); |