|
|||||||||
| Home >> All >> nl >> aidministrator >> rdf >> ral >> [ rdbms overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
nl.aidministrator.rdf.ral.rdbms
Class RecursiveSQLResourceIterator

java.lang.Objectnl.aidministrator.rdf.ral.rdbms.RecursiveSQLResourceIterator
- All Implemented Interfaces:
- nl.aidministrator.rdf.ral.ResourceIterator
- public class RecursiveSQLResourceIterator
- extends java.lang.Object
- implements nl.aidministrator.rdf.ral.ResourceIterator
- extends java.lang.Object
A ResourceIterator that executes SQL queries recursively by re-inserting part of the query's results into the query. The query should contain EXACTLY ONE IN-parameter (i.e. there is one '?' in the query) and the ResultSet should contain the following columns: id (int), namespace (String) and localname (String). The first value (the id) will be re-inserted into the query.
- Version:
- 1.4, 01/02/02
| Field Summary | |
protected java.sql.Connection |
_databaseCon
Connection to the database. |
protected java.util.Set |
_iterated
Stores Resources that have already been iterated. |
protected java.util.Vector |
_resultsQueue
Queue containing the results. |
protected java.sql.PreparedStatement |
_statement
The query in the form of a PreparedStatement. |
| Constructor Summary | |
RecursiveSQLResourceIterator(java.sql.Connection databaseCon,
java.lang.String query,
IdResource initialResource)
Constructor. |
|
| Method Summary | |
private void |
_add(nl.aidministrator.rdf.sail.model.Resource resource)
|
private void |
_fillQueue(int value)
|
void |
close()
Closes all connections to the repository. |
protected void |
finalize()
Called by the garbage collector on SQLValueIterator when garbage collection determines that there are no more references to the SQLValueIterator. |
boolean |
hasNext()
Checks whether there are any more results available. |
nl.aidministrator.rdf.sail.model.Value |
next()
Gets the next result. |
| Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
_databaseCon
protected java.sql.Connection _databaseCon
- Connection to the database.
_statement
protected java.sql.PreparedStatement _statement
- The query in the form of a PreparedStatement.
_resultsQueue
protected java.util.Vector _resultsQueue
- Queue containing the results.
_iterated
protected java.util.Set _iterated
- Stores Resources that have already been iterated. This prevents looping
of the iterator and therefore supports multiple inheritance and loops
in the class or property hierarchy.
| Constructor Detail |
RecursiveSQLResourceIterator
public RecursiveSQLResourceIterator(java.sql.Connection databaseCon, java.lang.String query, IdResource initialResource) throws java.sql.SQLException
- Constructor.
| Method Detail |
_add
private void _add(nl.aidministrator.rdf.sail.model.Resource resource)
_fillQueue
private void _fillQueue(int value)
hasNext
public boolean hasNext()
- Description copied from interface:
nl.aidministrator.rdf.ral.ResourceIterator - Checks whether there are any more results available.
- Specified by:
hasNextin interfacenl.aidministrator.rdf.ral.ResourceIterator
next
public nl.aidministrator.rdf.sail.model.Value next()
- Gets the next result.
- Specified by:
nextin interfacenl.aidministrator.rdf.ral.ResourceIterator
close
public void close()
- Description copied from interface:
nl.aidministrator.rdf.ral.ResourceIterator - Closes all connections to the repository.
- Specified by:
closein interfacenl.aidministrator.rdf.ral.ResourceIterator
finalize
protected void finalize()
- Called by the garbage collector on SQLValueIterator when garbage
collection determines that there are no more references to the
SQLValueIterator.
|
|||||||||
| Home >> All >> nl >> aidministrator >> rdf >> ral >> [ rdbms overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
nl.aidministrator.rdf.ral.rdbms.RecursiveSQLResourceIterator