com.bigdata.rdf.spo
Class DistinctSPOIterator
java.lang.Object
com.bigdata.rdf.spo.DistinctSPOIterator
- All Implemented Interfaces:
- ICloseableIterator<ISPO>, Iterator<ISPO>
public class DistinctSPOIterator
- extends Object
- implements ICloseableIterator<ISPO>
Iterator using a BTree filter out duplicate (s,p,o) tuples.
- Version:
- $Id: DistinctSPOIterator.java 2265 2009-10-26 12:51:06Z thompsonbry $
- Author:
- Bryan Thompson
- See Also:
SPORelation.distinctSPOIterator(ICloseableIterator)
|
Method Summary |
void |
close()
Closes the iterator, releasing any associated resources. |
boolean |
hasNext()
Returns immediately if there is an element waiting. |
ISPO |
next()
|
void |
remove()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DistinctSPOIterator
public DistinctSPOIterator(SPORelation spoRelation,
ICloseableIterator<ISPO> src)
- Parameters:
src - The source iterator.
close
public void close()
- Description copied from interface:
ICloseableIterator
- Closes the iterator, releasing any associated resources. This method MAY
be invoked safely if the iterator is already closed.
Note: Implementations that support Iterator.remove() MUST NOT
eagerly close the iterator when it is exhausted since that would make it
impossible to remove the last visited statement. Instead they MUST wait
for an explicit ICloseableIterator.close() by the application.
- Specified by:
close in interface ICloseableIterator<ISPO>
hasNext
public boolean hasNext()
- Returns immediately if there is an element waiting. Otherwise, scans
ahead until it finds an element which has not already been visited. It
then add the element to the set of elements already seen and saves a
reference to that element to be returned by
next().
- Specified by:
hasNext in interface Iterator<ISPO>
next
public ISPO next()
- Specified by:
next in interface Iterator<ISPO>
remove
public void remove()
- Specified by:
remove in interface Iterator<ISPO>
Copyright © 2006-2009 SYSTAP, LLC. All Rights Reserved.