Java Doc for SelectQuery.java in  » EJB-Server-resin-3.1.5 » resin » com » caucho » amber » query » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » EJB Server resin 3.1.5 » resin » com.caucho.amber.query 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.caucho.amber.query.AbstractQuery
      com.caucho.amber.query.SelectQuery

SelectQuery
public class SelectQuery extends AbstractQuery (Code)
Represents an Amber select query



Constructor Summary
 SelectQuery(String query, JdbcMetaData metaData)
    

Method Summary
public  booleanexists(FromItem item)
     Returns true if the item must have at least one entry in the database.
public  StringgenerateLoadSQL()
    
public  StringgenerateLoadSQL(boolean fullSelect)
     Generates the load SQL.
Parameters:
  fullSelect - true if the load entity expressionsshould be fully loaded for all entityfields.
public  longgetCacheMaxAge()
     Returns the expire time.
public  ClassgetConstructorClass()
     Gets the constructor class for SELECT NEW.
 Map<AmberExpr, String>getJoinFetchMap()
     Gets the (join) fetch map.
public  intgetLimit()
     Gets the LIMIT value.
public  intgetOffset()
     Gets the OFFSET value.
public  AbstractQuerygetParentQuery()
     Gets the parent query.
 intgetResultCount()
     Returns the result type.
public  ArrayList<AmberExpr>getResultList()
     Returns the result list.
 TypegetResultType(int index)
     Returns the result type.
public  StringgetSQL()
    
 voidinit()
     initializes the query.
public  booleaninvalidateTable(String table)
     Returns true if modifying the given table modifies a cached query.
public  booleanisCacheable()
     Returns true for cacheable queries.
public  booleanisTableReadOnly()
    
 voidreplaceJoin(JoinExpr join)
    
 voidsetConstructorClass(Class cl)
     Sets the constructor class for SELECT NEW.
 voidsetDistinct(boolean isDistinct)
     Sets true if distinct.
 voidsetGroupList(ArrayList<AmberExpr> groupList)
     Sets the group by list.
 voidsetHasFrom(boolean hasFrom)
     Sets whether the query has a FROM clause or not.
 voidsetHaving(AmberExpr expr)
    
 voidsetJoinFetchMap(Map<AmberExpr, String> joinFetchMap)
     Sets the (join) fetch map.
public  voidsetLimit(int limit)
     Sets the LIMIT value.
public  voidsetOffset(int offset)
     Sets the OFFSET value.
 voidsetOrderList(ArrayList<AmberExpr> orderList, ArrayList<Boolean> ascList)
     Sets the order by list.
 voidsetParentQuery(AbstractQuery parent)
     Sets the parent query.
 voidsetResultList(ArrayList<AmberExpr> resultList)
     Sets the result list.
 voidsetWhere(AmberExpr expr)
    
public  StringtoString()
     Debug view.
public  booleanusesFrom(FromItem item, int type)
     Returns true if the from item is used by the query.


Constructor Detail
SelectQuery
SelectQuery(String query, JdbcMetaData metaData)(Code)




Method Detail
exists
public boolean exists(FromItem item)(Code)
Returns true if the item must have at least one entry in the database.



generateLoadSQL
public String generateLoadSQL()(Code)



generateLoadSQL
public String generateLoadSQL(boolean fullSelect)(Code)
Generates the load SQL.
Parameters:
  fullSelect - true if the load entity expressionsshould be fully loaded for all entityfields. Otherwise, only the entity idwill be loaded: select o.id from ...It is implemented to optimize the SQLand allow for databases that onlysupport single columns in subqueries.Derby is an example. An additionalcondition to generate only the o.idis the absence of group by. If thereis a group by the full select willalways be generated.See also com.caucho.amber.expr.ExistsExpr the load SQL.



getCacheMaxAge
public long getCacheMaxAge()(Code)
Returns the expire time.



getConstructorClass
public Class getConstructorClass()(Code)
Gets the constructor class for SELECT NEW.



getJoinFetchMap
Map<AmberExpr, String> getJoinFetchMap()(Code)
Gets the (join) fetch map.



getLimit
public int getLimit()(Code)
Gets the LIMIT value.



getOffset
public int getOffset()(Code)
Gets the OFFSET value.



getParentQuery
public AbstractQuery getParentQuery()(Code)
Gets the parent query.



getResultCount
int getResultCount()(Code)
Returns the result type.



