Package mc.core.domain.base.aspect
Interface AspectAttribute.DataValueHandler<V>
- All Known Implementing Classes:
AspectAttribute.DVAssetHandler,AspectAttribute.DVBaseHandler,AspectAttribute.DVBooleanHandler,AspectAttribute.DVDateHandler,AspectAttribute.DVNumericHandler,AspectAttribute.DVPatternHandler,AspectAttribute.DVPriceHandler,AspectAttribute.DVTextHandler
- Enclosing class:
- AspectAttribute<C extends ComplexEntity>
public static interface AspectAttribute.DataValueHandler<V>
generic interface defining handler API, avoiding complex generic type declaration of
DVBaseHandler-
Method Summary
Modifier and TypeMethodDescriptiondefault <I extends AspectAttribute.DataValueHandler>
Optional<I>check if we have a handler of the given class, cast and return Optional of it.setFromString(String value) setFromString(String value, Locale locale) setMultiValueAppend(boolean append) setTerritory(Territory territory) setValue(DataValueTO dataValueTO)
-
Method Details
-
setValue
AspectAttribute.DataValueHandler setValue(V value) throws mc.core.system.validation.ValidationException - Throws:
mc.core.system.validation.ValidationException
-
setValues
AspectAttribute.DataValueHandler setValues(List<V> values) throws mc.core.system.validation.ValidationException - Throws:
mc.core.system.validation.ValidationException
-
setFromString
AspectAttribute.DataValueHandler setFromString(String value) throws mc.core.system.validation.ValidationException - Throws:
mc.core.system.validation.ValidationException
-
setFromString
AspectAttribute.DataValueHandler setFromString(String value, Locale locale) throws mc.core.system.validation.ValidationException - Throws:
mc.core.system.validation.ValidationException
-
setValue
AspectAttribute.DataValueHandler setValue(DataValueTO dataValueTO) throws mc.core.system.validation.ValidationException - Throws:
mc.core.system.validation.ValidationException
-
setMultiValueAppend
-
setTerritory
-
instance
check if we have a handler of the given class, cast and return Optional of it. Return empty Optional if this is a different handler class. Can be used to downcast the handler base class to the handler subclass in order to call specialized methods on the subclass.- Parameters:
handlerClass-- Returns:
- Optional of this handler instance if it is of the given class. otherwise empty Optional
-