- java.lang.Object
-
- org.tentackle.fx.translate.AbstractValueTranslator<M,V>
-
- Type Parameters:
M- the model's typeV- the view's type
- All Implemented Interfaces:
ValueTranslator<M,V>
- Direct Known Subclasses:
EnumStringTranslator,IdentityTranslator,ObservableListTranslator,StringColorTranslator,ValueStringTranslator
public abstract class AbstractValueTranslator<M,V> extends java.lang.Object implements ValueTranslator<M,V>
Base class of a value translator.- Author:
- harald
-
-
Constructor Summary
Constructors Constructor Description AbstractValueTranslator(FxComponent component)Creates a string translator for a given text component.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FxComponentgetComponent()Gets the component.booleanisLenient()Returns whether parsing to model should be lenient.voidsetLenient(boolean lenient)Sets whether parsing to model should be lenient.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.tentackle.fx.ValueTranslator
bindingPropertiesUpdated, needsToModelTwice, toModel, toModelFunction, toView, toViewFunction
-
-
-
-
Constructor Detail
-
AbstractValueTranslator
public AbstractValueTranslator(FxComponent component)
Creates a string translator for a given text component.- Parameters:
component- the component
-
-
Method Detail
-
getComponent
public FxComponent getComponent()
Description copied from interface:ValueTranslatorGets the component.- Specified by:
getComponentin interfaceValueTranslator<M,V>- Returns:
- the component
-
isLenient
public boolean isLenient()
Description copied from interface:ValueTranslatorReturns whether parsing to model should be lenient.- Specified by:
isLenientin interfaceValueTranslator<M,V>- Returns:
- true if lenient, false is default
-
setLenient
public void setLenient(boolean lenient)
Sets whether parsing to model should be lenient.- Parameters:
lenient- true if lenient
-
-