T
- public class RemoteAsynchronousIteratorImpl<E> extends Object implements RemoteAsynchronousIterator<E>
IAsynchronousIterator
but
whose methods throw IOException
and are therefore compatible with
Remote
and Exporter
.RemoteAsynchronousIterator.RemoteElement<E>
Constructor and Description |
---|
RemoteAsynchronousIteratorImpl(IAsynchronousIterator<E> itr)
Ctor variant does not support
nextElement() . |
RemoteAsynchronousIteratorImpl(IAsynchronousIterator<E> itr,
IStreamSerializer<E> serializer)
Ctor variant optionally supports
nextElement() . |
Modifier and Type | Method and Description |
---|---|
void |
close() |
boolean |
hasNext() |
boolean |
hasNext(long timeout,
TimeUnit unit) |
boolean |
isExhausted() |
E |
next() |
E |
next(long timeout,
TimeUnit unit) |
RemoteAsynchronousIterator.RemoteElement<E> |
nextElement()
Method applies a custom serializer to the value returned by
RemoteAsynchronousIterator.next() and returns a RemoteAsynchronousIterator.RemoteElement that can be
transported by RMI and which knows how to de-serialize the element on the
other end. |
void |
remove() |
public RemoteAsynchronousIteratorImpl(IAsynchronousIterator<E> itr)
nextElement()
.itr
- The source iterator (local object).public RemoteAsynchronousIteratorImpl(IAsynchronousIterator<E> itr, IStreamSerializer<E> serializer)
nextElement()
.itr
- The source iterator (local object).serializer
- Optional, but nextElement()
only works when you
specify an IStreamSerializer
.public void close() throws IOException
close
in interface RemoteAsynchronousIterator<E>
IOException
ICloseableIterator.close()
public boolean hasNext() throws IOException
hasNext
in interface RemoteAsynchronousIterator<E>
IOException
Iterator.hasNext()
public boolean hasNext(long timeout, TimeUnit unit) throws IOException, InterruptedException
hasNext
in interface RemoteAsynchronousIterator<E>
IOException
InterruptedException
IAsynchronousIterator.hasNext(long, TimeUnit)
public boolean isExhausted() throws IOException
isExhausted
in interface RemoteAsynchronousIterator<E>
IOException
IAsynchronousIterator.isExhausted()
public E next() throws IOException
next
in interface RemoteAsynchronousIterator<E>
IOException
Iterator.next()
public E next(long timeout, TimeUnit unit) throws IOException, InterruptedException
next
in interface RemoteAsynchronousIterator<E>
IOException
InterruptedException
IAsynchronousIterator.next(long, TimeUnit)
public void remove() throws IOException
remove
in interface RemoteAsynchronousIterator<E>
IOException
Iterator.remove()
public RemoteAsynchronousIterator.RemoteElement<E> nextElement()
RemoteAsynchronousIterator
RemoteAsynchronousIterator.next()
and returns a RemoteAsynchronousIterator.RemoteElement
that can be
transported by RMI and which knows how to de-serialize the element on the
other end.nextElement
in interface RemoteAsynchronousIterator<E>
UnsupportedOperationException
- if you did not specify an IStreamSerializer
to the ctor.Copyright © 2006–2019 SYSTAP, LLC DBA Blazegraph. All rights reserved.