java.lang.Object
org.apache.hivemind.schema.rules.SmartTranslator
- All Implemented Interfaces:
- org.apache.hivemind.schema.Translator
- public class SmartTranslator
- extends java.lang.Object
- implements org.apache.hivemind.schema.Translator
A "smart" translator that attempts to automatically convert from string types to object or
wrapper types, using java.beans.PropertyEditors.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_default
private java.lang.String _default
SmartTranslator
public SmartTranslator()
SmartTranslator
public SmartTranslator(java.lang.String initializer)
- Initializers:
- default: default value for empty input
translate
public java.lang.Object translate(org.apache.hivemind.internal.Module contributingModule,
java.lang.Class propertyType,
java.lang.String inputValue,
org.apache.hivemind.Location location)
- Description copied from interface:
org.apache.hivemind.schema.Translator
- Invoked by a org.apache.hivemind.schema.Rule
to translate an inputValue into an appropriate object.
Substitution symbols will already have been expanded before this method is
invoked.
- Specified by:
translate in interface org.apache.hivemind.schema.Translator