Package com.jidesoft.converter
Class YearNameConverter
java.lang.Object
com.jidesoft.converter.NumberConverter
com.jidesoft.converter.YearNameConverter
- All Implemented Interfaces:
ObjectConverter
Converter which converts year to int and converts it back. It is no difference from a number converter except it
doesn't use grouping when formatting.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic ConverterContextDefault ConverterContext for MonthConverter.Fields inherited from class com.jidesoft.converter.NumberConverter
CONTEXT_FRACTION_NUMBER -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfromString(String string, ConverterContext context) Converts from String to an object.protected NumberFormatGets the NumberFormat for Locale.US.booleansupportFromString(String string, ConverterContext context) If it supports fromString.Methods inherited from class com.jidesoft.converter.NumberConverter
getNumberFormat, isAvoidNegativeZero, isGroupingUsed, parseNumber, setAvoidNegativeZero, setCurrency, setFractionDigits, setGroupingUsed, setIntegerDigits, setNumberFormat, setRoundingMode, supportToString, toString
-
Field Details
-
CONTEXT
Default ConverterContext for MonthConverter.
-
-
Constructor Details
-
YearNameConverter
public YearNameConverter()Creates a new CalendarConverter.
-
-
Method Details
-
getDefaultNumberFormat
Description copied from class:NumberConverterGets the NumberFormat for Locale.US.- Overrides:
getDefaultNumberFormatin classNumberConverter- Returns:
- the NumberFormat for Locale.US.
-
fromString
Description copied from interface:ObjectConverterConverts from String to an object.- Parameters:
string- the stringcontext- context to be converted- Returns:
- the object converted from string
-
supportFromString
Description copied from interface:ObjectConverterIf it supports fromString.- Parameters:
string- the stringcontext- context to be converted- Returns:
- true if it supports
-