public class MetricInstrumentedIterator extends Object implements KeyIterator
MetricInstrumentedStore to measure wallclock
time, method invocation counts, and exceptions thrown by the methods on
RecordIterator instances returned from
MetricInstrumentedStore.getSlice(com.thinkaurelius.titan.diskstorage.keycolumnvalue.KeySliceQuery, com.thinkaurelius.titan.diskstorage.keycolumnvalue.StoreTransaction).| Modifier and Type | Method and Description |
|---|---|
void |
close() |
RecordIterator<Entry> |
getEntries()
Returns an iterator over all entries associated with the current
key that match the column range specified in the query.
|
boolean |
hasNext() |
StaticBuffer |
next() |
static MetricInstrumentedIterator |
of(KeyIterator keyIterator,
String... prefix)
If the iterator argument is non-null, then return a new
MetricInstrumentedIterator wrapping it. |
void |
remove() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEachRemainingpublic static MetricInstrumentedIterator of(KeyIterator keyIterator, String... prefix)
MetricInstrumentedIterator wrapping it. Metrics for method calls
on the wrapped instance will be prefixed with the string prefix
which must be non-null. If the iterator argument is null, then return
null.keyIterator - the iterator to wrap with Metrics measurementsprefix - the Metrics name prefix stringkeyIterator or null if
keyIterator is nullpublic boolean hasNext()
hasNext in interface Iterator<StaticBuffer>public StaticBuffer next()
next in interface Iterator<StaticBuffer>public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableIOExceptionpublic RecordIterator<Entry> getEntries()
KeyIteratorIterator.next() might close previously returned RecordIterators
depending on the implementation, hence it is important to iterate over
(and close) the RecordIterator before calling Iterator.next() or Iterator.hasNext().getEntries in interface KeyIteratorpublic void remove()
remove in interface Iterator<StaticBuffer>Copyright © 2012–2015. All rights reserved.