T
- public interface RDFIterator<T> extends Iterator<T>, AutoCloseable
This iterator differentiates from standard Iterator
interface in that it explicitly declares to
throw exceptions in its methods.
RDFIterator however still extends the Iterator
interface so that all the methods which are
available in standard Java and third party libraries (such as google collections
, which is
used by this library) can still be used
User should however always make explicit use of methods specific to this interface and avoid use of the
standard ones provided by the Iterator
class
The contract of this iterator does not foresee the remove
method to be implemented.
Expect a runtime exception to be thrown when accessing this method
Modifier and Type | Method and Description |
---|---|
void |
close()
closes the iterator and release resources
|
T |
getNext()
gets the next element of the iterator, and advances over the data stream (roughly
equivalent to traditional
next() iterator method) |
boolean |
streamOpen()
tells if the data stream associated to this iterator is not empty (roughly
equivalent to traditional
hasNext() iterator method) |
boolean streamOpen() throws ModelAccessException
hasNext()
iterator method)ModelAccessException
T getNext() throws ModelAccessException
next()
iterator method)ModelAccessException
void close() throws ModelAccessException
close
in interface AutoCloseable
ModelAccessException
Copyright © 2015 ART Group, University of Rome, Tor Vergata. All Rights Reserved.