com.google.zxing.client.android
Class LocaleManager

java.lang.Object
  extended by com.google.zxing.client.android.LocaleManager

public final class LocaleManager
extends java.lang.Object

Handles any locale-specific logic for the client.

Author:
Sean Owen

Method Summary
static java.lang.String getBookSearchCountryTLD(android.content.Context context)
          The same as above, but specifically for Google Book Search.
static java.lang.String getCountryTLD(android.content.Context context)
           
static java.lang.String getProductSearchCountryTLD(android.content.Context context)
          The same as above, but specifically for Google Product Search.
static java.lang.String getTranslatedAssetLanguage()
           
static boolean isBookSearchUrl(java.lang.String url)
          Does a given URL point to Google Book Search, regardless of domain.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getCountryTLD

public static java.lang.String getCountryTLD(android.content.Context context)
Returns:
country-specific TLD suffix appropriate for the current default locale (e.g. "co.uk" for the United Kingdom)

getProductSearchCountryTLD

public static java.lang.String getProductSearchCountryTLD(android.content.Context context)
The same as above, but specifically for Google Product Search.

Returns:
The top-level domain to use.

getBookSearchCountryTLD

public static java.lang.String getBookSearchCountryTLD(android.content.Context context)
The same as above, but specifically for Google Book Search.

Returns:
The top-level domain to use.

isBookSearchUrl

public static boolean isBookSearchUrl(java.lang.String url)
Does a given URL point to Google Book Search, regardless of domain.

Parameters:
url - The address to check.
Returns:
True if this is a Book Search URL.

getTranslatedAssetLanguage

public static java.lang.String getTranslatedAssetLanguage()