Java Doc for StatementContext.java in  » Database-DBMS » db-derby-10.2 » org » apache » derby » iapi » sql » conn » 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 » Database DBMS » db derby 10.2 » org.apache.derby.iapi.sql.conn 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.apache.derby.iapi.sql.conn.StatementContext

All known Subclasses:   org.apache.derby.impl.sql.conn.GenericStatementContext,
StatementContext
public interface StatementContext extends Context(Code)
StatementContext keeps the context for a statement.




Method Summary
public  voidaddDependency(Dependency dy)
     Track a Dependency within this StatementContext.
public  voidcancel()
     Indicate that the statement which has allocated this statement context should cancel its execution.
public  voidclearInUse()
     Mark this context as not in use.
public  voidclearSavePoint()
     Clear the save point for the current statement.
public  shortgetSQLAllowed()
     Get the setting of the SQL allowed state.
public  StringgetStatementText()
     Return the text of the current statement. Note that this may be null.
public  NoPutResultSet[]getSubqueryTrackingArray()
     Get the subquery tracking array for this query.
public  booleangetSystemCode()
     Return true if this statement is system code.
public  booleaninTrigger()
     Returns whether we started from within the context of a trigger or not.
public  booleaninUse()
     Is this statement context in use or not.
public  booleanisAtomic()
     Indicates whether the statement needs to be executed atomically or not, i.e., whether a commit/rollback is permitted by a connection nested in this statement.
public  booleanisCancelled()
     Checks if the statement which has allocated this statement context should cancel its execution.
public  booleanisForReadOnly()
    
public  booleanonStack()
     Reports whether this StatementContext is on the context stack. true if this StatementContext is on the context stack.
public  voidresetSavePoint()
     If this statement context has a savepoint, then it is reset to the current point.
public  voidsetInUse(boolean inTrigger, boolean isAtomic, boolean isForReadOnly, String stmtText, ParameterValueSet pvs, long timeoutMillis)
     Mark this context as being in use.
Parameters:
  inTrigger - true if the parent started in the context of a trigger
Parameters:
  isAtomic - true if the statement must be executedatomically
Parameters:
  isForReadOnly - true if the statement is for producing non-updatableresultset
Parameters:
  stmtText - the text of the statement.
public  voidsetParentRollback()
     Indicate that, in the event of a statement-level exception, this context is NOT the last one that needs to be rolled back--rather, it is nested within some other statement context, and that other context needs to be rolled back, too.
public  voidsetSQLAllowed(short allow, boolean force)
     Set the level of SQL allowed in this and subsequent nested statements due to a routine call.
public  voidsetSavePoint()
     Set a save point for the current statement.
public  voidsetSubqueryResultSet(int subqueryNumber, NoPutResultSet subqueryResultSet, int numSubqueries)
     Set the appropriate entry in the subquery tracking array for the specified subquery.
public  voidsetSystemCode()
     Set to indicate statement is system code.
public  voidsetTopResultSet(ResultSet topResultSet, NoPutResultSet[] subqueryTrackingArray)
     Set the top ResultSet in the ResultSet tree for close down on an error.



