Most visited

Recently visited

TextUtilsCompat

public final class TextUtilsCompat
extends Object

java.lang.Object
   ↳ android.support.v4.text.TextUtilsCompat


Summary

Fields

public static final Locale ROOT

Public methods

static int getLayoutDirectionFromLocale(Locale locale)

Return the layout direction for a given Locale

static String htmlEncode(String s)

Html-encode the string.

Inherited methods

From class java.lang.Object

Fields

ROOT

Locale ROOT

Public methods

getLayoutDirectionFromLocale

int getLayoutDirectionFromLocale (Locale locale)

Return the layout direction for a given Locale

Parameters
locale Locale: the Locale for which we want the layout direction. Can be null.
Returns
int the layout direction. This may be one of: LAYOUT_DIRECTION_LTR or LAYOUT_DIRECTION_RTL. Be careful: this code will need to be updated when vertical scripts will be supported

htmlEncode

String htmlEncode (String s)

Html-encode the string.

Parameters
s String: the string to be encoded
Returns
String the encoded string

Hooray!