01: /*
02:
03: Derby - Class org.apache.derby.iapi.store.access.ScanInfo
04:
05: Licensed to the Apache Software Foundation (ASF) under one or more
06: contributor license agreements. See the NOTICE file distributed with
07: this work for additional information regarding copyright ownership.
08: The ASF licenses this file to you under the Apache License, Version 2.0
09: (the "License"); you may not use this file except in compliance with
10: the License. You may obtain a copy of the License at
11:
12: http://www.apache.org/licenses/LICENSE-2.0
13:
14: Unless required by applicable law or agreed to in writing, software
15: distributed under the License is distributed on an "AS IS" BASIS,
16: WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17: See the License for the specific language governing permissions and
18: limitations under the License.
19:
20: */
21:
22: package org.apache.derby.iapi.store.access;
23:
24: import org.apache.derby.iapi.error.StandardException;
25:
26: import java.util.Properties;
27:
28: /**
29:
30: This object provides performance information related to an open scan.
31: The information is accumulated during operations on a ScanController() and
32: then copied into this object and returned by a call to
33: ScanController.getStatistic().
34:
35: @see GenericScanController#getScanInfo()
36:
37: **/
38:
39: public interface ScanInfo {
40: /**
41: * Return all information gathered about the scan.
42: * <p>
43: * This routine returns a list of properties which contains all information
44: * gathered about the scan. If a Property is passed in, then that property
45: * list is appeneded to, otherwise a new property object is created and
46: * returned.
47: * <p>
48: * Not all scans may support all properties, if the property is not
49: * supported then it will not be returned. The following is a list of
50: * properties that may be returned. These names have been internationalized,
51: * the names shown here are the old, non-internationalized names:
52: *
53: * scanType
54: * - type of the scan being performed:
55: * btree
56: * heap
57: * sort
58: * numPagesVisited
59: * - the number of pages visited during the scan. For btree scans
60: * this number only includes the leaf pages visited.
61: * numDeletedRowsVisited
62: * - the number of deleted rows visited during the scan. This
63: * number includes only those rows marked deleted.
64: * numRowsVisited
65: * - the number of rows visited during the scan. This number
66: * includes all rows, including: those marked deleted, those
67: * that don't meet qualification, ...
68: * numRowsQualified
69: * - the number of rows which met the qualification.
70: * treeHeight (btree's only)
71: * - for btree's the height of the tree. A tree with one page
72: * has a height of 1. Total number of pages visited in a btree
73: * scan is (treeHeight - 1 + numPagesVisited).
74: * numColumnsFetched
75: * - the number of columns Fetched - partial scans will result
76: * in fetching less columns than the total number in the scan.
77: * columnsFetchedBitSet
78: * - The BitSet.toString() method called on the validColumns arg.
79: * to the scan, unless validColumns was set to null, and in that
80: * case we will return "all".
81: * NOTE - this list will be expanded as more information about the scan
82: * is gathered and returned.
83: *
84: * @param prop Property list to fill in.
85: *
86: * @exception StandardException Standard exception policy.
87: **/
88: Properties getAllScanInfo(Properties prop) throws StandardException;
89: }
|