Class CurrencyConstraint
java.lang.Object
org.alfresco.repo.dictionary.constraint.AbstractConstraint
org.alfresco.repo.dictionary.constraint.ListOfValuesConstraint
fr.becpg.repo.dictionary.constraint.CurrencyConstraint
- All Implemented Interfaces:
org.alfresco.service.cmr.dictionary.Constraint
public class CurrencyConstraint
extends org.alfresco.repo.dictionary.constraint.ListOfValuesConstraint
Class used to load supported currencies constraints
- Version:
- $Id: $Id
- Author:
- rabah
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static BeCPGCacheServiceprivate static final Stringprivate static final Stringprivate static SystemConfigurationServicestatic final StringConstantUNDIFINED_CONSTRAINT_VALUE="-"Fields inherited from class org.alfresco.repo.dictionary.constraint.ListOfValuesConstraint
ALLOWED_VALUES_PARAM, CASE_SENSITIVE_PARAM, caseSensitive, CONSTRAINT_TYPE, sorted, SORTED_PARAMFields inherited from class org.alfresco.repo.dictionary.constraint.AbstractConstraint
ERR_EVALUATE_EXCEPTION, ERR_PROP_NOT_SET -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidevaluateSingleValue(Object value) getAllowedValuesFromCache.getDisplayLabel(String constraintAllowableValue, org.alfresco.service.cmr.i18n.MessageLookup messageLookup) voidprivate static StringvoidsetAllowedValuesSuffix(List<String> allowedValuesSuffix) Setter for the fieldallowedValuesSuffix.voidsetBeCPGCacheService(BeCPGCacheService beCPGCacheService) Setter for the fieldbeCPGCacheService.voidsetSystemConfigurationService(SystemConfigurationService systemConfigurationService) Setter for the fieldsystemConfigurationService.Methods inherited from class org.alfresco.repo.dictionary.constraint.ListOfValuesConstraint
getParameters, getRawAllowedValues, getType, isCaseSensitive, isSorted, setAllowedValues, setCaseSensitive, setSorted, toStringMethods inherited from class org.alfresco.repo.dictionary.constraint.AbstractConstraint
checkPropertyNotNull, evaluate, evaluateCollection, getShortName, getTitle, set_shortName, setRegistry, setShortName, setTitle
-
Field Details
-
UNDIFINED_CONSTRAINT_VALUE
ConstantUNDIFINED_CONSTRAINT_VALUE="-"- See Also:
-
ERR_NON_STRING
- See Also:
-
ERR_INVALID_VALUE
- See Also:
-
beCPGCacheService
-
systemConfigurationService
-
allowedValuesSuffix
-
-
Constructor Details
-
CurrencyConstraint
public CurrencyConstraint()
-
-
Method Details
-
propConstraints
-
setBeCPGCacheService
Setter for the field
beCPGCacheService.- Parameters:
beCPGCacheService- aBeCPGCacheServiceobject.
-
setSystemConfigurationService
Setter for the field
systemConfigurationService.- Parameters:
systemConfigurationService- aSystemConfigurationServiceobject
-
setAllowedValuesSuffix
Setter for the field
allowedValuesSuffix.- Parameters:
allowedValuesSuffix- aListobject.
-
initialize
public void initialize()- Specified by:
initializein interfaceorg.alfresco.service.cmr.dictionary.Constraint- Overrides:
initializein classorg.alfresco.repo.dictionary.constraint.ListOfValuesConstraint
-
getAllowedValues
- Overrides:
getAllowedValuesin classorg.alfresco.repo.dictionary.constraint.ListOfValuesConstraint
-
getDisplayLabel
public String getDisplayLabel(String constraintAllowableValue, org.alfresco.service.cmr.i18n.MessageLookup messageLookup) - Overrides:
getDisplayLabelin classorg.alfresco.repo.dictionary.constraint.ListOfValuesConstraint
-
evaluateSingleValue
- Overrides:
evaluateSingleValuein classorg.alfresco.repo.dictionary.constraint.ListOfValuesConstraint
-
getAllowedValuesFromCache
getAllowedValuesFromCache.
- Returns:
- a
Listobject.
-