@ProviderType public interface ConverterBuilder
null
the next
rule found will be visited. If none of the rules can handle the conversion,
the original converter will be used to perform the conversion.Modifier and Type | Method and Description |
---|---|
Converter |
build()
Build the specified converter.
|
ConverterBuilder |
errorHandler(ConverterFunction func)
Register a custom error handler.
|
ConverterBuilder |
rule(ConverterFunction func)
Register a catch-all rule, will be called of no other rule matches.
|
ConverterBuilder |
rule(TargetRule rule)
Register a conversion rule for this converter.
|
ConverterBuilder |
rule(java.lang.reflect.Type type,
ConverterFunction func)
Register a conversion rule for this converter.
|
Converter build()
ConverterBuilder errorHandler(ConverterFunction func)
func
- The function to be used to handle errors.ConverterBuilder rule(java.lang.reflect.Type type, ConverterFunction func)
type
- The type that this rule will produce.func
- The function that will handle the conversion.ConverterBuilder rule(TargetRule rule)
rule
- A rule implementation.ConverterBuilder rule(ConverterFunction func)
func
- The function that will handle the conversion.Copyright © 2010 - 2020 Adobe. All Rights Reserved