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


0001:        /*
0002:
0003:           Derby - Class org.apache.derby.iapi.sql.execute.ResultSetFactory
0004:
0005:           Licensed to the Apache Software Foundation (ASF) under one or more
0006:           contributor license agreements.  See the NOTICE file distributed with
0007:           this work for additional information regarding copyright ownership.
0008:           The ASF licenses this file to you under the Apache License, Version 2.0
0009:           (the "License"); you may not use this file except in compliance with
0010:           the License.  You may obtain a copy of the License at
0011:
0012:              http://www.apache.org/licenses/LICENSE-2.0
0013:
0014:           Unless required by applicable law or agreed to in writing, software
0015:           distributed under the License is distributed on an "AS IS" BASIS,
0016:           WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
0017:           See the License for the specific language governing permissions and
0018:           limitations under the License.
0019:
0020:         */
0021:
0022:        package org.apache.derby.iapi.sql.execute;
0023:
0024:        import org.apache.derby.iapi.error.StandardException;
0025:
0026:        import org.apache.derby.iapi.sql.ResultDescription;
0027:        import org.apache.derby.iapi.sql.ResultSet;
0028:        import org.apache.derby.iapi.sql.Activation;
0029:
0030:        import org.apache.derby.iapi.services.loader.GeneratedMethod;
0031:
0032:        import org.apache.derby.iapi.store.access.Qualifier;
0033:
0034:        /**
0035:         * ResultSetFactory provides a wrapper around all of
0036:         * the result sets needed in an execution implementation.
0037:         * <p>
0038:         * For the activations to avoid searching for this module
0039:         * in their execute methods, the base activation supertype
0040:         * should implement a method that does the lookup and salts
0041:         * away this factory for the activation to use as it needs it.
0042:         *
0043:         * @author ames
0044:         */
0045:        public interface ResultSetFactory {
0046:            /**
0047:            	Module name for the monitor's module locating system.
0048:             */
0049:            String MODULE = "org.apache.derby.iapi.sql.execute.ResultSetFactory";
0050:
0051:            //
0052:            // DDL operations
0053:            //
0054:
0055:            /**
0056:                Generic DDL result set creation.
0057:
0058:            	@param activation 		the activation for this result set
0059:
0060:            	@return	ResultSet	A wrapper result set to run the Execution-time
0061:            	                        logic.
0062:            	@exception StandardException thrown when unable to create the
0063:            		result set
0064:             */
0065:            ResultSet getDDLResultSet(Activation activation)
0066:                    throws StandardException;
0067:
0068:            //
0069:            // MISC operations
0070:            //
0071:
0072:            /**
0073:                Generic Misc result set creation.
0074:
0075:            	@param activation 		the activation for this result set
0076:
0077:            	@return	ResultSet	A wrapper result set to run the Execution-time
0078:            	                        logic.
0079:            	@exception StandardException thrown when unable to create the
0080:            		result set
0081:             */
0082:            ResultSet getMiscResultSet(Activation activation)
0083:                    throws StandardException;
0084:
0085:            //
0086:            // Transaction operations
0087:            //
0088:            /**
0089:
0090:            	@param activation 		the activation for this result set
0091:
0092:            	@return	ResultSet	A wrapper result set to run the Execution-time
0093:            	                        logic.
0094:            	@exception StandardException thrown when unable to create the
0095:            		result set
0096:             */
0097:            ResultSet getSetTransactionResultSet(Activation activation)
0098:                    throws StandardException;
0099:
0100:            //
0101:            // DML statement operations
0102:            //
0103:            /**
0104:            	An insert result set simply reports that it completed, and
0105:            	the number of rows inserted.  It does not return rows.
0106:            	The insert has been completed once the
0107:            	insert result set is available.
0108:
0109:            	@param source the result set from which to take rows to
0110:            		be inserted into the target table.
0111:            	@param checkGM	The code to enforce the check constraints, if any
0112:            	@return the insert operation as a result set.
0113:            	@exception StandardException thrown when unable to perform the insert
0114:             */
0115:            ResultSet getInsertResultSet(NoPutResultSet source,
0116:                    GeneratedMethod checkGM) throws StandardException;
0117:
0118:            /**
0119:            	An insert VTI result set simply reports that it completed, and
0120:            	the number of rows inserted.  It does not return rows.
0121:            	The insert has been completed once the
0122:            	insert result set is available.
0123:
0124:            	@param source the result set from which to take rows to
0125:            		be inserted into the target table.
0126:            	@param vtiRS	The code to instantiate the VTI, if necessary
0127:            	@return the insert VTI operation as a result set.
0128:            	@exception StandardException thrown when unable to perform the insert
0129:             */
0130:            ResultSet getInsertVTIResultSet(NoPutResultSet source,
0131:                    NoPutResultSet vtiRS) throws StandardException;
0132:
0133:            /**
0134:            	A delete VTI result set simply reports that it completed, and
0135:            	the number of rows deleted.  It does not return rows.
0136:            	The delete has been completed once the
0137:            	delete result set is available.
0138:
0139:            	@param source the result set from which to take rows to
0140:            		be inserted into the target table.
0141:            	@return the delete VTI operation as a result set.
0142:            	@exception StandardException thrown when unable to perform the insert
0143:             */
0144:            ResultSet getDeleteVTIResultSet(NoPutResultSet source)
0145:                    throws StandardException;
0146:
0147:            /**
0148:            	A delete result set simply reports that it completed, and
0149:            	the number of rows deleted.  It does not return rows.
0150:            	The delete has been completed once the
0151:            	delete result set is available.
0152:
0153:            	@param source the result set from which to take rows to
0154:            		be deleted from the target table. This result set must
0155:            		contain one column which provides RowLocations that are
0156:            		valid in the target table.
0157:            	@return the delete operation as a result set.
0158:            	@exception StandardException thrown when unable to perform the delete
0159:             */
0160:            ResultSet getDeleteResultSet(NoPutResultSet source)
0161:                    throws StandardException;
0162:
0163:            /**
0164:            	A delete Cascade result set simply reports that it completed, and
0165:            	the number of rows deleted.  It does not return rows.
0166:            	The delete has been completed once the
0167:            	delete result set is available.
0168:
0169:            	@param source the result set from which to take rows to
0170:            		be deleted from the target table.
0171:            	@param constantActionItem a constant action saved object reference
0172:            	@param dependentResultSets an array of DeleteCascade Resultsets
0173:                                           for the current table referential action
0174:            							   dependents tables.
0175:            	@param resultSetId  an Id which is used to store the refence
0176:                                    to the temporary result set created of
0177:                                    the materilized rows.Dependent table resultsets
0178:            						uses the same id to access their parent temporary result sets.
0179:            	@return the delete operation as a delete cascade result set.
0180:            	@exception StandardException thrown when unable to perform the delete
0181:             */
0182:            ResultSet getDeleteCascadeResultSet(NoPutResultSet source,
0183:                    int constantActionItem, ResultSet[] dependentResultSets,
0184:                    String resultSetId) throws StandardException;
0185:
0186:            /**
0187:            	An update result set simply reports that it completed, and
0188:            	the number of rows updated.  It does not return rows.
0189:            	The update has been completed once the
0190:            	update result set is available.
0191:
0192:            	@param source the result set from which to take rows to be 
0193:            		updated in the target table. This result set must contain 
0194:            		a column which provides RowLocations that are valid in the 
0195:            		target table, and new values to be placed in those rows.
0196:            	@param checkGM	The code to enforce the check constraints, if any
0197:            	@return the update operation as a result set.
0198:            	@exception StandardException thrown when unable to perform the update
0199:             */
0200:            ResultSet getUpdateResultSet(NoPutResultSet source,
0201:                    GeneratedMethod checkGM) throws StandardException;
0202:
0203:            /**
0204:             * @param source the result set from which to take rows to be 
0205:             *               updated in the target table.
0206:             * @return the update operation as a result set.
0207:             * @exception StandardException thrown on error
0208:             */
0209:            public ResultSet getUpdateVTIResultSet(NoPutResultSet source)
0210:                    throws StandardException;
0211:
0212:            /**
0213:            	An update result set simply reports that it completed, and
0214:            	the number of rows updated.  It does not return rows.
0215:            	The update has been completed once the
0216:            	update result set is available.
0217:
0218:            	@param source the result set from which to take rows to be 
0219:            		updated in the target table. This result set must contain 
0220:            		a column which provides RowLocations that are valid in the 
0221:            		target table, and new values to be placed in those rows.
0222:            	@param checkGM	The code to enforce the check constraints, if any
0223:            	@param constantActionItem a constant action saved object reference
0224:            	@param rsdItem   result Description, saved object id. 				
0225:            	@return the update operation as a result set.
0226:            	@exception StandardException thrown when unable to perform the update
0227:             */
0228:            ResultSet getDeleteCascadeUpdateResultSet(NoPutResultSet source,
0229:                    GeneratedMethod checkGM, int constantActionItem, int rsdItem)
0230:                    throws StandardException;
0231:
0232:            /**
0233:            	A call statement result set simply reports that it completed.  
0234:            	It does not return rows.
0235:
0236:            	@param methodCall a reference to a method in the activation
0237:            		  for the method call
0238:            	@param activation the activation for this result set
0239:
0240:            	@return the call statement operation as a result set.
0241:            	@exception StandardException thrown when unable to perform the call statement
0242:             */
0243:            ResultSet getCallStatementResultSet(GeneratedMethod methodCall,
0244:                    Activation activation) throws StandardException;
0245:
0246:            //
0247:            // Query expression operations
0248:            //
0249:
0250:            /**
0251:            	A project restrict result set iterates over its source,
0252:            	evaluating a restriction and when it is satisfied,
0253:            	constructing a row to return in its result set based on
0254:            	its projection.
0255:            	The rows can be constructed as they are requested from the
0256:            	result set.
0257:
0258:            	@param source the result set from which to take rows to be 
0259:            		filtered by this operation.
0260:            	@param restriction a reference to a method in the activation
0261:            		that is applied to the activation's "current row" field
0262:            		to determine whether the restriction is satisfied or not.
0263:            		The signature of this method is
0264:            		<verbatim>
0265:            			Boolean restriction() throws StandardException;
0266:            		</verbatim>
0267:            	@param projection a reference to a method in the activation
0268:            		that is applied to the activation's "current row" field
0269:            		to project out the expected result row.
0270:            		The signature of this method is
0271:            		<verbatim>
0272:            			ExecRow projection() throws StandardException;
0273:            		</verbatim>
0274:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0275:            	@param constantRestriction a reference to a method in the activation
0276:            		that represents a constant expression (eg where 1 = 2).
0277:            		The signature of this method is
0278:            		<verbatim>
0279:            			Boolean restriction() throws StandardException;
0280:            		</verbatim>
0281:            	@param mapArrayItem	Item # for mapping of source to target columns
0282:            	@param reuseResult	Whether or not to reuse the result row.
0283:            	@param doesProjection	Whether or not this PRN does a projection
0284:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0285:            										optimizer
0286:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0287:            	@return the project restrict operation as a result set.
0288:            	@exception StandardException thrown when unable to create the
0289:            		result set
0290:             */
0291:            NoPutResultSet getProjectRestrictResultSet(NoPutResultSet source,
0292:                    GeneratedMethod restriction, GeneratedMethod projection,
0293:                    int resultSetNumber, GeneratedMethod constantRestriction,
0294:                    int mapArrayItem, boolean reuseResult,
0295:                    boolean doesProjection, double optimizerEstimatedRowCount,
0296:                    double optimizerEstimatedCost) throws StandardException;
0297:
0298:            /**
0299:            	A hash table result set builds a hash table on its source,
0300:            	applying a list of predicates, if any, to the source,
0301:            	when building the hash table.  It then does a look up into
0302:            	the hash table on a probe.
0303:            	The rows can be constructed as they are requested from the
0304:            	result set.
0305:
0306:            	@param source the result set from which to take rows to be 
0307:            		filtered by this operation.
0308:            	@param singleTableRestriction restriction, if any, applied to
0309:            		input of hash table.
0310:            	@param equijoinQualifiers Qualifier[] for look up into hash table
0311:            	@param projection a reference to a method in the activation
0312:            		that is applied to the activation's "current row" field
0313:            		to project out the expected result row.
0314:            		The signature of this method is
0315:            		<verbatim>
0316:            			ExecRow projection() throws StandardException;
0317:            		</verbatim>
0318:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0319:            	@param mapRefItem	Item # for mapping of source to target columns
0320:            	@param reuseResult	Whether or not to reuse the result row.
0321:            	@param keyColItem	Item for hash key column array
0322:            	@param removeDuplicates	Whether or not to remove duplicates when building the hash table
0323:            	@param maxInMemoryRowCount			Max size of in-memory hash table
0324:            	@param initialCapacity				initialCapacity for java.util.HashTable
0325:            	@param loadFactor					loadFactor for java.util.HashTable
0326:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0327:            										optimizer
0328:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0329:            	@return the project restrict operation as a result set.
0330:            	@exception StandardException thrown when unable to create the
0331:            		result set
0332:             */
0333:            public NoPutResultSet getHashTableResultSet(NoPutResultSet source,
0334:                    GeneratedMethod singleTableRestriction,
0335:                    Qualifier[][] equijoinQualifiers,
0336:                    GeneratedMethod projection, int resultSetNumber,
0337:                    int mapRefItem, boolean reuseResult, int keyColItem,
0338:                    boolean removeDuplicates, long maxInMemoryRowCount,
0339:                    int initialCapacity, float loadFactor,
0340:                    double optimizerEstimatedRowCount,
0341:                    double optimizerEstimatedCost) throws StandardException;
0342:
0343:            /**
0344:            	A sort result set sorts its source and if requested removes
0345:            	duplicates.  It will generate the entire result when open, and
0346:            	then return it a row at a time.
0347:            	<p>
0348:            	If passed aggregates it will do scalar or vector aggregate
0349:            	processing.  A list of aggregator information is passed
0350:            	off of the PreparedStatement's savedObjects.  Aggregation
0351:            	and SELECT DISTINCT cannot be processed in the same sort.
0352:
0353:            	@param source the result set from which to take rows to be 
0354:            		filtered by this operation.
0355:            	@param distinct true if distinct SELECT list
0356:            	@param isInSortedOrder	true if the source result set is in sorted order
0357:            	@param orderItem entry in preparedStatement's savedObjects for order
0358:            	@param rowAllocator a reference to a method in the activation
0359:            		that generates rows of the right size and shape for the source
0360:            	@param rowSize the size of the row that is allocated by rowAllocator.
0361:            		size should be the maximum size of the sum of all the datatypes.
0362:            		user type are necessarily approximated
0363:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0364:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0365:            										optimizer
0366:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0367:            	@return the distinct operation as a result set.
0368:            	@exception StandardException thrown when unable to create the
0369:            		result set
0370:             */
0371:            NoPutResultSet getSortResultSet(NoPutResultSet source,
0372:                    boolean distinct, boolean isInSortedOrder, int orderItem,
0373:                    GeneratedMethod rowAllocator, int rowSize,
0374:                    int resultSetNumber, double optimizerEstimatedRowCount,
0375:                    double optimizerEstimatedCost) throws StandardException;
0376:
0377:            /**
0378:            	A ScalarAggregateResultSet computes non-distinct scalar aggregates.
0379:            	It will compute the aggregates when open.
0380:
0381:            	@param source the result set from which to take rows to be 
0382:            		filtered by this operation.
0383:            	@param isInSortedOrder	true if the source result set is in sorted order
0384:            	@param aggregateItem entry in preparedStatement's savedObjects for aggregates
0385:            	@param orderingItem		Ignored to allow same signature as getDistinctScalarAggregateResultSet
0386:            	@param rowAllocator a reference to a method in the activation
0387:            		that generates rows of the right size and shape for the source
0388:            	@param rowSize			Ignored to allow same signature as getDistinctScalarAggregateResultSet
0389:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0390:            	@param singleInputRow	Whether we know we have a single input row or not
0391:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0392:            										optimizer
0393:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0394:            	@return the scalar aggregation operation as a result set.
0395:            	@exception StandardException thrown when unable to create the
0396:            		result set
0397:             */
0398:            NoPutResultSet getScalarAggregateResultSet(NoPutResultSet source,
0399:                    boolean isInSortedOrder, int aggregateItem,
0400:                    int orderingItem, GeneratedMethod rowAllocator,
0401:                    int rowSize, int resultSetNumber, boolean singleInputRow,
0402:                    double optimizerEstimatedRowCount,
0403:                    double optimizerEstimatedCost) throws StandardException;
0404:
0405:            /**
0406:            	A DistinctScalarAggregateResultSet computes scalar aggregates when 
0407:            	at least one of them is a distinct aggregate.
0408:            	It will compute the aggregates when open.
0409:
0410:            	@param source the result set from which to take rows to be 
0411:            		filtered by this operation.
0412:            	@param isInSortedOrder	true if the source result set is in sorted order
0413:            	@param aggregateItem entry in preparedStatement's savedObjects for aggregates
0414:            	@param orderingItem entry in preparedStatement's savedObjects for order
0415:            	@param rowAllocator a reference to a method in the activation
0416:            		that generates rows of the right size and shape for the source
0417:            	@param rowSize the size of the row that is allocated by rowAllocator.
0418:            		size should be the maximum size of the sum of all the datatypes.
0419:            		user type are necessarily approximated
0420:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0421:            	@param singleInputRow	Whether we know we have a single input row or not
0422:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0423:            										optimizer
0424:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0425:            	@return the scalar aggregation operation as a result set.
0426:            	@exception StandardException thrown when unable to create the
0427:            		result set
0428:             */
0429:            NoPutResultSet getDistinctScalarAggregateResultSet(
0430:                    NoPutResultSet source, boolean isInSortedOrder,
0431:                    int aggregateItem, int orderingItem,
0432:                    GeneratedMethod rowAllocator, int rowSize,
0433:                    int resultSetNumber, boolean singleInputRow,
0434:                    double optimizerEstimatedRowCount,
0435:                    double optimizerEstimatedCost) throws StandardException;
0436:
0437:            /**
0438:            	A GroupedAggregateResultSet computes non-distinct grouped aggregates.
0439:            	It will compute the aggregates when open.
0440:
0441:            	@param source the result set from which to take rows to be 
0442:            		filtered by this operation.
0443:            	@param isInSortedOrder	true if the source result set is in sorted order
0444:            	@param aggregateItem entry in preparedStatement's savedObjects for aggregates
0445:            	@param orderingItem		Ignored to allow same signature as getDistinctScalarAggregateResultSet
0446:            	@param rowAllocator a reference to a method in the activation
0447:            		that generates rows of the right size and shape for the source
0448:            	@param rowSize			Ignored to allow same signature as getDistinctScalarAggregateResultSet
0449:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0450:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0451:            										optimizer
0452:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0453:            	@return the scalar aggregation operation as a result set.
0454:            	@exception StandardException thrown when unable to create the
0455:            		result set
0456:             */
0457:            NoPutResultSet getGroupedAggregateResultSet(NoPutResultSet source,
0458:                    boolean isInSortedOrder, int aggregateItem,
0459:                    int orderingItem, GeneratedMethod rowAllocator,
0460:                    int rowSize, int resultSetNumber,
0461:                    double optimizerEstimatedRowCount,
0462:                    double optimizerEstimatedCost) throws StandardException;
0463:
0464:            /**
0465:            	A DistinctGroupedAggregateResultSet computes scalar aggregates when 
0466:            	at least one of them is a distinct aggregate.
0467:            	It will compute the aggregates when open.
0468:
0469:            	@param source the result set from which to take rows to be 
0470:            		filtered by this operation.
0471:            	@param isInSortedOrder	true if the source result set is in sorted order
0472:            	@param aggregateItem entry in preparedStatement's savedObjects for aggregates
0473:            	@param orderingItem entry in preparedStatement's savedObjects for order
0474:            	@param rowAllocator a reference to a method in the activation
0475:            		that generates rows of the right size and shape for the source
0476:            	@param rowSize the size of the row that is allocated by rowAllocator.
0477:            		size should be the maximum size of the sum of all the datatypes.
0478:            		user type are necessarily approximated
0479:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0480:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0481:            										optimizer
0482:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0483:            	@return the scalar aggregation operation as a result set.
0484:            	@exception StandardException thrown when unable to create the
0485:            		result set
0486:             */
0487:            NoPutResultSet getDistinctGroupedAggregateResultSet(
0488:                    NoPutResultSet source, boolean isInSortedOrder,
0489:                    int aggregateItem, int orderingItem,
0490:                    GeneratedMethod rowAllocator, int rowSize,
0491:                    int resultSetNumber, double optimizerEstimatedRowCount,
0492:                    double optimizerEstimatedCost) throws StandardException;
0493:
0494:            /**
0495:            	An any result set iterates over its source,
0496:            	returning a row with all columns set to nulls
0497:            	if the source returns no rows.
0498:
0499:            	@param source the result set from which to take rows to be 
0500:            		filtered by this operation.
0501:            	@param emptyRowFun a reference to a method in the activation
0502:            		that is called if the source returns no rows
0503:            	@param resultSetNumber		The resultSetNumber for the ResultSet
0504:            	@param subqueryNumber		The subquery number for this subquery.
0505:            	@param pointOfAttachment	The point of attachment for this subquery.
0506:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0507:            										optimizer
0508:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0509:            	@return the any operation as a result set.
0510:            	@exception StandardException thrown when unable to create the
0511:            		result set
0512:             */
0513:            NoPutResultSet getAnyResultSet(NoPutResultSet source,
0514:                    GeneratedMethod emptyRowFun, int resultSetNumber,
0515:                    int subqueryNumber, int pointOfAttachment,
0516:                    double optimizerEstimatedRowCount,
0517:                    double optimizerEstimatedCost) throws StandardException;
0518:
0519:            /**
0520:            	A once result set iterates over its source,
0521:            	raising an error if the source returns > 1 row and
0522:            	returning a row with all columns set to nulls
0523:            	if the source returns no rows.
0524:
0525:            	@param source the result set from which to take rows to be 
0526:            		filtered by this operation.
0527:            	@param emptyRowFun a reference to a method in the activation
0528:            		that is called if the source returns no rows
0529:            	@param cardinalityCheck The type of cardinality check, if any that
0530:            		is required
0531:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0532:            	@param subqueryNumber		The subquery number for this subquery.
0533:            	@param pointOfAttachment	The point of attachment for this subquery.
0534:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0535:            										optimizer
0536:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0537:            	@return the once operation as a result set.
0538:            	@exception StandardException thrown when unable to create the
0539:            		result set
0540:             */
0541:            NoPutResultSet getOnceResultSet(NoPutResultSet source,
0542:                    GeneratedMethod emptyRowFun, int cardinalityCheck,
0543:                    int resultSetNumber, int subqueryNumber,
0544:                    int pointOfAttachment, double optimizerEstimatedRowCount,
0545:                    double optimizerEstimatedCost) throws StandardException;
0546:
0547:            /**
0548:            	A row result set forms a result set on a single, known row value.
0549:            	It is used to turn constant rows into result sets for use in
0550:            	the result set paradigm.
0551:            	The row can be constructed when it is requested from the
0552:            	result set.
0553:
0554:            	@param activation the activation for this result set,
0555:            		against which the row operation is performed to
0556:            		create the result set.
0557:            	@param row a reference to a method in the activation
0558:            		that creates the expected row.
0559:            		<verbatim>
0560:            			ExecRow row() throws StandardException;
0561:            		</verbatim>
0562:            	@param canCacheRow	True if execution can cache the input row
0563:            		after it has gotten it.  If the input row is constructed soley
0564:            		of constants or parameters, it is ok to cache this row rather
0565:            		than recreating it each time it is requested.
0566:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0567:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0568:            										optimizer
0569:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0570:            	@return the row as a result set.
0571:            	@exception StandardException thrown when unable to create the
0572:            		result set
0573:             */
0574:            NoPutResultSet getRowResultSet(Activation activation,
0575:                    GeneratedMethod row, boolean canCacheRow,
0576:                    int resultSetNumber, double optimizerEstimatedRowCount,
0577:                    double optimizerEstimatedCost) throws StandardException;
0578:
0579:            /**
0580:            	A VTI result set wraps a user supplied result set.
0581:
0582:            	@param activation the activation for this result set,
0583:            		against which the row operation is performed to
0584:            		create the result set.
0585:            	@param row a reference to a method in the activation
0586:            		that creates the expected row.
0587:            		<verbatim>
0588:            			ExecRow row() throws StandardException;
0589:            		</verbatim>
0590:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0591:            	@param constructor		The GeneratedMethod for the user's constructor
0592:            	@param javaClassName	The java class name for the VTI
0593:            	@param erdNumber		int for referenced column BitSet 
0594:            							(so it can be turned back into an object)
0595:            	@param version2			Whether or not VTI is a version 2 VTI.
0596:            	@param isTarget			Whether or not VTI is a target VTI.
0597:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0598:            										optimizer
0599:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0600:            	@return the row as a result set.
0601:            	@exception StandardException thrown when unable to create the
0602:            		result set
0603:             */
0604:            public NoPutResultSet getVTIResultSet(Activation activation,
0605:                    GeneratedMethod row, int resultSetNumber,
0606:                    GeneratedMethod constructor, String javaClassName,
0607:                    Qualifier[][] pushedQualifiers, int erdNumber,
0608:                    boolean version2, boolean reuseablePs, int ctcNumber,
0609:                    boolean isTarget, int scanIsolationLevel,
0610:                    double optimizerEstimatedRowCount,
0611:                    double optimizerEstimatedCost) throws StandardException;
0612:
0613:            /**
0614:            	A hash result set forms a result set on a hash table built on a scan
0615:            	of a table.
0616:            	The rows are put into the hash table on the 1st open.
0617:            	<p>
0618:
0619:            	@param activation the activation for this result set,
0620:            		which provides the context for the row allocation operation.
0621:            	@param conglomId the conglomerate of the table to be scanned.
0622:            	@param scociItem The saved item for the static conglomerate info.
0623:            	@param resultRowAllocator a reference to a method in the activation
0624:            		that creates a holder for the rows from the scan.
0625:            		<verbatim>
0626:            			ExecRow rowAllocator() throws StandardException;
0627:            		</verbatim>
0628:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0629:            	@param startKeyGetter a reference to a method in the activation
0630:            		that gets the start key indexable row for the scan.  Null
0631:            		means there is no start key.
0632:            		<verbatim>
0633:            			ExecIndexRow startKeyGetter() throws StandardException;
0634:            		</verbatim>
0635:            	@param startSearchOperator The start search operator for opening
0636:            		the scan
0637:            	@param stopKeyGetter	a reference to a method in the activation
0638:            		that gets the stop key indexable row for the scan.  Null means
0639:            		there is no stop key.
0640:            		<verbatim>
0641:            			ExecIndexRow stopKeyGetter() throws StandardException;
0642:            		</verbatim>
0643:            	@param stopSearchOperator	The stop search operator for opening
0644:            		the scan
0645:            	@param sameStartStopPosition	Re-use the startKeyGetter for the stopKeyGetter
0646:            									(Exact match search.)
0647:            	@param scanQualifiers the array of Qualifiers for the scan.
0648:            		Null or an array length of zero means there are no qualifiers.
0649:            	@param nextQualifiers the array of Qualifiers for the look up into the hash table.
0650:            	@param initialCapacity	The initialCapacity for the HashTable.
0651:            	@param loadFactor		The loadFactor for the HashTable.
0652:            	@param maxCapacity		The maximum size for the HashTable.
0653:            	@param hashKeyColumn	The 0-based column # for the hash key.
0654:            	@param tableName		The full name of the table 
0655:            	@param userSuppliedOptimizerOverrides		Overrides specified by the user on the sql
0656:            	@param indexName		The name of the index, if one used to access table.
0657:            	@param isConstraint		If index, if used, is a backing index for a constraint.
0658:            	@param forUpdate		True means open for update
0659:            	@param colRefItem		An saved item for a bitSet of columns that
0660:            							are referenced in the underlying table.  -1 if
0661:            							no item.
0662:            	@param lockMode			The lock granularity to use (see
0663:            							TransactionController in access)
0664:            	@param tableLocked		Whether or not the table is marked as using table locking
0665:            							(in sys.systables)
0666:            	@param isolationLevel	Isolation level (specified or not) to use on scans
0667:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0668:            										optimizer
0669:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0670:            	@return the table scan operation as a result set.
0671:            	@exception StandardException thrown when unable to create the
0672:            		result set
0673:             */
0674:            NoPutResultSet getHashScanResultSet(Activation activation,
0675:                    long conglomId, int scociItem,
0676:                    GeneratedMethod resultRowAllocator, int resultSetNumber,
0677:                    GeneratedMethod startKeyGetter, int startSearchOperator,
0678:                    GeneratedMethod stopKeyGetter, int stopSearchOperator,
0679:                    boolean sameStartStopPosition,
0680:                    Qualifier[][] scanQualifiers, Qualifier[][] nextQualifiers,
0681:                    int initialCapacity, float loadFactor, int maxCapacity,
0682:                    int hashKeyColumn, String tableName,
0683:                    String userSuppliedOptimizerOverrides, String indexName,
0684:                    boolean isConstraint, boolean forUpdate, int colRefItem,
0685:                    int indexColItem, int lockMode, boolean tableLocked,
0686:                    int isolationLevel, double optimizerEstimatedRowCount,
0687:                    double optimizerEstimatedCost) throws StandardException;
0688:
0689:            /**
0690:            	A distinct scan result set pushes duplicate elimination into
0691:            	the scan.
0692:            	<p>
0693:
0694:            	@param activation the activation for this result set,
0695:            		which provides the context for the row allocation operation.
0696:            	@param conglomId the conglomerate of the table to be scanned.
0697:            	@param scociItem The saved item for the static conglomerate info.
0698:            	@param resultRowAllocator a reference to a method in the activation
0699:            		that creates a holder for the rows from the scan.
0700:            		<verbatim>
0701:            			ExecRow rowAllocator() throws StandardException;
0702:            		</verbatim>
0703:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0704:            	@param hashKeyColumn	The 0-based column # for the hash key.
0705:            	@param tableName		The full name of the table
0706:            	@param userSuppliedOptimizerOverrides		Overrides specified by the user on the sql
0707:            	@param indexName		The name of the index, if one used to access table.
0708:            	@param isConstraint		If index, if used, is a backing index for a constraint.
0709:            	@param colRefItem		An saved item for a bitSet of columns that
0710:            							are referenced in the underlying table.  -1 if
0711:            							no item.
0712:            	@param lockMode			The lock granularity to use (see
0713:            							TransactionController in access)
0714:            	@param tableLocked		Whether or not the table is marked as using table locking
0715:            							(in sys.systables)
0716:            	@param isolationLevel	Isolation level (specified or not) to use on scans
0717:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0718:            										optimizer
0719:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0720:            	@return the table scan operation as a result set.
0721:            	@exception StandardException thrown when unable to create the
0722:            		result set
0723:             */
0724:            NoPutResultSet getDistinctScanResultSet(Activation activation,
0725:                    long conglomId, int scociItem,
0726:                    GeneratedMethod resultRowAllocator, int resultSetNumber,
0727:                    int hashKeyColumn, String tableName,
0728:                    String userSuppliedOptimizerOverrides, String indexName,
0729:                    boolean isConstraint, int colRefItem, int lockMode,
0730:                    boolean tableLocked, int isolationLevel,
0731:                    double optimizerEstimatedRowCount,
0732:                    double optimizerEstimatedCost) throws StandardException;
0733:
0734:            /**
0735:            	A table scan result set forms a result set on a scan
0736:            	of a table.
0737:            	The rows can be constructed as they are requested from the
0738:            	result set.
0739:            	<p>
0740:            	This form of the table scan operation is simple, and is
0741:            	to be used when there are no predicates to be passed down
0742:            	to the scan to limit its scope on the target table.
0743:
0744:            	@param conglomId the conglomerate of the table to be scanned.
0745:            	@param scociItem The saved item for the static conglomerate info.
0746:            	@param activation the activation for this result set,
0747:            		which provides the context for the row allocation operation.
0748:            	@param resultRowAllocator a reference to a method in the activation
0749:            		that creates a holder for the result row of the scan.  May
0750:            		be a partial row.
0751:            		<verbatim>
0752:            			ExecRow rowAllocator() throws StandardException;
0753:            		</verbatim>
0754:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0755:            	@param startKeyGetter a reference to a method in the activation
0756:            		that gets the start key indexable row for the scan.  Null
0757:            		means there is no start key.
0758:            		<verbatim>
0759:            			ExecIndexRow startKeyGetter() throws StandardException;
0760:            		</verbatim>
0761:            	@param startSearchOperator The start search operator for opening
0762:            		the scan
0763:            	@param stopKeyGetter	a reference to a method in the activation
0764:            		that gets the stop key indexable row for the scan.  Null means
0765:            		there is no stop key.
0766:            		<verbatim>
0767:            			ExecIndexRow stopKeyGetter() throws StandardException;
0768:            		</verbatim>
0769:            	@param stopSearchOperator	The stop search operator for opening
0770:            		the scan
0771:            	@param sameStartStopPosition	Re-use the startKeyGetter for the stopKeyGetter
0772:            									(Exact match search.)
0773:            	@param qualifiers the array of Qualifiers for the scan.
0774:            		Null or an array length of zero means there are no qualifiers.
0775:            	@param tableName		The full name of the table
0776:            	@param userSuppliedOptimizerOverrides		Overrides specified by the user on the sql
0777:            	@param indexName		The name of the index, if one used to access table.
0778:            	@param isConstraint		If index, if used, is a backing index for a constraint.
0779:            	@param forUpdate		True means open for update
0780:            	@param colRefItem		An saved item for a bitSet of columns that
0781:            							are referenced in the underlying table.  -1 if
0782:            							no item.
0783:            	@param lockMode			The lock granularity to use (see
0784:            							TransactionController in access)
0785:            	@param tableLocked		Whether or not the table is marked as using table locking
0786:            							(in sys.systables)
0787:            	@param isolationLevel	Isolation level (specified or not) to use on scans
0788:            	@param oneRowScan		Whether or not this is a 1 row scan.
0789:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0790:            										optimizer
0791:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0792:
0793:            	@return the table scan operation as a result set.
0794:            	@exception StandardException thrown when unable to create the
0795:            		result set
0796:             */
0797:            NoPutResultSet getTableScanResultSet(Activation activation,
0798:                    long conglomId, int scociItem,
0799:                    GeneratedMethod resultRowAllocator, int resultSetNumber,
0800:                    GeneratedMethod startKeyGetter, int startSearchOperator,
0801:                    GeneratedMethod stopKeyGetter, int stopSearchOperator,
0802:                    boolean sameStartStopPosition, Qualifier[][] qualifiers,
0803:                    String tableName, String userSuppliedOptimizerOverrides,
0804:                    String indexName, boolean isConstraint, boolean forUpdate,
0805:                    int colRefItem, int indexColItem, int lockMode,
0806:                    boolean tableLocked, int isolationLevel,
0807:                    boolean oneRowScan, double optimizerEstimatedRowCount,
0808:                    double optimizerEstimatedCost) throws StandardException;
0809:
0810:            /**
0811:            	A table scan result set forms a result set on a scan
0812:            	of a table.
0813:            	The rows can be constructed as they are requested from the
0814:            	result set.
0815:            	<p>
0816:            	This form of the table scan operation is simple, and is
0817:            	to be used when there are no predicates to be passed down
0818:            	to the scan to limit its scope on the target table.
0819:
0820:            	@param conglomId the conglomerate of the table to be scanned.
0821:            	@param scociItem The saved item for the static conglomerate info.
0822:            	@param activation the activation for this result set,
0823:            		which provides the context for the row allocation operation.
0824:            	@param resultRowAllocator a reference to a method in the activation
0825:            		that creates a holder for the result row of the scan.  May
0826:            		be a partial row.
0827:            		<verbatim>
0828:            			ExecRow rowAllocator() throws StandardException;
0829:            		</verbatim>
0830:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0831:            	@param startKeyGetter a reference to a method in the activation
0832:            		that gets the start key indexable row for the scan.  Null
0833:            		means there is no start key.
0834:            		<verbatim>
0835:            			ExecIndexRow startKeyGetter() throws StandardException;
0836:            		</verbatim>
0837:            	@param startSearchOperator The start search operator for opening
0838:            		the scan
0839:            	@param stopKeyGetter	a reference to a method in the activation
0840:            		that gets the stop key indexable row for the scan.  Null means
0841:            		there is no stop key.
0842:            		<verbatim>
0843:            			ExecIndexRow stopKeyGetter() throws StandardException;
0844:            		</verbatim>
0845:            	@param stopSearchOperator	The stop search operator for opening
0846:            		the scan
0847:            	@param sameStartStopPosition	Re-use the startKeyGetter for the stopKeyGetter
0848:            									(Exact match search.)
0849:            	@param qualifiers the array of Qualifiers for the scan.
0850:            		Null or an array length of zero means there are no qualifiers.
0851:            	@param tableName		The full name of the table
0852:            	@param userSuppliedOptimizerOverrides		Overrides specified by the user on the sql
0853:            	@param indexName		The name of the index, if one used to access table.
0854:            	@param isConstraint		If index, if used, is a backing index for a constraint.
0855:            	@param forUpdate		True means open for update
0856:            	@param colRefItem		An saved item for a bitSet of columns that
0857:            							are referenced in the underlying table.  -1 if
0858:            							no item.
0859:            	@param lockMode			The lock granularity to use (see
0860:            							TransactionController in access)
0861:            	@param tableLocked		Whether or not the table is marked as using table locking
0862:            							(in sys.systables)
0863:            	@param isolationLevel	Isolation level (specified or not) to use on scans
0864:            	@param rowsPerRead		The number of rows to read per fetch.
0865:            	@param oneRowScan		Whether or not this is a 1 row scan.
0866:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0867:            										optimizer
0868:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0869:
0870:            	@return the table scan operation as a result set.
0871:            	@exception StandardException thrown when unable to create the
0872:            		result set
0873:             */
0874:            NoPutResultSet getBulkTableScanResultSet(Activation activation,
0875:                    long conglomId, int scociItem,
0876:                    GeneratedMethod resultRowAllocator, int resultSetNumber,
0877:                    GeneratedMethod startKeyGetter, int startSearchOperator,
0878:                    GeneratedMethod stopKeyGetter, int stopSearchOperator,
0879:                    boolean sameStartStopPosition, Qualifier[][] qualifiers,
0880:                    String tableName, String userSuppliedOptimizerOverrides,
0881:                    String indexName, boolean isConstraint, boolean forUpdate,
0882:                    int colRefItem, int indexColItem, int lockMode,
0883:                    boolean tableLocked, int isolationLevel, int rowsPerRead,
0884:                    boolean oneRowScan, double optimizerEstimatedRowCount,
0885:                    double optimizerEstimatedCost) throws StandardException;
0886:
0887:            /**
0888:            	An index row to base row result set gets an index row from its source
0889:            	and uses the RowLocation in its last column to get the row from the
0890:            	base conglomerate.
0891:            	<p>
0892:
0893:                @param conglomId	Conglomerate # for the heap.
0894:            	@param scoci The saved item for the static conglomerate info.
0895:            	@param source	the source result set, which is expected to provide
0896:            					rows from an index conglomerate
0897:            	@param resultRowAllocator a reference to a method in the activation
0898:            		that creates a holder for the rows from the scan.
0899:            		<verbatim>
0900:            			ExecRow rowAllocator() throws StandardException;
0901:            		</verbatim>
0902:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0903:            	@param indexName		The name of the index.
0904:            	@param heapColRefItem	A saved item for a bitImpl of columns that
0905:            							are referenced in the underlying heap.  -1 if
0906:            							no item.
0907:            	@param indexColRefItem	A saved item for a bitImpl of columns that
0908:            							are referenced in the underlying index.  -1 if
0909:            							no item.
0910:            	@param indexColMapItem	A saved item for a ReferencedColumnsDescriptorImpl
0911:            							which tell  which columms are coming from the index.
0912:            	@param restriction		The restriction, if any, to be applied to the base row
0913:            	@param forUpdate		True means to open for update
0914:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0915:            										optimizer
0916:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0917:
0918:            	@return the index row to base row operation as a result set.
0919:            	@exception StandardException thrown when unable to create the
0920:            		result set
0921:             */
0922:            public NoPutResultSet getIndexRowToBaseRowResultSet(long conglomId,
0923:                    int scoci, NoPutResultSet source,
0924:                    GeneratedMethod resultRowAllocator, int resultSetNumber,
0925:                    String indexName, int heapColRefItem, int indexColRefItem,
0926:                    int indexColMapItem, GeneratedMethod restriction,
0927:                    boolean forUpdate, double optimizerEstimatedRowCount,
0928:                    double optimizerEstimatedCost) throws StandardException;
0929:
0930:            /**
0931:            	A nested loop left outer join result set forms a result set on top of
0932:            	2 other result sets.
0933:            	The rows can be constructed as they are requested from the
0934:            	result set.
0935:            	<p>
0936:            	This form of the nested loop join operation is simple, and is
0937:            	to be used when there are no join predicates to be passed down
0938:            	to the join to limit its scope on the right ResultSet.
0939:
0940:            	@param leftResultSet	Outer ResultSet for join.
0941:            	@param leftNumCols		Number of columns in the leftResultSet
0942:            	@param rightResultSet	Inner ResultSet for join.
0943:            	@param rightNumCols		Number of columns in the rightResultSet
0944:            	@param joinClause a reference to a method in the activation
0945:            		that is applied to the activation's "current row" field
0946:            		to determine whether the joinClause is satisfied or not.
0947:            		The signature of this method is
0948:            		<verbatim>
0949:            			Boolean joinClause() throws StandardException;
0950:            		</verbatim>
0951:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0952:            	@param oneRowRightSide	boolean, whether or not the right side returns
0953:            							a single row.  (No need to do 2nd next() if it does.)
0954:            	@param notExistsRightSide	boolean, whether or not the right side resides a
0955:            								NOT EXISTS base table
0956:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0957:            										optimizer
0958:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0959:            	@param userSuppliedOptimizerOverrides		Overrides specified by the user on the sql
0960:            	@return the nested loop join operation as a result set.
0961:            	@exception StandardException thrown when unable to create the
0962:            		result set
0963:             */
0964:            public NoPutResultSet getNestedLoopJoinResultSet(
0965:                    NoPutResultSet leftResultSet, int leftNumCols,
0966:                    NoPutResultSet rightResultSet, int rightNumCols,
0967:                    GeneratedMethod joinClause, int resultSetNumber,
0968:                    boolean oneRowRightSide, boolean notExistsRightSide,
0969:                    double optimizerEstimatedRowCount,
0970:                    double optimizerEstimatedCost,
0971:                    String userSuppliedOptimizerOverrides)
0972:                    throws StandardException;
0973:
0974:            /**
0975:            	A hash join.
0976:
0977:            	@param leftResultSet	Outer ResultSet for join.
0978:            	@param leftNumCols		Number of columns in the leftResultSet
0979:            	@param rightResultSet	Inner ResultSet for join.
0980:            	@param rightNumCols		Number of columns in the rightResultSet
0981:            	@param joinClause a reference to a method in the activation
0982:            		that is applied to the activation's "current row" field
0983:            		to determine whether the joinClause is satisfied or not.
0984:            		The signature of this method is
0985:            		<verbatim>
0986:            			Boolean joinClause() throws StandardException;
0987:            		</verbatim>
0988:            	@param resultSetNumber	The resultSetNumber for the ResultSet
0989:            	@param oneRowRightSide	boolean, whether or not the right side returns
0990:            							a single row.  (No need to do 2nd next() if it does.)
0991:            	@param notExistsRightSide	boolean, whether or not the right side resides a
0992:            								NOT EXISTS base table
0993:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
0994:            										optimizer
0995:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
0996:            	@param userSuppliedOptimizerOverrides		Overrides specified by the user on the sql
0997:            	@return the nested loop join operation as a result set.
0998:            	@exception StandardException thrown when unable to create the
0999:            		result set
1000:             */
1001:            public NoPutResultSet getHashJoinResultSet(
1002:                    NoPutResultSet leftResultSet, int leftNumCols,
1003:                    NoPutResultSet rightResultSet, int rightNumCols,
1004:                    GeneratedMethod joinClause, int resultSetNumber,
1005:                    boolean oneRowRightSide, boolean notExistsRightSide,
1006:                    double optimizerEstimatedRowCount,
1007:                    double optimizerEstimatedCost,
1008:                    String userSuppliedOptimizerOverrides)
1009:                    throws StandardException;
1010:
1011:            /**
1012:            	A nested loop join result set forms a result set on top of
1013:            	2 other result sets.
1014:            	The rows can be constructed as they are requested from the
1015:            	result set.
1016:            	<p>
1017:            	This form of the nested loop join operation is simple, and is
1018:            	to be used when there are no join predicates to be passed down
1019:            	to the join to limit its scope on the right ResultSet.
1020:
1021:            	@param leftResultSet	Outer ResultSet for join.
1022:            	@param leftNumCols		Number of columns in the leftResultSet
1023:            	@param rightResultSet	Inner ResultSet for join.
1024:            	@param rightNumCols		Number of columns in the rightResultSet
1025:            	@param joinClause a reference to a method in the activation
1026:            		that is applied to the activation's "current row" field
1027:            		to determine whether the joinClause is satisfied or not.
1028:            		The signature of this method is
1029:            		<verbatim>
1030:            			Boolean joinClause() throws StandardException;
1031:            		</verbatim>
1032:            	@param resultSetNumber	The resultSetNumber for the ResultSet
1033:            	@param emptyRowFun a reference to a method in the activation
1034:            						that is called if the right child returns no rows
1035:            	@param wasRightOuterJoin	Whether or not this was originally a right outer join
1036:            	@param oneRowRightSide	boolean, whether or not the right side returns
1037:            							a single row.  (No need to do 2nd next() if it does.)
1038:            	@param notExistsRightSide	boolean, whether or not the right side resides a
1039:            								NOT EXISTS base table
1040:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
1041:            										optimizer
1042:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
1043:            	@param userSuppliedOptimizerOverrides		Overrides specified by the user on the sql
1044:            	@return the nested loop join operation as a result set.
1045:            	@exception StandardException thrown when unable to create the
1046:            		result set
1047:             */
1048:            public NoPutResultSet getNestedLoopLeftOuterJoinResultSet(
1049:                    NoPutResultSet leftResultSet, int leftNumCols,
1050:                    NoPutResultSet rightResultSet, int rightNumCols,
1051:                    GeneratedMethod joinClause, int resultSetNumber,
1052:                    GeneratedMethod emptyRowFun, boolean wasRightOuterJoin,
1053:                    boolean oneRowRightSide, boolean notExistsRightSide,
1054:                    double optimizerEstimatedRowCount,
1055:                    double optimizerEstimatedCost,
1056:                    String userSuppliedOptimizerOverrides)
1057:                    throws StandardException;
1058:
1059:            /**
1060:            	A left outer join using a hash join.
1061:
1062:            	@param leftResultSet	Outer ResultSet for join.
1063:            	@param leftNumCols		Number of columns in the leftResultSet
1064:            	@param rightResultSet	Inner ResultSet for join.
1065:            	@param rightNumCols		Number of columns in the rightResultSet
1066:            	@param joinClause a reference to a method in the activation
1067:            		that is applied to the activation's "current row" field
1068:            		to determine whether the joinClause is satisfied or not.
1069:            		The signature of this method is
1070:            		<verbatim>
1071:            			Boolean joinClause() throws StandardException;
1072:            		</verbatim>
1073:            	@param resultSetNumber	The resultSetNumber for the ResultSet
1074:            	@param emptyRowFun a reference to a method in the activation
1075:            						that is called if the right child returns no rows
1076:            	@param wasRightOuterJoin	Whether or not this was originally a right outer join
1077:            	@param oneRowRightSide	boolean, whether or not the right side returns
1078:            							a single row.  (No need to do 2nd next() if it does.)
1079:            	@param notExistsRightSide	boolean, whether or not the right side resides a
1080:            								NOT EXISTS base table
1081:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
1082:            										optimizer
1083:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
1084:            	@param userSuppliedOptimizerOverrides		Overrides specified by the user on the sql
1085:            	@return the nested loop join operation as a result set.
1086:            	@exception StandardException thrown when unable to create the
1087:            		result set
1088:             */
1089:            public NoPutResultSet getHashLeftOuterJoinResultSet(
1090:                    NoPutResultSet leftResultSet, int leftNumCols,
1091:                    NoPutResultSet rightResultSet, int rightNumCols,
1092:                    GeneratedMethod joinClause, int resultSetNumber,
1093:                    GeneratedMethod emptyRowFun, boolean wasRightOuterJoin,
1094:                    boolean oneRowRightSide, boolean notExistsRightSide,
1095:                    double optimizerEstimatedRowCount,
1096:                    double optimizerEstimatedCost,
1097:                    String userSuppliedOptimizerOverrides)
1098:                    throws StandardException;
1099:
1100:            /**
1101:            	A ResultSet which materializes the underlying ResultSet tree into a 
1102:            	temp table on the 1st open.  All subsequent "scans" of this ResultSet
1103:            	will return results from the temp table.
1104:
1105:            	@param source the result set input to this result set.
1106:            	@param resultSetNumber	The resultSetNumber for the ResultSet
1107:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
1108:            										optimizer
1109:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
1110:            	@return the materialization operation as a result set.
1111:
1112:             	@exception StandardException		Thrown on failure
1113:             */
1114:            NoPutResultSet getMaterializedResultSet(NoPutResultSet source,
1115:                    int resultSetNumber, double optimizerEstimatedRowCount,
1116:                    double optimizerEstimatedCost) throws StandardException;
1117:
1118:            /**
1119:            	A ResultSet which provides the insensitive scrolling functionality
1120:            	for the underlying result set by materializing the underlying ResultSet 
1121:            	tree into a hash table while scrolling forward.
1122:
1123:            	@param source the result set input to this result set.
1124:            	@param activation the activation for this result set,
1125:            		which provides the context for normalization.
1126:            	@param resultSetNumber	The resultSetNumber for the ResultSet
1127:            	@param sourceRowWidth	The # of columns in the source row.
1128:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
1129:            										optimizer
1130:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
1131:            	@return the materialization operation as a result set.
1132:
1133:             	@exception StandardException		Thrown on failure
1134:             */
1135:            NoPutResultSet getScrollInsensitiveResultSet(NoPutResultSet source,
1136:                    Activation activation, int resultSetNumber,
1137:                    int sourceRowWidth, boolean scrollable,
1138:                    double optimizerEstimatedRowCount,
1139:                    double optimizerEstimatedCost) throws StandardException;
1140:
1141:            /**
1142:            	REMIND: needs more description...
1143:
1144:            	@param source the result set input to this result set.
1145:            	@param resultSetNumber	The resultSetNumber for the ResultSet
1146:            	@param erdNumber	int for ResultDescription 
1147:            						(so it can be turned back into an object)
1148:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
1149:            										optimizer
1150:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
1151:            	@return the normalization operation as a result set.
1152:
1153:             	@exception StandardException		Thrown on failure
1154:             */
1155:            NoPutResultSet getNormalizeResultSet(NoPutResultSet source,
1156:                    int resultSetNumber, int erdNumber,
1157:                    double optimizerEstimatedRowCount,
1158:                    double optimizerEstimatedCost, boolean forUpdate)
1159:                    throws StandardException;
1160:
1161:            /**
1162:            	A current of result set forms a result set on the
1163:            	current row of an open cursor.
1164:            	It is used to perform positioned operations such as
1165:            	positioned update and delete, using the result set paradigm.
1166:
1167:            	@param cursorName the name of the cursor providing the row.
1168:            	@param activation the activation for this result set,
1169:            		used to provide information about the result set.
1170:            	@param resultSetNumber	The resultSetNumber for the ResultSet
1171:             */
1172:            NoPutResultSet getCurrentOfResultSet(String cursorName,
1173:                    Activation activation, int resultSetNumber, String psName);
1174:
1175:            /**
1176:             * The Union interface is used to evaluate the union (all) of two ResultSets.
1177:             * (Any duplicate elimination is performed above this ResultSet.)
1178:             *
1179:             * Forms a ResultSet returning the union of the rows in two source
1180:             * ResultSets.  The column types in source1 and source2 are assumed to be
1181:             * the same.
1182:             *
1183:             * @param source1	The first ResultSet whose rows go into the union
1184:             * @param source2	The second ResultSet whose rows go into the
1185:             *			union
1186:             *	@param resultSetNumber	The resultSetNumber for the ResultSet
1187:             *	@param optimizerEstimatedRowCount	Estimated total # of rows by
1188:             *										optimizer
1189:             *	@param optimizerEstimatedCost		Estimated total cost by optimizer
1190:             *
1191:             * @return	A ResultSet from which the caller can get the union
1192:             *		of the two source ResultSets.
1193:             *
1194:             * @exception StandardException		Thrown on failure
1195:             */
1196:            NoPutResultSet getUnionResultSet(NoPutResultSet source1,
1197:                    NoPutResultSet source2, int resultSetNumber,
1198:                    double optimizerEstimatedRowCount,
1199:                    double optimizerEstimatedCost) throws StandardException;
1200:
1201:            /**
1202:             * The SetOpResultSet is used to implement an INTERSECT or EXCEPT operation.
1203:             * It selects rows from two ordered input result sets.
1204:             *
1205:             * @param leftSource The result set that implements the left input
1206:             * @param rightSource The result set that implements the right input
1207:             * @param activation the activation for this result set
1208:             * @param resultSetNumber
1209:             * @param optimizerEstimatedRowCount
1210:             * @param optimizerEstimatedCost
1211:             * @param opType IntersectOrExceptNode.INTERSECT_OP or EXCEPT_OP
1212:             * @param all true if the operation is an INTERSECT ALL or an EXCEPT ALL,
1213:             *            false if the operation is an INTERSECT DISCTINCT or an EXCEPT DISCTINCT
1214:             * @param intermediateOrderByColumnsSavedObject The saved object index for the array of order by columns for the
1215:             *        ordering of the left and right sources. That is, both the left and right sources have an order by
1216:             *        clause of the form ORDER BY intermediateOrderByColumns[0],intermediateOrderByColumns[1],...
1217:             * @param intermediateOrderByDirectionSavedObject The saved object index for the array of source
1218:             *        order by directions. That is, the ordering of the i'th order by column in the input is ascending
1219:             *        if intermediateOrderByDirection[i] is 1, descending if intermediateOrderByDirection[i] is -1.
1220:             *
1221:             * @return	A ResultSet from which the caller can get the INTERSECT or EXCEPT
1222:             *
1223:             * @exception StandardException		Thrown on failure
1224:             */
1225:            NoPutResultSet getSetOpResultSet(NoPutResultSet leftSource,
1226:                    NoPutResultSet rightSource, Activation activation,
1227:                    int resultSetNumber, long optimizerEstimatedRowCount,
1228:                    double optimizerEstimatedCost, int opType, boolean all,
1229:                    int intermediateOrderByColumnsSavedObject,
1230:                    int intermediateOrderByDirectionSavedObject)
1231:                    throws StandardException;
1232:
1233:            //
1234:            // Misc operations
1235:            //
1236:
1237:            /**
1238:             * A last index key result set returns the last row from
1239:             * the index in question.  It is used as an ajunct to max().
1240:             *
1241:             * @param activation 		the activation for this result set,
1242:             *		which provides the context for the row allocation operation.
1243:             * @param resultSetNumber	The resultSetNumber for the ResultSet
1244:             * @param resultRowAllocator a reference to a method in the activation
1245:             * 						that creates a holder for the result row of the scan.  May
1246:             *						be a partial row.  <verbatim>
1247:             *		ExecRow rowAllocator() throws StandardException; </verbatim>
1248:             * @param conglomId 		the conglomerate of the table to be scanned.
1249:             * @param tableName			The full name of the table
1250:             * @param userSuppliedOptimizerOverrides		Overrides specified by the user on the sql
1251:             * @param indexName			The name of the index, if one used to access table.
1252:             * @param colRefItem		An saved item for a bitSet of columns that
1253:             *							are referenced in the underlying table.  -1 if
1254:             *							no item.
1255:             * @param lockMode			The lock granularity to use (see
1256:             *							TransactionController in access)
1257:             * @param tableLocked		Whether or not the table is marked as using table locking
1258:             *							(in sys.systables)
1259:             * @param isolationLevel	Isolation level (specified or not) to use on scans
1260:             * @param optimizerEstimatedRowCount	Estimated total # of rows by
1261:             * 										optimizer
1262:             * @param optimizerEstimatedCost		Estimated total cost by optimizer
1263:             *
1264:             * @return the scan operation as a result set.
1265:             *
1266:             * @exception StandardException thrown when unable to create the
1267:             * 				result set
1268:             */
1269:            NoPutResultSet getLastIndexKeyResultSet(Activation activation,
1270:                    int resultSetNumber, GeneratedMethod resultRowAllocator,
1271:                    long conglomId, String tableName,
1272:                    String userSuppliedOptimizerOverrides, String indexName,
1273:                    int colRefItem, int lockMode, boolean tableLocked,
1274:                    int isolationLevel, double optimizerEstimatedRowCount,
1275:                    double optimizerEstimatedCost) throws StandardException;
1276:
1277:            /**
1278:            	A Dependent table scan result set forms a result set on a scan
1279:            	of a dependent table for the rows that got materilized 
1280:            	on the scan of its parent table and if the row being deleted
1281:            	on parent table has a reference in the dependent table.
1282:
1283:            	@param activation the activation for this result set,
1284:            		which provides the context for the row allocation operation.
1285:            	@param conglomId the conglomerate of the table to be scanned.
1286:            	@param scociItem The saved item for the static conglomerate info.
1287:            	@param resultRowAllocator a reference to a method in the activation
1288:            		that creates a holder for the result row of the scan.  May
1289:            		be a partial row.
1290:            		<verbatim>
1291:            			ExecRow rowAllocator() throws StandardException;
1292:            		</verbatim>
1293:            	@param resultSetNumber	The resultSetNumber for the ResultSet
1294:            	@param startKeyGetter a reference to a method in the activation
1295:            		that gets the start key indexable row for the scan.  Null
1296:            		means there is no start key.
1297:            		<verbatim>
1298:            			ExecIndexRow startKeyGetter() throws StandardException;
1299:            		</verbatim>
1300:            	@param startSearchOperator The start search operator for opening
1301:            		the scan
1302:            	@param stopKeyGetter	a reference to a method in the activation
1303:            		that gets the stop key indexable row for the scan.  Null means
1304:            		there is no stop key.
1305:            		<verbatim>
1306:            			ExecIndexRow stopKeyGetter() throws StandardException;
1307:            		</verbatim>
1308:            	@param stopSearchOperator	The stop search operator for opening
1309:            		the scan
1310:            	@param sameStartStopPosition	Re-use the startKeyGetter for the stopKeyGetter
1311:            									(Exact match search.)
1312:            	@param qualifiers the array of Qualifiers for the scan.
1313:            		Null or an array length of zero means there are no qualifiers.
1314:            	@param tableName		The full name of the table
1315:            	@param userSuppliedOptimizerOverrides		Overrides specified by the user on the sql
1316:            	@param indexName		The name of the index, if one used to access table.
1317:            	@param isConstraint		If index, if used, is a backing index for a constraint.
1318:            	@param forUpdate		True means open for update
1319:            	@param colRefItem		An saved item for a bitSet of columns that
1320:            							are referenced in the underlying table.  -1 if
1321:            							no item.
1322:            	@param lockMode			The lock granularity to use (see
1323:            							TransactionController in access)
1324:            	@param tableLocked		Whether or not the table is marked as using table locking
1325:            							(in sys.systables)
1326:            	@param isolationLevel	Isolation level (specified or not) to use on scans
1327:            	@param oneRowScan		Whether or not this is a 1 row scan.
1328:            	@param optimizerEstimatedRowCount	Estimated total # of rows by
1329:            										optimizer
1330:            	@param optimizerEstimatedCost		Estimated total cost by optimizer
1331:            	@param parentResultSetId  Id to access the materlized temporary result
1332:                                    	  set from the refence stored in the activation.
1333:            	@param fkIndexConglomId foreign key index conglomerate id.
1334:            	@param fkColArrayItem  saved column array object  that matches the foreign key index
1335:            	                       columns  and the resultset from the parent table.
1336:            	@param  rltItem row location template
1337:
1338:            	@return the table scan operation as a result set.
1339:            	@exception StandardException thrown when unable to create the
1340:            		result set
1341:             */
1342:            public NoPutResultSet getRaDependentTableScanResultSet(
1343:                    Activation activation, long conglomId, int scociItem,
1344:                    GeneratedMethod resultRowAllocator, int resultSetNumber,
1345:                    GeneratedMethod startKeyGetter, int startSearchOperator,
1346:                    GeneratedMethod stopKeyGetter, int stopSearchOperator,
1347:                    boolean sameStartStopPosition, Qualifier[][] qualifiers,
1348:                    String tableName, String userSuppliedOptimizerOverrides,
1349:                    String indexName, boolean isConstraint, boolean forUpdate,
1350:                    int colRefItem, int indexColItem, int lockMode,
1351:                    boolean tableLocked, int isolationLevel,
1352:                    boolean oneRowScan, double optimizerEstimatedRowCount,
1353:                    double optimizerEstimatedCost, String parentResultSetId,
1354:                    long fkIndexConglomId, int fkColArrayItem, int rltItem)
1355:                    throws StandardException;
1356:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.