com.univocity.parsers.conversions.Conversion, as well as useful methods for obtaining new instances of these.
| Modifier and Type | Field and Description |
|---|---|
| private static final LowerCaseConversion | |
| private static final ToStringConversion | |
| private static final TrimConversion | |
| private static final UpperCaseConversion |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static FormattedBigDecimalConversion | Returns: a new instance ofFormattedBigDecimalConversion that supports the given number formatslist of acceptable numeric patterns. The first pattern in this sequence will be used to convert a BigDecimal into a String in numberFormats)NumericConversion#revert(Number).Returns a new instance of |
| public static FormattedBigDecimalConversion | Returns: a new instance ofFormattedBigDecimalConversion that supports the given number formatsdefault BigDecimal to be returned when the input String is null. Used when defaultValueForNullString, String... FormattedBigDecimalConversion#execute(String) is invoked.list of acceptable numeric patterns. The first pattern in this sequence will be used to convert a BigDecimal into a String in numberFormats)NumericConversion#revert(Number).Returns a new instance of |
| public static FormattedBigDecimalConversion | Returns: a new instance ofFormattedBigDecimalConversion that supports the given number formatsdefault BigDecimal to be returned when the input String is null. Used when defaultValueForNullString, String FormattedBigDecimalConversion#execute(String) is invoked.default String value to be returned when a BigDecimal input is null. Used when stringIfNull, String... FormattedBigDecimalConversion#revert(BigDecimal) is invoked.list of acceptable numeric patterns. The first pattern in this sequence will be used to convert a BigDecimal into a String in numberFormats)NumericConversion#revert(Number).Returns a new instance of |
| public static NumericConversion | Returns: a new instance ofNumericConversion that supports the given number formatslist of acceptable numeric patterns. The first pattern in this sequence will be used to convert a Number into a String in numberFormats)NumericConversion#revert(Number).Returns a new instance of |
| public static < type of number T extends Number> NumericConversion | Returns: a new instance ofNumericConversion that supports the given number formatstype of number to be returned. The resulting instance of numberType, String... Number will be cast to the expected type.list of acceptable numeric patterns. The first pattern in this sequence will be used to convert a Number into a String in numberFormats)NumericConversion#revert(Number).Returns a new instance of |
| public static ValidatedConversion | Returns: new instance ofValidatedConversion configured with the given parameterslist of values that are not allowed. noneOf)Returns a new instance of |
| public static ValidatedConversion | Returns: a not-blank validatorReturns a |
| public static ValidatedConversion | Returns: a value format validatorregular expression to match and ensure the value has a given format regexToMatch)Returns a |
| public static ValidatedConversion | |
| public static ValidatedConversion | Returns: new instance ofValidatedConversion configured with the given parameterslist of accepted values. oneOf)Returns a new instance of |
| public static RegexConversion | Returns: the new instance ofRegexConversion created with the given parameters.the regular expression used to match contents of a given input String replaceRegex, String the replacement content to replace any contents matched by the given regular expression replacement)Returns a new instance of |
| public static ToStringConversion | Returns: a singleton instance ofToStringConversionReturns a singleton instance of |
| public static BigDecimalConversion | Returns: a new instance ofBigDecimalConversionReturns a new instance of |
| public static BigIntegerConversion | Returns: a new instance ofBigIntegerConversionReturns a new instance of |
| public static BooleanConversion | Returns: a new instance ofBooleanConversion with support for multiple representations of true and falsedefault Boolean value to be returned when the input String is null. Used when defaultValueForNullString, String BooleanConversion#execute(String) is invoked.default String value to be returned when a Boolean input is null. Used when defaultValueForNullBoolean, String[] BooleanConversion#revert(Boolean) is invoked.Strings that identify the boolean value true. The first element will be returned when executing valuesForTrue, String[] BooleanConversion.revert(true)Strings that identify the boolean value false. The first element will be returned when executing valuesForFalse)BooleanConversion.revert(false)Returns a new instance of |
| public static BooleanConversion | Returns: a new instance ofBooleanConversion with support for multiple representations of true and falsedefault Boolean value to be returned when the input String is null. Used when defaultValueForNullString, String BooleanConversion#execute(String) is invoked.default String value to be returned when a Boolean input is null. Used when defaultValueForNullBoolean, String BooleanConversion#revert(Boolean) is invoked.String that identify the boolean value true. valueForTrue, String String that identify the boolean value false. valueForFalse)Returns a new instance of |
| public static BooleanConversion | Returns: a new instance ofBooleanConversion with support for multiple representations of true and falseStrings that identify the boolean value true. The first element will be returned when executing valuesForTrue, String[] BooleanConversion.revert(true)Strings that identify the boolean value false. The first element will be returned when executing valuesForFalse)BooleanConversion.revert(false)Returns a new instance of |
| public static BooleanConversion | Returns: a new instance ofBooleanConversion with support for multiple representations of true and falseReturns a new instance of |
| public static BooleanConversion | Returns: a new instance ofBooleanConversion with support for multiple representations of true and falseString that identifies the boolean value true. valueForTrue, String String that identifies the boolean value false. valueForFalse)Returns a new instance of |
| public static ByteConversion | |
| public static CalendarConversion | Returns: the new instance ofCalendarConversion created with the given parameters.the locale, String... Locale that determines how the date mask should be formatted.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Calendar into a String in dateFormats)CalendarConversion#revert(Calendar).Returns a new instance of |
| public static CalendarConversion | Returns: the new instance ofCalendarConversion created with the given parameters.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Calendar into a String in dateFormats)CalendarConversion#revert(Calendar).Returns a new instance of |
| public static CalendarConversion | Returns: the new instance ofCalendarConversion created with the given parameters.the locale, Calendar Locale that determines how the date mask should be formatted.default Calendar value to be returned when the input String is null. Used when dateIfNull, String... CalendarConversion#execute(String) is invoked.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Calendar into a String in dateFormats)CalendarConversion#revert(Calendar).Returns a new instance of |
| public static CalendarConversion | Returns: the new instance ofCalendarConversion created with the given parameters.default Calendar value to be returned when the input String is null. Used when dateIfNull, String... CalendarConversion#execute(String) is invoked.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Calendar into a String in dateFormats)CalendarConversion#revert(Calendar).Returns a new instance of |
| public static CalendarConversion | Returns: the new instance ofCalendarConversion created with the given parameters.the locale, Calendar Locale that determines how the date mask should be formatted.default Calendar value to be returned when the input String is null. Used when dateIfNull, String CalendarConversion#execute(String) is invoked.default String value to be returned when a Date input is null. Used when stringIfNull, String... CalendarConversion#revert(Calendar) is invoked.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Calendar into a String in dateFormats)CalendarConversion#revert(Calendar).Returns a new instance of |
| public static CalendarConversion | Returns: the new instance ofCalendarConversion created with the given parameters.the timeZone, Locale TimeZone to be consideredthe locale, Calendar Locale that determines how the date mask should be formatted.default Calendar value to be returned when the input String is null. Used when dateIfNull, String CalendarConversion#execute(String) is invoked.default String value to be returned when a Date input is null. Used when stringIfNull, String... CalendarConversion#revert(Calendar) is invoked.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Calendar into a String in dateFormats)CalendarConversion#revert(Calendar).Returns a new instance of |
| public static CalendarConversion | Returns: the new instance ofCalendarConversion created with the given parameters.default Calendar value to be returned when the input String is null. Used when dateIfNull, String CalendarConversion#execute(String) is invoked.default String value to be returned when a Date input is null. Used when stringIfNull, String... CalendarConversion#revert(Calendar) is invoked.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Calendar into a String in dateFormats)CalendarConversion#revert(Calendar).Returns a new instance of |
| public static CharacterConversion | |
| public static CharacterConversion | Returns: a new instance ofCharacterConversiondefault Character value to be returned when the input String is null. Used when defaultValueForNullString, String CharacterConversion#execute(String) is invoked.default String value to be returned when a Character input is null. Used when defaultValueForNullChar)CharacterConversion#revert(Character) is invoked.Returns a new instance of |
| public static CharacterConversion | Returns: a new instance ofCharacterConversiondefault Character value to be returned when the input String is null. Used when defaultValueForNullString)CharacterConversion#execute(String) is invoked.Returns a new instance of |
| public static DateConversion | Returns: the new instance ofDateConversion created with the given parameters.the locale, String... Locale that determines how the date mask should be formatted.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Date into a String in dateFormats)DateConversion#revert(Date).Returns a new instance of |
| public static DateConversion | Returns: the new instance ofDateConversion created with the given parameters.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Date into a String in dateFormats)DateConversion#revert(Date).Returns a new instance of |
| public static DateConversion | Returns: the new instance ofDateConversion created with the given parameters.the locale, Date Locale that determines how the date mask should be formatted.default Date value to be returned when the input String is null. Used when dateIfNull, String... DateConversion#execute(String) is invoked.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Date into a String in dateFormats)DateConversion#revert(Date).Returns a new instance of |
| public static DateConversion | Returns: the new instance ofDateConversion created with the given parameters.default Date value to be returned when the input String is null. Used when dateIfNull, String... DateConversion#execute(String) is invoked.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Date into a String in dateFormats)DateConversion#revert(Date).Returns a new instance of |
| public static DateConversion | Returns: the new instance ofDateConversion created with the given parameters.the timeZone, Locale TimeZone of the date to be formattedthe locale, Date Locale that determines how the date mask should be formatted.default Date value to be returned when the input String is null. Used when dateIfNull, String DateConversion#execute(String) is invoked.default String value to be returned when a Date input is null. Used when stringIfNull, String... DateConversion#revert(Date) is invoked.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Date into a String in dateFormats)DateConversion#revert(Date).Returns a new instance of |
| public static DateConversion | Returns: the new instance ofDateConversion created with the given parameters.the locale, Date Locale that determines how the date mask should be formatted.default Date value to be returned when the input String is null. Used when dateIfNull, String DateConversion#execute(String) is invoked.default String value to be returned when a Date input is null. Used when stringIfNull, String... DateConversion#revert(Date) is invoked.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Date into a String in dateFormats)DateConversion#revert(Date).Returns a new instance of |
| public static DateConversion | Returns: the new instance ofDateConversion created with the given parameters.default Date value to be returned when the input String is null. Used when dateIfNull, String DateConversion#execute(String) is invoked.default String value to be returned when a Date input is null. Used when stringIfNull, String... DateConversion#revert(Date) is invoked.list of acceptable date patterns. The first pattern in this sequence will be used to convert a Date into a String in dateFormats)DateConversion#revert(Date).Returns a new instance of |
| public static DoubleConversion | |
| public static < the T extends Enumenum type | Returns: new instance ofEnumConversionthe enumeration type to be converted from/to enumType)StringReturns a new instance of |
| public static < the T extends Enumenum type | Returns: new instance ofEnumConversionthe enumeration type to be converted from/to enumType, EnumSelector... Stringthe selection elements of the enumeration to use for matching selectors)Strings.Returns a new instance of |
| public static < the T extends Enumenum type | Returns: new instance ofEnumConversionthe enumeration type to be converted from/to enumType, String Stringname of custom element of the enumeration (attribute or method) whose values should be used to match equivalent customEnumElement, EnumSelector... Strings.the selection elements of the enumeration to use for matching selectors)Strings.Returns a new instance of |
| public static < the T extends Enumenum type | Returns: new instance ofEnumConversionthe enumeration type to be converted from/to enumType, T Stringthe default enumeration constant to use if the input valueIfStringIsNull, String String is nullthe default valueIfEnumIsNull, String String value to use if the input enum constant is nullname of custom element of the enumeration (attribute or method) whose values should be used to match equivalent customEnumElement, EnumSelector... Strings.the selection elements of the enumeration to use for matching selectors)Strings.Returns a new instance of |
| public static FloatConversion | |
| public static FormattedDateConversion | Returns: new instance ofFormattedDateConversion configured with the given parametersReturns a new instance of |
| public static FormattedDateConversion | Returns: new instance ofFormattedDateConversion configured with the given parametersDefault string value to be returned when the input object is null. valueIfObjectIsNull)Returns a new instance of |
| public static FormattedDateConversion | Returns: new instance ofFormattedDateConversion configured with the given parametersThe locale)Locale that determines how the date pattern should be formatted.Returns a new instance of |
| public static FormattedDateConversion | Returns: new instance ofFormattedDateConversion configured with the given parametersThe locale, String Locale that determines how the date pattern should be formatted.Default string value to be returned when the input object is null. valueIfObjectIsNull)Returns a new instance of |
| public static IntegerConversion | |
| public static LongConversion | |
| public static LowerCaseConversion | Returns: a singleton instance ofLowerCaseConversionReturns a singleton instance of |
| public static NullStringConversion | Returns: the new instance ofNullStringConversion created with the given parameters.the sequence of Strings that represent a null value. nullRepresentations)Returns a new instance of |
| public static ShortConversion | |
| public static UpperCaseConversion | Returns: a singleton instance ofUpperCaseConversionReturns a singleton instance of |
| public static TrimConversion | |
| public static TrimConversion | Returns: a trim-to-length conversionthe maximum length a value can contain. Characters after this limit will
be discarded. length)Returns a |
| public static ValidatedConversion | Returns: new instance ofValidatedConversion configured with the given parametersflag to indicate whether values can be null nullable, boolean flag to indicate whether values can be blank allowBlanks)Returns a |
| public static ValidatedConversion | Returns: new instance ofValidatedConversion configured with the given parametersflag to indicate whether values can be null nullable, boolean flag to indicate whether values can be blank allowBlanks, String[] list of accepted values. oneOf, String[] list of unacceptable values noneOf)Returns a new instance of |
| public static ValidatedConversion | Returns: new instance ofValidatedConversion configured with the given parametersflag to indicate whether values can be null nullable, boolean flag to indicate whether values can be blank allowBlanks, String regular expression to match and ensure the value has a given format regexToMatch)Returns a |
| public static ValidatedConversion | Returns: new instance ofValidatedConversion configured with the given parametersflag to indicate whether values can be null nullable, boolean flag to indicate whether values can be blank allowBlanks, String[] list of accepted values. oneOf, String[] list of unacceptable values noneOf, String regular expression to match and ensure the value has a given format regexToMatch)Returns a new instance of |