Package org.cxbox.core.util.filter
Annotation Type SearchParameter
-
@Target(FIELD) @Retention(RUNTIME) public @interface SearchParameter
Enables filtration by the annotated field ofDataResponseDTO. Configures the rules and parameters for filtering by field.
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description Class<? extends ClassifyDataProvider>multiFieldKeyUsed only for fields ofMultivalueFieldtype and is necessary to correctly type string representation of filtering parameter.StringnameA path to the field on a JPA entity on which filtering will be performed.Class<? extends ClassifyDataProvider>providerGet a provider for defining of classify data parameter in sorting or searching cases.booleanstrictWhether to filter by datetime as-is.booleansuppressProcessWhether to block the mechanism at the Cxbox level or not.
-
-
-
Element Detail
-
name
String name
A path to the field on a JPA entity on which filtering will be performed. For collections annotated withElementCollectionprovide a path to the collection field itself. For collections annotated withOneToManyprovide a path to the association entity field.- Returns:
- Dot notation path e.g. entityField.associationField.
- Default:
- ""
-
-
-
strict
boolean strict
Whether to filter by datetime as-is. If not strict, datetime filtering will be done by the value at the beginning or end of the day for the LESS THAN and GREATER THAN operators, respectively. If strict, filtering will be done by the actual filter value.- Returns:
- Whether to apply strict filtering or not.
- Default:
- false
-
-
-
suppressProcess
boolean suppressProcess
Whether to block the mechanism at the Cxbox level or not. If blocked, filtering should be implemented at the level of services that manage the entity. By default, the Cxbox filter is not blocked.- Returns:
- Whether to block the mechanism at the cxbox level or not
- Default:
- false
-
-
-
multiFieldKey
Class<? extends ClassifyDataProvider> multiFieldKey
Used only for fields ofMultivalueFieldtype and is necessary to correctly type string representation of filtering parameter.- Returns:
- ClassifyDataProvider which could be applied to the key(id) of
MultivalueFieldSingleValue. E.g. the key is stringified date, then we should useDateValueProvider
- Default:
- org.cxbox.core.util.filter.provider.impl.LongValueProvider.class
-
-
-
provider
Class<? extends ClassifyDataProvider> provider
Get a provider for defining of classify data parameter in sorting or searching cases. Necessary to correctly type string representation of filtering parameter.- Returns:
- ClassifyDataProvider
- Default:
- org.cxbox.core.util.filter.provider.impl.StringValueProvider.class
-
-