Remote adapter for the JCR RangeIterator
interface. This
class makes a local iterator available as an RMI service using the
RemoteIterator
interface.
@Deprecated public abstract class ServerIterator extends ServerObject implements RemoteIterator
ref
Constructor and Description |
---|
ServerIterator(RangeIterator iterator,
RemoteAdapterFactory factory,
int maxBufferSize)
Deprecated.
Creates a remote adapter for the given local item.
|
Modifier and Type | Method and Description |
---|---|
protected abstract Object |
getRemoteObject(Object object)
Deprecated.
Returns a remote adapter for the given local object.
|
long |
getSize()
Deprecated.
Returns the size of the iterator.
|
Object[] |
nextObjects()
Deprecated.
Returns an array of remote references to the next elements in this
iteration.
|
void |
skip(long items)
Deprecated.
Skips the given number of elements.
|
getFactory, getRemoteItem, getRemoteNode, getRemoteNodeTypeArray, getRepositoryException, getSerialValue, getSerialValues
clone, exportObject, exportObject, exportObject, unexportObject
getClientHost, getLog, setLog
public ServerIterator(RangeIterator iterator, RemoteAdapterFactory factory, int maxBufferSize) throws RemoteException
iterator
- local iterator to be adaptedfactory
- remote adapter factorymaxBufferSize
- maximum buffer sizeRemoteException
- on RMI errorspublic long getSize() throws RemoteException
getSize
in interface RemoteIterator
RemoteException
- on RMI errorsRangeIterator.getSize()
public void skip(long items) throws NoSuchElementException, RemoteException
skip
in interface RemoteIterator
items
- number of elements to skipNoSuchElementException
- if skipped past the last elementRemoteException
- on RMI errorsRangeIterator.skip(long)
protected abstract Object getRemoteObject(Object object) throws RemoteException
nextObjects()
to convert the local
objects to remote references to be sent to the client.
Subclasses should implement this method to use the remote adapter factory to create remote adapters of the specific element type.
object
- local objectRemoteException
- on RMI errorspublic Object[] nextObjects() throws RemoteException
nextObjects
in interface RemoteIterator
null
RemoteException
- on RMI errorsIterator.next()
Copyright © 2004–2024 The Apache Software Foundation. All rights reserved.