@groovy.transform.CompileStatic final class TaackFilter<T extends GormEntity<T>> extends java.lang.Object
Service allowing to automatically filter data in a tableFilter. It is typically used in a table block. It uses params given from the UiFilterSpecifier to filter data.
The main methods are named TaackFilter.list<T>. The uniq mandatory parameter is the Class we want the list for. Optional params includes allowed ids or passing a filter directly allow to restrict the list of objects returned.
Modifiers | Name | Description |
---|---|---|
class |
TaackFilter.1 |
|
static class |
TaackFilter.FilterBuilder |
|
static enum |
TaackFilter.Order |
Type | Name and description |
---|---|
int |
max |
Constructor and description |
---|
TaackFilter
(TaackFilter.FilterBuilder filterBuilder, org.hibernate.SessionFactory sessionFactory, java.util.Map<java.lang.String, ? extends java.lang.Object> theParams) |
Type Params | Return Type | Name and description |
---|---|---|
|
final java.util.List<java.lang.Object> |
executeQuery(java.lang.String query, java.util.Map<java.lang.String, java.lang.Object> namedParams, java.lang.Integer max, java.lang.Integer offset) Helper method allowing to execute a query |
|
final java.lang.Long |
executeQueryUniqueResult(java.lang.Class aClass, java.util.Map<java.lang.String, java.lang.Object> namedParams, java.lang.String query, java.lang.Integer max, java.lang.Integer offset) Helper method allowing to execute a query, after a type, returning an uniq result. |
|
java.lang.String |
getOrderString() |
|
java.lang.String |
getSortString() |
|
final grails.util.Pair<java.util.List<T>, java.lang.Long> |
list(java.lang.Class<T> aClass, int max, UiFilterSpecifier filterSpecifier, T tInstance, FieldInfo[] fields, TaackFilter.Order order, java.util.Collection<java.lang.Long> idsInList) list entities and number of results |
|
final grails.util.Pair<java.util.List<T>, java.lang.Long> |
list() |
|
java.lang.String |
toString() |
Methods inherited from class | Name |
---|---|
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(), java.lang.Object#wait(long), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Helper method allowing to execute a query
max
- max number of resultsHelper method allowing to execute a query, after a type, returning an uniq result. @return
list entities and number of results
aClass
- type we want to listmax
- (optional) max number of resultsfilterSpecifier
- (optional) additional filter criteria that overrides the ones passed via paramstInstance
- (optional) object of the same class as aClass, allowing to add filter criteriasortableDirection
- (optional) sort parameteridsInList
- (optional) restrict the results to those idsGroovy Documentation