1 // Copyright 2012 Google. All Rights Reserved.
2 package com
.google
.appengine
.api
.datastore
;
4 import java
.util
.Arrays
;
7 * Concrete {@link CallbackContext} implementation that is specific to
8 * intercepted queries. Methods annotated with {@PreQuery} that receive
9 * instances of this class may modify the {@link Query} returned by calling
10 * {@link #getCurrentElement()}. This is an effective way to modify queries
14 public final class PreQueryContext
extends BaseCallbackContext
<Query
> {
16 PreQueryContext(CurrentTransactionProvider currentTransactionProvider
, Query query
) {
17 super(currentTransactionProvider
, Arrays
.asList(new Query(query
)));
21 String
getKind(Query query
) {
22 return query
.getKind();