blob: 48b409479e4cf390bdaf7496f217f9a2ceefcce0 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.5.0_06) on Wed Jul 19 14:42:55 EDT 2006 -->
<TITLE>
org.objectstyle.cayenne.query (Cayenne API Documentation - v.1.2)
</TITLE>
<META NAME="keywords" CONTENT="org.objectstyle.cayenne.query package">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../objectstyle-javadoc.css" TITLE="Style">
<SCRIPT type="text/javascript">
function windowTitle()
{
parent.document.title="org.objectstyle.cayenne.query (Cayenne API Documentation - v.1.2)";
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>
</HEAD>
<BODY BGCOLOR="white" onload="windowTitle();">
<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../org/objectstyle/cayenne/property/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
&nbsp;<A HREF="../../../../org/objectstyle/cayenne/remote/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../index.html?org/objectstyle/cayenne/query/package-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
&nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
&nbsp;<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->
<HR>
<H2>
Package org.objectstyle.cayenne.query
</H2>
Defines standard queries supported by Cayenne and extension mechanism to create
custom queries.
<P>
<B>See:</B>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF="#package_description"><B>Description</B></A>
<P>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Interface Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/GenericSelectQuery.html" title="interface in org.objectstyle.cayenne.query">GenericSelectQuery</A></B></TD>
<TD><B>Deprecated.</B>&nbsp;<I>Since 1.2 this interface obsolete.</I></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/ParameterizedQuery.html" title="interface in org.objectstyle.cayenne.query">ParameterizedQuery</A></B></TD>
<TD>Defines a query that can serve as a template for other queries.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/PrefetchProcessor.html" title="interface in org.objectstyle.cayenne.query">PrefetchProcessor</A></B></TD>
<TD>A hierarchical visitor interface for traversing a tree of PrefetchTreeNodes.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/Query.html" title="interface in org.objectstyle.cayenne.query">Query</A></B></TD>
<TD>Defines minimal API of a query descriptor that is executable via Cayenne.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/QueryMetadata.html" title="interface in org.objectstyle.cayenne.query">QueryMetadata</A></B></TD>
<TD>Provides a common interface for accessing query metadata.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/QueryRouter.html" title="interface in org.objectstyle.cayenne.query">QueryRouter</A></B></TD>
<TD>An interface used by Queries to route themselves to an appropriate QueryEngine.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/SQLAction.html" title="interface in org.objectstyle.cayenne.query">SQLAction</A></B></TD>
<TD>Defines API for query execution strategy over JDBC connection (as in Strategy Pattern).</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/SQLActionVisitor.html" title="interface in org.objectstyle.cayenne.query">SQLActionVisitor</A></B></TD>
<TD>A factory interface to create standard SQLActions for a set of standard queries.</TD>
</TR>
</TABLE>
&nbsp;
<P>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Class Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/AbstractQuery.html" title="class in org.objectstyle.cayenne.query">AbstractQuery</A></B></TD>
<TD>A common superclass of Cayenne queries.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/BatchQuery.html" title="class in org.objectstyle.cayenne.query">BatchQuery</A></B></TD>
<TD>BatchQuery and its descendants allow to group similar data for the batch database
modifications, including inserts, updates and deletes.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/DeleteBatchQuery.html" title="class in org.objectstyle.cayenne.query">DeleteBatchQuery</A></B></TD>
<TD>Batched delete query.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/DeleteQuery.html" title="class in org.objectstyle.cayenne.query">DeleteQuery</A></B></TD>
<TD>&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/IndirectQuery.html" title="class in org.objectstyle.cayenne.query">IndirectQuery</A></B></TD>
<TD>A convenience superclass of the queries that resolve into some other queries during the
routing phase.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/InsertBatchQuery.html" title="class in org.objectstyle.cayenne.query">InsertBatchQuery</A></B></TD>
<TD>Batched INSERT query.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/InsertQuery.html" title="class in org.objectstyle.cayenne.query">InsertQuery</A></B></TD>
<TD><B>Deprecated.</B>&nbsp;<I>since 1.2 Object InsertQuery is not needed anymore.</I></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/NamedQuery.html" title="class in org.objectstyle.cayenne.query">NamedQuery</A></B></TD>
<TD>A query that is a reference to a named parameterized query stored in the mapping.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/ObjectIdQuery.html" title="class in org.objectstyle.cayenne.query">ObjectIdQuery</A></B></TD>
<TD>A query that matches zero or one object or data row corresponding to the ObjectId.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/Ordering.html" title="class in org.objectstyle.cayenne.query">Ordering</A></B></TD>
<TD>Defines object sorting criteria, used either for in-memory sorting of object lists or
as a specification for building <em>ORDER BY</em> clause of a SelectQuery query.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/PrefetchSelectQuery.html" title="class in org.objectstyle.cayenne.query">PrefetchSelectQuery</A></B></TD>
<TD>A SelectQuery to perform a prefetch based on another query.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/PrefetchTreeNode.html" title="class in org.objectstyle.cayenne.query">PrefetchTreeNode</A></B></TD>
<TD>Defines a node in a prefetch tree.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/ProcedureQuery.html" title="class in org.objectstyle.cayenne.query">ProcedureQuery</A></B></TD>
<TD>A query based on Procedure.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/QualifiedQuery.html" title="class in org.objectstyle.cayenne.query">QualifiedQuery</A></B></TD>
<TD>An abstract superclass of queries with Expression qualifiers.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/QueryChain.html" title="class in org.objectstyle.cayenne.query">QueryChain</A></B></TD>
<TD>A Query decorator for a collection of other queries.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/RelationshipQuery.html" title="class in org.objectstyle.cayenne.query">RelationshipQuery</A></B></TD>
<TD>A query that selects objects related to a given object.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/SelectQuery.html" title="class in org.objectstyle.cayenne.query">SelectQuery</A></B></TD>
<TD>A query that selects persistent objects of a certain type or "raw data" (aka DataRows).</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/SQLTemplate.html" title="class in org.objectstyle.cayenne.query">SQLTemplate</A></B></TD>
<TD>A query that executes unchanged (except for template preprocessing) "raw" SQL specified
by the user.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/UpdateBatchQuery.html" title="class in org.objectstyle.cayenne.query">UpdateBatchQuery</A></B></TD>
<TD>Batched UPDATE query.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD WIDTH="15%"><B><A HREF="../../../../org/objectstyle/cayenne/query/UpdateQuery.html" title="class in org.objectstyle.cayenne.query">UpdateQuery</A></B></TD>
<TD>Object encapsulating an UPDATE statement.</TD>
</TR>
</TABLE>
&nbsp;
<P>
<A NAME="package_description"><!-- --></A><H2>
Package org.objectstyle.cayenne.query Description
</H2>
<P>
Defines standard queries supported by Cayenne and extension mechanism to create
custom queries. Many of the queries in this package are used by the framework internally.
Normally users would only care about these general query classes:
<ul>
<li>SelectQuery</li>
<li>SQLTemplate</li>
<li>ProcedureQuery</li>
</ul>
and sometimes - these specialized queries:
<ul>
<li>QueryChain</li>
<li>RelationshipQuery</li>
<li>SingleObjectQuery</li>
</ul>
<p>Cayenne can "execute" any object as a query as long as it implements
Query interface and provides meaningful implementation of either <em>Query.route(...)</em>
and/or
<em>Query.createSQLAction(SQLActionVisitor)}</em> methods.
So users can extend/customize queries if they need to. Custom implementations would
normally either create a query from a standard Cayenne set
and delegate the execution to it (acting as a sort of "query builder"),
or can implement its own non-standard SQLAction.</p>
<P>
<P>
<DL>
</DL>
<HR>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../org/objectstyle/cayenne/property/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
&nbsp;<A HREF="../../../../org/objectstyle/cayenne/remote/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../index.html?org/objectstyle/cayenne/query/package-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
&nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
&nbsp;<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<HR>
<!--@SFLOGO@--> &nbsp; <i>Copyright &#169; 2001-2006 <a href=
"http://objectstyle.org" target="_top">ObjectStyle.org</a> All Rights Reserved.</i>
</BODY>
</HTML>