Source Code Cross Referenced for RowIterator.java in  » Database-DBMS » axion » org » axiondb » 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 » axion » org.axiondb 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * $Id: RowIterator.java,v 1.12 2005/04/22 02:28:53 ahimanikya Exp $
003:         * =======================================================================
004:         * Copyright (c) 2002-2005 Axion Development Team.  All rights reserved.
005:         *  
006:         * Redistribution and use in source and binary forms, with or without 
007:         * modification, are permitted provided that the following conditions 
008:         * are met:
009:         * 
010:         * 1. Redistributions of source code must retain the above 
011:         *    copyright notice, this list of conditions and the following 
012:         *    disclaimer. 
013:         *   
014:         * 2. Redistributions in binary form must reproduce the above copyright 
015:         *    notice, this list of conditions and the following disclaimer in 
016:         *    the documentation and/or other materials provided with the 
017:         *    distribution. 
018:         *   
019:         * 3. The names "Tigris", "Axion", nor the names of its contributors may 
020:         *    not be used to endorse or promote products derived from this 
021:         *    software without specific prior written permission. 
022:         *  
023:         * 4. Products derived from this software may not be called "Axion", nor 
024:         *    may "Tigris" or "Axion" appear in their names without specific prior
025:         *    written permission.
026:         *   
027:         * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
028:         * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
029:         * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
030:         * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 
031:         * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 
032:         * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 
033:         * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 
034:         * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 
035:         * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 
036:         * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 
037:         * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
038:         * =======================================================================
039:         */
040:
041:        package org.axiondb;
042:
043:        import java.util.NoSuchElementException;
044:
045:        /**
046:         * A bidirectional iterator over a collection of {@link Row}s.
047:         * 
048:         * @version $Revision: 1.12 $ $Date: 2005/04/22 02:28:53 $
049:         * @author Rodney Waldhoff
050:         * @author Ahimanikya Satapathy
051:         */
052:        public interface RowIterator {
053:
054:            /**
055:             * Add a {@link Row}at the current position in my underlying collection, or throw
056:             * {@link UnsupportedOperationException}. (Optional operation.)
057:             */
058:            void add(Row row) throws UnsupportedOperationException,
059:                    AxionException;
060:
061:            /**
062:             * Returns the last {@link Row}returned by me (by {@link #next},{@link #previous},
063:             * {@link #first},{@link #last}, etc.).
064:             * 
065:             * @throws NoSuchElementException when no {@link Row}has yet been returned
066:             */
067:            Row current() throws NoSuchElementException;
068:
069:            /**
070:             * Returns the index of the {@link #current}row, if any.
071:             * 
072:             * @throws NoSuchElementException when no {@link Row}has yet been returned
073:             */
074:            int currentIndex() throws NoSuchElementException;
075:
076:            /**
077:             * Returns the first {@link Row}in the list, positioning the cursor to just before
078:             * the first {@link Row}in the list. (In other words, after <code>first</code> is
079:             * called both {@link #next}and {@link #current}will return the first row in the
080:             * list.)
081:             * 
082:             * @throws NoSuchElementException when there is no first {@link Row}
083:             * @throws AxionException when a problem occurs accessing the {@link Row}
084:             */
085:            Row first() throws NoSuchElementException, AxionException;
086:
087:            /**
088:             * Returns <code>true</code> if I have a current {@link Row}. (In other words,
089:             * returns <code>true</code> iff {@link #current}would return a {@link Row}rather
090:             * than throwing an exception.)
091:             */
092:            boolean hasCurrent();
093:
094:            /**
095:             * Returns <code>true</code> if I have more {@link Row}s when traversing the list
096:             * in the forward direction. (In other words, returns <code>true</code> iff
097:             * {@link #next}would return a {@link Row}rather than throwing an exception.)
098:             */
099:            boolean hasNext();
100:
101:            /**
102:             * Returns <code>true</code> if I have more {@link Row}s when traversing the list
103:             * in the reverse direction. (In other words, returns <code>true</code> iff
104:             * {@link #previous}would return a {@link Row}rather than throwing an exception.)
105:             */
106:            boolean hasPrevious();
107:
108:            /**
109:             * Returns <code>true</code> if there are no rows to report with this iterator.
110:             */
111:            boolean isEmpty();
112:
113:            /**
114:             * Returns the last {@link Row}in the list, positioning the cursor to just after the
115:             * last {@link Row}in the list. (In other words, after <code>last</code> is called
116:             * both {@link #previous}and {@link #current}will return the last row in the list.)
117:             * 
118:             * @throws NoSuchElementException when there is no last {@link Row}
119:             * @throws AxionException when a problem occurs accessing the {@link Row}
120:             */
121:            Row last() throws NoSuchElementException, AxionException;
122:
123:            /**
124:             * Returns the next {@link Row}in the list, or throws
125:             * {@link java.util.NoSuchElementException}if no next <code>Row</code> exists.
126:             * 
127:             * @throws NoSuchElementException when there is no next {@link Row}
128:             * @throws AxionException when a problem occurs accessing the {@link Row}
129:             */
130:            Row next() throws NoSuchElementException, AxionException;
131:
132:            /**
133:             * Sets the current iterator position to currentIndex() + count; this will not set the
134:             * current row, peekPrevious() may be used to return the current row. This will
135:             * provide random access e.g one can postion the cursor before the desired row and
136:             * then call next().
137:             */
138:            int next(int count) throws AxionException;
139:
140:            /**
141:             * Returns the index of the {@link #next}row, if any, or the number of elements is
142:             * the iterator if we've reached the end.
143:             */
144:            int nextIndex();
145:
146:            /**
147:             * Return the value that would be returned by a call to {@link #next}, if any, but
148:             * don't update my position.
149:             * 
150:             * @throws NoSuchElementException when there is no next {@link Row}
151:             * @throws AxionException when a problem occurs accessing the {@link Row}
152:             */
153:            Row peekNext() throws NoSuchElementException, AxionException;
154:
155:            /**
156:             * Return the value that would be returned by a call to {@link #previous}, if any,
157:             * but don't update my position.
158:             * 
159:             * @throws NoSuchElementException when there is no previous {@link Row}
160:             * @throws AxionException when a problem occurs accessing the {@link Row}
161:             */
162:            Row peekPrevious() throws NoSuchElementException, AxionException;
163:
164:            /**
165:             * Returns the previous {@link Row}in the list, or throws
166:             * {@link java.util.NoSuchElementException}if no next <code>Row</code> exists.
167:             * 
168:             * @throws NoSuchElementException when there is no next {@link Row}
169:             * @throws AxionException when a problem occurs accessing the {@link Row}
170:             */
171:            Row previous() throws NoSuchElementException, AxionException;
172:
173:            /**
174:             * Sets the current iterator position to currentIndex() - count; this will not set the
175:             * current row, peekNext() may be used to return the current row. This will provide
176:             * random access e.g one can postion the cursor after the desired row and then call
177:             * previous().
178:             */
179:            int previous(int count) throws AxionException;
180:
181:            /**
182:             * Returns the index of the {@link #previous}row, if any, or -1 if we're add the
183:             * beginning of the list.
184:             */
185:            int previousIndex();
186:
187:            /**
188:             * Set the {@link Row}at the current position in my underlying collection, or throw
189:             * {@link UnsupportedOperationException}. (Optional operation.)
190:             */
191:            void remove() throws UnsupportedOperationException, AxionException;
192:
193:            /**
194:             * Re-initialize this <code>RowIterator</code> to its initial state (positioned just
195:             * before the first {@link Row}in the list).
196:             */
197:            void reset() throws AxionException;
198:
199:            /**
200:             * Set the {@link Row}at the current position in my underlying collection, or throw
201:             * {@link UnsupportedOperationException}. (Optional operation.)
202:             */
203:            void set(Row row) throws UnsupportedOperationException,
204:                    AxionException;
205:
206:            /**
207:             * Retunrs the current size of the underlaying row collection
208:             */
209:            int size() throws AxionException;
210:
211:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.