public class CriteriaBuilderHelper extends Object
Constructor and Description |
---|
CriteriaBuilderHelper(Class<?> entityType,
Class<?>... aliasTypes)
Constructor used to instantiate new objects.
|
Modifier and Type | Method and Description |
---|---|
static String |
decode(String string) |
void |
dump()
Dumps all the entities data to System.out.
|
static String |
encode(String string) |
Set<String> |
getEntities()
Returns the entities used in this instance.
|
Class<?> |
getTypeOfProperty(String property)
Returns the type of a given property.
|
void |
parseConfiguration(CriteriaBuilder criteriaBuilder,
String configurationString)
This method parses a criteria configuration and adds the given restrictions to the
CriteriaBuilder instance. |
Object |
parseCriteriaValue(Class<?> clazz,
String value)
This method is used for parsing a criteria value.
|
void |
setCriteriaParser(Class<?> clazz,
CriteriaParser<?> criteriaParser)
Sets a
CriteriaParser for a given class. |
public Object parseCriteriaValue(Class<?> clazz, String value)
clazz
- the type classvalue
- the value to be parsedpublic Class<?> getTypeOfProperty(String property)
property
- the property to search forpublic void setCriteriaParser(Class<?> clazz, CriteriaParser<?> criteriaParser)
CriteriaParser
for a given class.clazz
- the class to be usedcriteriaParser
- the CriteriaParser
to handle data for the classpublic void parseConfiguration(CriteriaBuilder criteriaBuilder, String configurationString)
CriteriaBuilder
instance.criteriaBuilder
- the CriteriaBuilder
to be usedconfigurationString
- the criteria configuration stringpublic void dump()
Copyright © 2020. All rights reserved.