org.openanzo.jastor
Class CachedPropertyIterator<E>
java.lang.Object
org.openanzo.jastor.CachedPropertyIterator<E>
- Type Parameters:
E - The Jastor Type for the values that this iterator of properties represents
- All Implemented Interfaces:
- info.aduna.collections.iterators.CloseableIterator<E>, java.io.Closeable, java.util.Iterator<E>
public class CachedPropertyIterator<E>
- extends java.lang.Object
- implements info.aduna.collections.iterators.CloseableIterator<E>
Iterator that iterates over the set of object values for a given property on a given subject. Based on doing a find within
the NamedGraph for the given subject and property
- Author:
- Ben Szekely (bhszekel@us.ibm.com)
|
Constructor Summary |
CachedPropertyIterator(java.util.Collection<E> cache,
INamedGraph graph,
org.openrdf.model.Resource resource,
org.openrdf.model.URI property,
java.lang.String rangeUri,
boolean objectProperty)
Create iterator of object values for a given property on a given subject. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CachedPropertyIterator
public CachedPropertyIterator(java.util.Collection<E> cache,
INamedGraph graph,
org.openrdf.model.Resource resource,
org.openrdf.model.URI property,
java.lang.String rangeUri,
boolean objectProperty)
- Create iterator of object values for a given property on a given subject. Uses a cached collection of values and not a
find operation
- Parameters:
cache - Cache of values for propertygraph - INamedGraph that contains data to searchresource - Subject of statements to findproperty - Property of statements to findrangeUri - URI of this properties rangeobjectProperty - Flag specifying if property is ObjectProperty or DatatypeProperty
hasNext
public boolean hasNext()
- Specified by:
hasNext in interface java.util.Iterator<E>
next
public E next()
- Specified by:
next in interface java.util.Iterator<E>
remove
public void remove()
- Specified by:
remove in interface java.util.Iterator<E>
close
public void close()
- Specified by:
close in interface info.aduna.collections.iterators.CloseableIterator<E>- Specified by:
close in interface java.io.Closeable
Copyright © 2007 Cambridge Semantics Inc.. All Rights Reserved.