Module org.eclipse.persistence.core
Class RemoteCursoredStream
- java.lang.Object
-
- org.eclipse.persistence.queries.Cursor
-
- org.eclipse.persistence.queries.CursoredStream
-
- org.eclipse.persistence.internal.sessions.remote.RemoteCursoredStream
-
- All Implemented Interfaces:
Serializable,Enumeration,Iterator
public class RemoteCursoredStream extends CursoredStream
Purpose: The object is used as a wrapper to the CursoredStream object in the remote transaction (via RMI, CORBA, etc.)
Responsibilities: Wraps a database result set cursor to provide a stream to the remote client side on the resulting selected objects.
- Since:
- TOPLink/Java 3.0
- Author:
- King (Yaoping) Wang
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected ObjIDidThis is a unique id for remote cursored streamprotected booleanisClosedReturn if the stream is closed.protected intpageSizeReturn the cursored stream page size.-
Fields inherited from class org.eclipse.persistence.queries.CursoredStream
marker
-
Fields inherited from class org.eclipse.persistence.queries.Cursor
executionSession, fields, initiallyConformingIndex, nextRow, objectCollection, policy, position, query, resultSet, selectionCriteriaClone, session, size, statement, translationRow
-
-
Constructor Summary
Constructors Constructor Description RemoteCursoredStream(CursoredStream serverCursoredStream)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()Close the wrapped cursored stream This should be performed whenever the user has finished with the stream.protected intgetCursorSize()INTERNAL: Retreive the size of the wrapped cursored stream.ObjIDgetID()INTERNAL: Retrieve the OID of the wrapped cursored stream.booleanisClosed()INTERNAL: Return if the stream is closed.protected ObjectretrieveNextPage()Read the next page of objects from the server.-
Methods inherited from class org.eclipse.persistence.queries.CursoredStream
atEnd, available, buildCountDistinctExpression, clear, copy, getInitialReadSize, getMarker, getPageSize, getPosition, hasMoreElements, hasNext, mark, markSupported, next, next, nextElement, nextElements, peek, read, read, releasePrevious, reset, retrieveNextObject, setLimits, setMarker
-
Methods inherited from class org.eclipse.persistence.queries.Cursor
buildAndRegisterObject, finalize, getAccessor, getExecutionSession, getFields, getInitiallyConformingIndex, getObjectCollection, getPolicy, getQuery, getResultSet, getSelectionCriteriaClone, getSession, getStatement, getTranslationRow, remove, setExecutionSession, setFields, setInitiallyConformingIndex, setObjectCollection, setPolicy, setPosition, setResultSet, setSelectionCriteriaClone, setSession, setSize, setTranslationRow, size
-
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Enumeration
asIterator
-
Methods inherited from interface java.util.Iterator
forEachRemaining
-
-
-
-
Field Detail
-
id
protected ObjID id
This is a unique id for remote cursored stream
-
isClosed
protected boolean isClosed
Return if the stream is closed.
-
pageSize
protected int pageSize
Return the cursored stream page size.
-
-
Constructor Detail
-
RemoteCursoredStream
public RemoteCursoredStream(CursoredStream serverCursoredStream)
-
-
Method Detail
-
close
public void close() throws DatabaseExceptionClose the wrapped cursored stream This should be performed whenever the user has finished with the stream.- Overrides:
closein classCursor- Throws:
DatabaseException
-
getCursorSize
protected int getCursorSize()
INTERNAL: Retreive the size of the wrapped cursored stream.- Overrides:
getCursorSizein classCursoredStream
-
getID
public ObjID getID()
INTERNAL: Retrieve the OID of the wrapped cursored stream.
-
isClosed
public boolean isClosed()
INTERNAL: Return if the stream is closed.
-
retrieveNextPage
protected Object retrieveNextPage() throws DatabaseException
Read the next page of objects from the server.- Overrides:
retrieveNextPagein classCursoredStream- Throws:
DatabaseException
-
-