com.vaadin.flow.data.converter.
Enum Class DefaultConverterFactory
All Implemented Interfaces:
ConverterFactory
, Serializable
, Comparable<DefaultConverterFactory>
, Constable
Default implementation of ConverterFactory
, handling all standard
converters defined in com.vaadin.flow.data.converters
package.
Since:
Author:
Vaadin Ltd
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionnewInstance
(Class<P> presentationType, Class<M> modelType) Attempts to create a
Converter
instance, capable to handle conversion between the given presentation and model types.static DefaultConverterFactory
Returns the enum constant of this class with the specified name.
static DefaultConverterFactory[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
INSTANCE
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.
Returns:
an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
Parameters:
name
- the name of the enum constant to be returned.Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null -
newInstance
Description copied from interface:
ConverterFactory
Attempts to create a
Converter
instance, capable to handle conversion between the given presentation and model types. An emptyOptional
is returned if a conversion cannot be performed.Specified by:
newInstance
in interfaceConverterFactory
Type Parameters:
P
- The presentation type.M
- The model type.Parameters:
presentationType
- presentation type, not null.modelType
- model type, not null.Returns:
a
Converter
instance wrapped into anOptional
, or an emptyOptional
if no suitable converter is available.
-