Class DataDrivenEnumVariableExpression
java.lang.Object
org.broadleafcommerce.common.web.expression.DataDrivenEnumVariableExpression
- All Implemented Interfaces:
BroadleafVariableExpression
@Component("blDataDrivenEnumVariableExpression")
@ConditionalOnTemplating
public class DataDrivenEnumVariableExpression
extends Object
implements BroadleafVariableExpression
Variable expression that looks up a list of
DataDrivenEnumerationValues based on its enum key- Author:
- Phillip Verheyden (phillipuniverse)
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetEnumValues(String key) Looks up a list ofDataDrivenEnumerationValueby theDataDrivenEnumeration.getKey()specified by keygetEnumValues(String key, String sort) Looks up a list ofDataDrivenEnumerationValueby theDataDrivenEnumeration.getKey()specified by keygetName()
-
Field Details
-
enumService
-
-
Constructor Details
-
DataDrivenEnumVariableExpression
public DataDrivenEnumVariableExpression()
-
-
Method Details
-
getName
- Specified by:
getNamein interfaceBroadleafVariableExpression
-
getEnumValues
Looks up a list ofDataDrivenEnumerationValueby theDataDrivenEnumeration.getKey()specified by key- Parameters:
key- lookup for theDataDrivenEnumeration- Returns:
- the list of
DataDrivenEnumerationValuefor the given key
-
getEnumValues
Looks up a list ofDataDrivenEnumerationValueby theDataDrivenEnumeration.getKey()specified by key- Parameters:
key- lookup for theDataDrivenEnumerationsort- optional, either 'ASCENDING' or 'DESCENDING' depending on how you want the result list sorted- Returns:
- the list of
DataDrivenEnumerationValuefor the given key
-