Method Detail
addDependency
public void addDependency(Dependency dy) throws StandardException(Code)
Track a Dependency within this StatementContext. (We need to clear any dependencies added within this context on an error.
Parameters:
  dy - The dependency to track.
exception:
  StandardException - Thrown on error



cancel
public void cancel()(Code)
Indicate that the statement which has allocated this statement context should cancel its execution. Usually called as a consequence of Statement.cancel() or a query timeout set with Statement.setQueryTimeout().



clearInUse
public void clearInUse()(Code)
Mark this context as not in use. This is important because we always leave the top statement context on the stack, and we don't want to clean it up if a statement level exception happens while the context is not in use.



clearSavePoint
public void clearSavePoint() throws StandardException(Code)
Clear the save point for the current statement.
exception:
  StandardException - Thrown on error



getSQLAllowed
public short getSQLAllowed()(Code)
Get the setting of the SQL allowed state.



getStatementText
public String getStatementText()(Code)
Return the text of the current statement. Note that this may be null. It is currently not set up correctly for ResultSets that aren't single row result sets (e.g SELECT) and setXXXX/getXXXX jdbc methods. the statement text



getSubqueryTrackingArray
public NoPutResultSet[] getSubqueryTrackingArray() throws StandardException(Code)
Get the subquery tracking array for this query. (Useful for runtime statistics.) NoPutResultSet[] The (sparse) array of tops of subquery ResultSet trees
exception:
  StandardException - Thrown on error



getSystemCode
public boolean getSystemCode()(Code)
Return true if this statement is system code.



inTrigger
public boolean inTrigger()(Code)
Returns whether we started from within the context of a trigger or not. true if we are in a trigger context



inUse
public boolean inUse()(Code)
Is this statement context in use or not. true if in use



isAtomic
public boolean isAtomic()(Code)
Indicates whether the statement needs to be executed atomically or not, i.e., whether a commit/rollback is permitted by a connection nested in this statement. true if needs to be atomic



isCancelled
public boolean isCancelled()(Code)
Checks if the statement which has allocated this statement context should cancel its execution. true if the statement execution should be cancelled.



isForReadOnly
public boolean isForReadOnly()(Code)
Is this statement for a read only, non-updatable ResultSet true if the statement is for creating a read only, non-updatable ResultSet



onStack
public boolean onStack()(Code)
Reports whether this StatementContext is on the context stack. true if this StatementContext is on the context stack. false otherwise.



resetSavePoint
public void resetSavePoint() throws StandardException(Code)
If this statement context has a savepoint, then it is reset to the current point. Otherwise, it is a noop.
exception:
  StandardException - Thrown on error



setInUse
public void setInUse(boolean inTrigger, boolean isAtomic, boolean isForReadOnly, String stmtText, ParameterValueSet pvs, long timeoutMillis)(Code)
Mark this context as being in use.
Parameters:
  inTrigger - true if the parent started in the context of a trigger
Parameters:
  isAtomic - true if the statement must be executedatomically
Parameters:
  isForReadOnly - true if the statement is for producing non-updatableresultset
Parameters:
  stmtText - the text of the statement. Needed for any languagestatement (currently, for any statement that can cause a triggerto fire). Please set this unless you are some funky jdbc setXXXmethod or something.
Parameters:
  pvs - parameter value set, if it has one
Parameters:
  timeoutMillis - timeout value for the statement, in milliseconds.Zero means no timeout.



setParentRollback
public void setParentRollback()(Code)
Indicate that, in the event of a statement-level exception, this context is NOT the last one that needs to be rolled back--rather, it is nested within some other statement context, and that other context needs to be rolled back, too.



setSQLAllowed
public void setSQLAllowed(short allow, boolean force)(Code)
Set the level of SQL allowed in this and subsequent nested statements due to a routine call. Value must be one of RoutineAliasInfo.{MODIFIES_SQL_DATA, READS_SQL_DATA, CONTAINS_SQL, NO_SQL}
Parameters:
  force - set to true to override more restrictive setting. Used toreset the permissions after a function call.



setSavePoint
public void setSavePoint() throws StandardException(Code)
Set a save point for the current statement. NOTE: This needs to be off of the StatementContext so that it gets cleared on a statement error.
exception:
  StandardException - Thrown on error



setSubqueryResultSet
public void setSubqueryResultSet(int subqueryNumber, NoPutResultSet subqueryResultSet, int numSubqueries) throws StandardException(Code)
Set the appropriate entry in the subquery tracking array for the specified subquery. Useful for closing down open subqueries on an exception.
Parameters:
  subqueryNumber - The subquery # for this subquery
Parameters:
  subqueryResultSet - The NoPutResultSet at the top of the subquery
Parameters:
  numSubqueries - The total # of subqueries in the entire query
exception:
  StandardException - Thrown on error



setSystemCode
public void setSystemCode()(Code)
Set to indicate statement is system code. For example a system procedure, view, function etc.



setTopResultSet
public void setTopResultSet(ResultSet topResultSet, NoPutResultSet[] subqueryTrackingArray) throws StandardException(Code)
Set the top ResultSet in the ResultSet tree for close down on an error.
Parameters:
  topResultSet - The top ResultSet in the ResultSet tree
Parameters:
  subqueryTrackingArray - (Sparse) of tops of subquery ResultSet trees
exception:
  StandardException - Thrown on error



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