public final class PreQueryContext
extends java.lang.Object
CallbackContext
implementation that is specific to
intercepted queries. Methods annotated with that receive
instances of this class may modify the
Query
returned by calling
getCurrentElement()
. This is an effective way to modify queries
prior to execution.
Modifier and Type | Method and Description |
---|---|
T
|
getCurrentElement
()
|
int
|
getCurrentIndex
()
|
Transaction
|
getCurrentTransaction
()
|
java.util.List<T>
|
getElements
()
|
public java.util.List<T> getElements()
getElements
in interface
CallbackContext
<T>
public Transaction getCurrentTransaction()
getCurrentTransaction
in interface
CallbackContext
<T>
null
if there is no current
transaction.
public int getCurrentIndex()
getCurrentIndex
in interface
CallbackContext
<T>
CallbackContext.getElements()
of the element
for which the callback has been invoked.
public T getCurrentElement()
getCurrentElement
in interface
CallbackContext
<T>
getElements().getCurrentIndex()
.