public interface Matcher
org.infinispan.query.dsl
). The matching filters are notified via a callback supplied when
registering the filter. The filter will have to specify the fully qualified type name of the matching object because
simple names cannot be easily resolved as it would happen in the case of an EntityManager that has knowledge of all
types in advance.Modifier and Type | Method and Description |
---|---|
ObjectFilter |
getObjectFilter(FilterSubscription filterSubscription)
Obtains an ObjectFilter instance that is capable of testing a single filter condition.
|
ObjectFilter |
getObjectFilter(Query query) |
ObjectFilter |
getObjectFilter(String jpaQuery) |
QueryFactory<Query> |
getQueryFactory()
Creates a QueryFactory capable of creating DSL based queries that are accepted by this Matcher instance as
arguments for the registerFilter and getObjectFilter methods.
|
void |
match(Object instance)
Test the given instance against all the subscribed filters and notify all callbacks registered for instances of
the same type.
|
FilterSubscription |
registerFilter(Query query,
FilterCallback callback) |
FilterSubscription |
registerFilter(String jpaQuery,
FilterCallback callback) |
void |
unregisterFilter(FilterSubscription filterSubscription) |
QueryFactory<Query> getQueryFactory()
FilterSubscription registerFilter(Query query, FilterCallback callback)
FilterSubscription registerFilter(String jpaQuery, FilterCallback callback)
void unregisterFilter(FilterSubscription filterSubscription)
void match(Object instance)
instance
- the object to test against the registered filters; never nullObjectFilter getObjectFilter(FilterSubscription filterSubscription)
filterSubscription
- a filter subscription previously registered with this Matcher; the newly created
ObjectFilter will be based on the same filter conditionObjectFilter getObjectFilter(Query query)
ObjectFilter getObjectFilter(String jpaQuery)
Copyright © 2015 JBoss, a division of Red Hat. All rights reserved.