public class TranslateTranslatorFactory extends Object implements TranslatorFactory<Object>
Translator factory which lets users define a custom translator for a field.
Constructor and Description |
---|
TranslateTranslatorFactory(boolean earlyOnly) |
public TranslateTranslatorFactory(boolean earlyOnly)
earlyOnly
- determines whether this instance ignores @Translate annotations with early=falsepublic Translator<Object> create(Path path, Property property, Type type, CreateContext ctx)
create
in interface TranslatorFactory<Object>
path
- current path to this part of the tree, important for logging and exceptionsproperty
- is the property we are inspecting to create a translator fortype
- is the generic type of the field (or field component). For example, examining a field of type
ListCopyright © 2013. All Rights Reserved.