Uses of Interface
org.apache.cayenne.query.Query
Packages that use Query
Package
Description
Contains persistence APIs directly accessible by users.
Contains classes that make up Cayenne ORM stack.
Contains classes that handle JDBC interactions.
Contains database adapter API (DbAdapter) and its default implementation.
IBM DB2 DbAdapter.
Apache Derby DbAdapter.
FrontBase DbAdapter.
HSQLDB DbAdapter.
MySQL DbAdapter.
Oracle DbAdapter.
PostgreSQL DbAdapter.
MS SQLServer DbAdapter.
Contains O/R mapping classes that store relational database
metadata information and map it to Java classes.
Defines standard queries supported by Cayenne and extension mechanism to create
custom queries.
Contains classes an interfaces related to Cayenne remote object persistence features.
General utility classes.
-
Uses of Query in org.apache.cayenne
Methods in org.apache.cayenne with parameters of type QueryModifier and TypeMethodDescriptionstatic Object
Cayenne.objectForQuery
(ObjectContext context, Query query) Returns an object or a DataRow that is a result of a given query.DataChannel.onQuery
(ObjectContext originatingContext, Query query) Executes a query, using provided context to register persistent objects if query returns any objects.DataChannelFilter.onQuery
(ObjectContext originatingContext, Query query, DataChannelFilterChain filterChain) Deprecated.default QueryResponse
DataChannelFilter.onQuery
(ObjectContext originatingContext, Query query, DataChannelQueryFilterChain filterChain) Deprecated.Adapter method that allows to use old DataChannelFilter as new query filterdefault QueryResponse
DataChannelFilterChain.onQuery
(ObjectContext originatingContext, Query query) Deprecated.DataChannelQueryFilter.onQuery
(ObjectContext originatingContext, Query query, DataChannelQueryFilterChain filterChain) DataChannelQueryFilterChain.onQuery
(ObjectContext originatingContext, Query query) abstract QueryResponse
BaseContext.performGenericQuery
(Query query) ObjectContext.performGenericQuery
(Query query) Executes any kind of query providing the result in a form of QueryResponse.abstract List
BaseContext.performQuery
(Query query) ObjectContext.performQuery
(Query query) Executes a selecting query, returning a list of persistent objects or data rows. -
Uses of Query in org.apache.cayenne.access
Methods in org.apache.cayenne.access that return QueryModifier and TypeMethodDescriptionDataContextDelegate.willPerformGenericQuery
(DataContext context, Query query) Invoked before a Query is executed via DataContext.performGenericQuery.DataContextDelegate.willPerformQuery
(DataContext context, Query query) Invoked before a Query is executed via DataContext.performQuery.Methods in org.apache.cayenne.access with parameters of type QueryModifier and TypeMethodDescriptionprotected void
Performs initialization of the list of objects.void
OperationObserver.nextBatchCount
(Query query, int[] resultCount) Callback method invoked after a batch update is executed.void
Callback method invoked after an updating query is executed.void
OperationObserver.nextGeneratedRows
(Query query, ResultIterator<?> keys, List<ObjectId> idsToUpdate) Callback method invoked after each batch of generated values is read during an update.default void
OperationObserver.nextGeneratedRows
(Query query, ResultIterator<?> keys, ObjectId idToUpdate) Deprecated.void
OperationObserver.nextQueryException
(Query query, Exception ex) Callback method invoked on exceptions that happen during an execution of a specific query.void
Callback method invoked for each processed ResultSet.void
OperationObserver.nextRows
(Query q, ResultIterator<?> it) Callback method invoked for each opened ResultIterator.ClientServerChannel.onQuery
(ObjectContext context, Query query) DataContext.onQuery
(ObjectContext context, Query query) An implementation of aDataChannel
method that is used by child contexts to execute queries.DataDomain.onQuery
(ObjectContext originatingContext, Query query) Runs query returning generic QueryResponse.DataContext.performGenericQuery
(Query query) Executes a query returning a generic response.DataContext.performIteratedQuery
(Query query) Performs a single database select query returning result as a ResultIterator.int[]
DataContext.performNonSelectingQuery
(Query query) Performs a single database query that does not select rows.DataContext.performQuery
(Query query) Performs a single selecting query.DataContextDelegate.willPerformGenericQuery
(DataContext context, Query query) Invoked before a Query is executed via DataContext.performGenericQuery.DataContextDelegate.willPerformQuery
(DataContext context, Query query) Invoked before a Query is executed via DataContext.performQuery.Method parameters in org.apache.cayenne.access with type arguments of type QueryModifier and TypeMethodDescriptionvoid
DataDomain.performQueries
(Collection<? extends Query> queries, OperationObserver callback) Routes queries to appropriate DataNodes for execution.void
DataNode.performQueries
(Collection<? extends Query> queries, OperationObserver callback) Runs queries using Connection obtained from internal DataSource.void
QueryEngine.performQueries
(Collection<? extends Query> queries, OperationObserver resultConsumer) Executes a list of queries wrapping them in its own transaction.Constructors in org.apache.cayenne.access with parameters of type QueryModifierConstructorDescriptionIncrementalFaultList
(DataContext dataContext, Query query, int maxFetchSize) Creates a new IncrementalFaultList using a given DataContext and query. -
Uses of Query in org.apache.cayenne.access.flush
Methods in org.apache.cayenne.access.flush that return types with arguments of type QueryModifier and TypeMethodDescriptionDefaultDataDomainFlushAction.createQueries
(List<DbRowOp> dbRowOps) Method parameters in org.apache.cayenne.access.flush with type arguments of type QueryModifier and TypeMethodDescriptionprotected void
DefaultDataDomainFlushAction.executeQueries
(List<? extends Query> queries) Execute queries, grouping them by nodes -
Uses of Query in org.apache.cayenne.access.jdbc
Methods in org.apache.cayenne.access.jdbc with parameters of type QueryModifier and TypeMethodDescriptionprotected void
BaseSQLAction.readResultSet
(ResultSet resultSet, RowDescriptor descriptor, Query query, OperationObserver delegate) Helper method to process a ResultSet. -
Uses of Query in org.apache.cayenne.access.util
Fields in org.apache.cayenne.access.util with type parameters of type QueryMethods in org.apache.cayenne.access.util that return types with arguments of type QueryModifier and TypeMethodDescriptionDefaultOperationObserver.getQueryExceptions()
Returns a list of exceptions that occured during data operation run by query.Methods in org.apache.cayenne.access.util with parameters of type QueryModifier and TypeMethodDescriptionvoid
DefaultOperationObserver.nextBatchCount
(Query query, int[] resultCount) void
DoNothingOperationObserver.nextBatchCount
(Query query, int[] resultCount) void
void
void
DefaultOperationObserver.nextGeneratedRows
(Query query, ResultIterator<?> keys, List<ObjectId> idsToUpdate) Closes ResultIterator without reading its data.void
DoNothingOperationObserver.nextGeneratedRows
(Query query, ResultIterator<?> keys, List<ObjectId> idsToUpdate) void
DefaultOperationObserver.nextQueryException
(Query query, Exception ex) void
DoNothingOperationObserver.nextQueryException
(Query query, Exception ex) void
void
DefaultOperationObserver.nextRows
(Query query, ResultIterator it) Closes ResultIterator without reading its data.void
void
DoNothingOperationObserver.nextRows
(Query q, ResultIterator<?> it) void
void
IteratedSelectObserver.nextRows
(Query q, ResultIterator it) -
Uses of Query in org.apache.cayenne.dba
Methods in org.apache.cayenne.dba with parameters of type QueryModifier and TypeMethodDescriptionReturns an instance of SQLAction that should handle the query.Uses JdbcActionBuilder to create the right action. -
Uses of Query in org.apache.cayenne.dba.db2
Methods in org.apache.cayenne.dba.db2 with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.derby
Methods in org.apache.cayenne.dba.derby with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.firebird
Methods in org.apache.cayenne.dba.firebird with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.frontbase
Methods in org.apache.cayenne.dba.frontbase with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.h2
Methods in org.apache.cayenne.dba.h2 with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.hsqldb
Methods in org.apache.cayenne.dba.hsqldb with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.ingres
Methods in org.apache.cayenne.dba.ingres with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.mysql
Methods in org.apache.cayenne.dba.mysql with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.oracle
Methods in org.apache.cayenne.dba.oracle with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.postgres
Methods in org.apache.cayenne.dba.postgres with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.sqlite
Methods in org.apache.cayenne.dba.sqlite with parameters of type Query -
Uses of Query in org.apache.cayenne.dba.sqlserver
Methods in org.apache.cayenne.dba.sqlserver with parameters of type Query -
Uses of Query in org.apache.cayenne.map
Methods in org.apache.cayenne.map that return QueryModifier and TypeMethodDescriptionQueryDescriptor.buildQuery()
Assembles Cayenne query instance of appropriate type from this descriptor. -
Uses of Query in org.apache.cayenne.query
Subinterfaces of Query in org.apache.cayenne.queryModifier and TypeInterfaceDescriptioninterface
Defines a query that can serve as a template for other queries.interface
Select<T>
A common interface for grouping together different kinds of queries that return results.Classes in org.apache.cayenne.query that implement QueryModifier and TypeClassDescriptionclass
class
A common superclass of Cayenne queries.class
BatchQuery and its descendants allow to group similar data for the batch database modifications, including inserts, updates and deletes.class
Shared functionality for cacheable queries.class
ColumnSelect<T>
A helper builder for queries selecting individual properties based on the root object.class
Batched delete query.class
An EJBQL query representation in Cayenne.class
FluentSelect<T>
Base class forObjectSelect
andColumnSelect
class
A base superclass for queries that resolve into some other queries during the routing phase.class
Batched INSERT query.class
A query that represents a named parameterized non selecting query stored in the mapping.class
MappedSelect<T>
A query that represents a named parameterized selecting query stored in the mapping.class
A query that matches zero or one object or data row corresponding to the ObjectId.class
ObjectSelect<T>
A selecting query providing chainable API.class
A SelectQuery to perform a prefetch based on another query.class
Fluent API for calling stored procedures.class
A query based on Procedure.class
A Query decorator for a collection of other queries.class
A query that allows to explicitly clear both object and list caches either via refetch (eager refresh) or invalidate (lazy refresh).class
A query that selects objects related to a given object via a mapped relationship.class
SelectById<T>
A query to select objects by id.class
SelectQuery<T>
Deprecated.since 4.2, useObjectSelect
class
A generic query based on raw SQL and featuring fluent API.class
SQLSelect<T>
A selecting query based on raw SQL and featuring fluent API.class
A query that executes unchanged (except for template preprocessing) "raw" SQL specified by the user.class
Batched UPDATE query.Fields in org.apache.cayenne.query declared as QueryModifier and TypeFieldDescriptionprotected Query
RefreshQuery.query
protected Query
IndirectQuery.replacementQuery
Fields in org.apache.cayenne.query with type parameters of type QueryMethods in org.apache.cayenne.query that return QueryModifier and TypeMethodDescriptionObjectSelect.createQuery
(Map<String, ?> parameters) This method is intended for internal use in aMappedSelect
.ParameterizedQuery.createQuery
(Map<String, ?> parameters) Creates a new query based on current query as a template, and using a Map of named parameters.ProcedureQuery.createQuery
(Map<String, ?> parameters) Creates and returns a new ProcedureQuery built using this query as a prototype and substituting template parameters with the values from the map.SQLTemplate.createQuery
(Map<String, ?> parameters) Creates and returns a new SQLTemplate built using this query as a prototype and substituting template parameters with the values from the map.protected Query
AbstractMappedQuery.createReplacementQuery
(EntityResolver resolver) protected abstract Query
IndirectQuery.createReplacementQuery
(EntityResolver resolver) Creates a substitute query.protected Query
MappedSelect.createReplacementQuery
(EntityResolver resolver) protected Query
ObjectIdQuery.createReplacementQuery
(EntityResolver resolver) protected Query
ProcedureCall.createReplacementQuery
(EntityResolver resolver) protected Query
RelationshipQuery.createReplacementQuery
(EntityResolver resolver) protected Query
SelectById.createReplacementQuery
(EntityResolver resolver) protected Query
SQLExec.createReplacementQuery
(EntityResolver resolver) protected Query
SQLSelect.createReplacementQuery
(EntityResolver resolver) QueryMetadata.getOriginatingQuery()
Returns a query that originated this query.QueryMetadataProxy.getOriginatingQuery()
RefreshQuery.getQuery()
Returns an internal query, overriding cache policy to force a refresh.protected Query
IndirectQuery.getReplacementQuery
(EntityResolver resolver) Returns a replacement query, creating it on demand and caching it for reuse.Methods in org.apache.cayenne.query with parameters of type QueryModifier and TypeMethodDescriptionvoid
Adds a query to the chain.boolean
QueryChain.removeQuery
(Query query) Removes a query from the chain, returning true if the query was indeed present in the chain and was removed.void
AbstractQuery.route
(QueryRouter router, EntityResolver resolver, Query substitutedQuery) Implements default routing mechanism relying on the EntityResolver to find DataMap based on the query root.void
BatchQuery.route
(QueryRouter router, EntityResolver resolver, Query substitutedQuery) void
EJBQLQuery.route
(QueryRouter router, EntityResolver resolver, Query substitutedQuery) void
FluentSelect.route
(QueryRouter router, EntityResolver resolver, Query substitutedQuery) void
IndirectQuery.route
(QueryRouter router, EntityResolver resolver, Query substitutedQuery) Delegates routing to a replacement query.void
Query.route
(QueryRouter router, EntityResolver resolver, Query substitutedQuery) A callback method invoked by Cayenne during the routing phase of the query execution.void
QueryChain.route
(QueryRouter router, EntityResolver resolver, Query substitutedQuery) Delegates routing to each individual query in the chain.void
QueryRouter.route
(QueryEngine engine, Query query, Query substitutedQuery) A callback method that allows a query to set its preferred engine during the routing phase.void
RefreshQuery.route
(QueryRouter router, EntityResolver resolver, Query substitutedQuery) void
SelectQuery.route
(QueryRouter router, EntityResolver resolver, Query substitutedQuery) Deprecated.Routes itself and if there are any prefetches configured, creates prefetch queries and routes them as well.void
SQLTemplate.route
(QueryRouter router, EntityResolver resolver, Query substitutedQuery) Constructors in org.apache.cayenne.query with parameters of type QueryModifierConstructorDescriptionQueryChain
(Query[] queries) Creates a new QueryChain out of an array of queries.RefreshQuery
(Query query) Creates a RefreshQuery that refreshes results of a query and individual objects in the result.Constructor parameters in org.apache.cayenne.query with type arguments of type QueryModifierConstructorDescriptionQueryChain
(Collection<? extends Query> queries) Creates a new QueryChain with a collection of Queries. -
Uses of Query in org.apache.cayenne.remote
Methods in org.apache.cayenne.remote with parameters of type Query -
Uses of Query in org.apache.cayenne.util
Fields in org.apache.cayenne.util declared as QueryConstructors in org.apache.cayenne.util with parameters of type QueryModifierConstructorDescriptionObjectContextQueryAction
(ObjectContext actingContext, ObjectContext targetContext, Query query)
OperationObserver.nextGeneratedRows(Query, ResultIterator, List)