|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.threeten.bp.format.DecimalStyle
public final class DecimalStyle
Localized symbols used in date and time formatting.
A significant part of dealing with dates and times is the localization. This class acts as a central point for accessing the information.
| Field Summary | |
|---|---|
static DecimalStyle |
STANDARD
The standard set of non-localized symbols. |
| Method Summary | |
|---|---|
boolean |
equals(Object obj)
Checks if these symbols equal another set of symbols. |
static Set<Locale> |
getAvailableLocales()
Lists all the locales that are supported. |
char |
getDecimalSeparator()
Gets the character that represents the decimal point. |
char |
getNegativeSign()
Gets the character that represents the negative sign. |
char |
getPositiveSign()
Gets the character that represents the positive sign. |
char |
getZeroDigit()
Gets the character that represents zero. |
int |
hashCode()
A hash code for these symbols. |
static DecimalStyle |
of(Locale locale)
Obtains symbols for the specified locale. |
static DecimalStyle |
ofDefaultLocale()
Obtains symbols for the default locale. |
String |
toString()
Returns a string describing these symbols. |
DecimalStyle |
withDecimalSeparator(char decimalSeparator)
Returns a copy of the info with a new character that represents the decimal point. |
DecimalStyle |
withNegativeSign(char negativeSign)
Returns a copy of the info with a new character that represents the negative sign. |
DecimalStyle |
withPositiveSign(char positiveSign)
Returns a copy of the info with a new character that represents the positive sign. |
DecimalStyle |
withZeroDigit(char zeroDigit)
Returns a copy of the info with a new character that represents zero. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final DecimalStyle STANDARD
This uses standard ASCII characters for zero, positive, negative and a dot for the decimal point.
| Method Detail |
|---|
public static Set<Locale> getAvailableLocales()
The locale 'en_US' will always be present.
public static DecimalStyle ofDefaultLocale()
This method provides access to locale sensitive symbols.
public static DecimalStyle of(Locale locale)
This method provides access to locale sensitive symbols.
locale - the locale, not null
public char getZeroDigit()
The character used to represent digits may vary by culture. This method specifies the zero character to use, which implies the characters for one to nine.
public DecimalStyle withZeroDigit(char zeroDigit)
The character used to represent digits may vary by culture. This method specifies the zero character to use, which implies the characters for one to nine.
zeroDigit - the character for zero
public char getPositiveSign()
The character used to represent a positive number may vary by culture. This method specifies the character to use.
public DecimalStyle withPositiveSign(char positiveSign)
The character used to represent a positive number may vary by culture. This method specifies the character to use.
positiveSign - the character for the positive sign
public char getNegativeSign()
The character used to represent a negative number may vary by culture. This method specifies the character to use.
public DecimalStyle withNegativeSign(char negativeSign)
The character used to represent a negative number may vary by culture. This method specifies the character to use.
negativeSign - the character for the negative sign
public char getDecimalSeparator()
The character used to represent a decimal point may vary by culture. This method specifies the character to use.
public DecimalStyle withDecimalSeparator(char decimalSeparator)
The character used to represent a decimal point may vary by culture. This method specifies the character to use.
decimalSeparator - the character for the decimal point
public boolean equals(Object obj)
equals in class Objectobj - the object to check, null returns false
public int hashCode()
hashCode in class Objectpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||