E
- The type of the objects visited by the source iterator.public abstract class Advancer<E> extends FilterBase implements ITupleFilter<E>
ITupleCursor
to another key
after it visits some element. For example, the "distinct term scan" for
the RDF DB is written in this manner.Modifier and Type | Field and Description |
---|---|
protected static org.apache.log4j.Logger |
log |
protected ITupleCursor<E> |
src
Set by
#filter(ITupleCursor) . |
Modifier | Constructor and Description |
---|---|
protected |
Advancer() |
Modifier and Type | Method and Description |
---|---|
protected abstract void |
advance(ITuple<E> tuple)
Offers an opportunity to advance the source
ITupleCursor to a
new key using {@link ITupleCursor#seek(byte[]). |
ITupleIterator<E> |
filterOnce(Iterator src,
Object context)
Wrap the source iterator with this filter.
|
protected boolean |
init()
Hook for one-time initialization invoked before the advancer visits the
first tuple.
|
addFilter, filter, getProperty, getRequiredProperty, setProperty, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getProperty
protected static final transient org.apache.log4j.Logger log
protected ITupleCursor<E> src
#filter(ITupleCursor)
.public final ITupleIterator<E> filterOnce(Iterator src, Object context)
FilterBase
filterOnce
in interface ITupleFilter<E>
filterOnce
in class FilterBase
src
- The source iterator (MUST be an ITupleCursor
).context
- The iterator evaluation context.protected boolean init()
true
.false
if nothing should be visited.protected abstract void advance(ITuple<E> tuple)
ITupleCursor
to a
new key using {@link ITupleCursor#seek(byte[]).tuple
- The current value.Copyright © 2006–2019 SYSTAP, LLC DBA Blazegraph. All rights reserved.