getResultList
public ArrayList<AmberExpr> getResultList()(Code)
Returns the result list.



getResultType
Type getResultType(int index)(Code)
Returns the result type.



getSQL
public String getSQL()(Code)
Returns the id load sql



init
void init() throws QueryParseException(Code)
initializes the query.



invalidateTable
public boolean invalidateTable(String table)(Code)
Returns true if modifying the given table modifies a cached query.



isCacheable
public boolean isCacheable()(Code)
Returns true for cacheable queries.



isTableReadOnly
public boolean isTableReadOnly()(Code)
Are the tables read-only



replaceJoin
void replaceJoin(JoinExpr join)(Code)



setConstructorClass
void setConstructorClass(Class cl)(Code)
Sets the constructor class for SELECT NEW.



setDistinct
void setDistinct(boolean isDistinct)(Code)
Sets true if distinct.



setGroupList
void setGroupList(ArrayList<AmberExpr> groupList)(Code)
Sets the group by list.



setHasFrom
void setHasFrom(boolean hasFrom)(Code)
Sets whether the query has a FROM clause or not.



setHaving
void setHaving(AmberExpr expr)(Code)
Sets the having expression



setJoinFetchMap
void setJoinFetchMap(Map<AmberExpr, String> joinFetchMap)(Code)
Sets the (join) fetch map.



setLimit
public void setLimit(int limit)(Code)
Sets the LIMIT value.



setOffset
public void setOffset(int offset)(Code)
Sets the OFFSET value.



setOrderList
void setOrderList(ArrayList<AmberExpr> orderList, ArrayList<Boolean> ascList)(Code)
Sets the order by list.



setParentQuery
void setParentQuery(AbstractQuery parent)(Code)
Sets the parent query.



setResultList
void setResultList(ArrayList<AmberExpr> resultList)(Code)
Sets the result list.



setWhere
void setWhere(AmberExpr expr)(Code)
Sets the where expression



toString
public String toString()(Code)
Debug view.



usesFrom
public boolean usesFrom(FromItem item, int type)(Code)
Returns true if the from item is used by the query.



Fields inherited from com.caucho.amber.query.AbstractQuery
protected HashMap<String, EmbeddedExpr> _embeddedAliases(Code)(Java Doc)
protected ArrayList<FromItem> _fromList(Code)(Java Doc)
AmberExpr _having(Code)(Java Doc)
AmberExpr _where(Code)(Java Doc)

Methods inherited from com.caucho.amber.query.AbstractQuery
public void addEmbeddedAlias(String alias, EmbeddedExpr expr)(Code)(Java Doc)
public void complete(UserQuery userQuery, AmberConnection aConn) throws SQLException(Code)(Java Doc)
public FromItem createDependentFromItem(FromItem parent, LinkColumns link, String name)(Code)(Java Doc)
public FromItem createFromItem(Table table, String name)(Code)(Java Doc)
public FromItem createFromItem(EntityType entityType, Table table, String name)(Code)(Java Doc)
public boolean exists(FromItem item)(Code)(Java Doc)
public ArgExpr[] getArgList()(Code)(Java Doc)
public long getCacheMaxAge()(Code)(Java Doc)
public HashMap<String, EmbeddedExpr> getEmbeddedAliases()(Code)(Java Doc)
public ArrayList<FromItem> getFromList()(Code)(Java Doc)
JdbcMetaData getMetaData()(Code)(Java Doc)
public AbstractQuery getParentQuery()(Code)(Java Doc)
public ArrayList<String> getPreparedMapping()(Code)(Java Doc)
public String getQueryString()(Code)(Java Doc)
abstract public String getSQL()(Code)(Java Doc)
public boolean hasSubQuery()(Code)(Java Doc)
void init() throws QueryParseException(Code)(Java Doc)
boolean isFromInnerJoin(FromItem item)(Code)(Java Doc)
boolean isJoinParent(FromItem item)(Code)(Java Doc)
public void prepare(UserQuery userQuery, AmberConnection aConn) throws SQLException(Code)(Java Doc)
void registerUpdates(CachedQuery query)(Code)(Java Doc)
void replaceJoin(JoinExpr join)(Code)(Java Doc)
boolean setArgList(ArgExpr[] argList)(Code)(Java Doc)
public void setHasSubQuery(boolean hasSubQuery)(Code)(Java Doc)
public boolean usesFrom(FromItem item, int type)(Code)(Java Doc)
boolean usesFromData(FromItem item)(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.