wt.query
Class PagingSessionSpec

java.lang.Object
  extended bywt.query.PageableQuerySpec
      extended bywt.query.PagingSessionSpec
All Implemented Interfaces:
Externalizable, Serializable, StatementSpec

public final class PagingSessionSpec
extends PageableQuerySpec
implements Externalizable

This class can be used to fetch pages from an established paging session.

Supported API: true

Extendable: false

See Also:
Serialized Form

Field Summary
private  boolean allPersistable
           
private static String CLASSNAME
           
static long EXTERNALIZATION_VERSION_UID
           
private  int groupFromIndex
           
protected static long OLD_FORMAT_VERSION_UID
           
private static String RESOURCE
           
(package private) static long serialVersionUID
           
private  long sessionId
           
private  int totalSize
           
 
Fields inherited from class wt.query.PageableQuerySpec
 
Fields inherited from interface wt.pds.StatementSpec
ADVANCED_QUERY, ADVANCED_QUERY_ENABLED, AGGREGATE_SELECT, CORRELATED_CLASS_ATTRIBUTES, FETCH_SIZE, PRIMARY_CLASS, QUERY_LIMIT, RESULT_BUILDER, RESULT_CURSOR, SINGLE_RESULT_COMPATIBLE, STATEMENT_BUILDER, USE_BIND
 
Constructor Summary
  PagingSessionSpec()
          

Supported API: false
  PagingSessionSpec(long a_sessionId)
          

Supported API: false
(package private) PagingSessionSpec(StatementSpec a_primaryStatement, long a_sessionId, int a_totalSize)
           
 
Method Summary
 boolean bind()
           
private  void bindPagingParameter(QuerySpec a_qs, int a_start, int a_end)
           
 int getGroupFromIndex()
          Gets the value of the attribute: groupFromIndex.
 long getSessionId()
          Gets the value of the attribute: sessionId; Identifies a persistent paging session.
 int getTotalSize()
          Gets the value of the attribute: totalSize; Specifies the total number of results that can be paged through.
 boolean isAllPersistable()
          Gets the value of the attribute: allPersistable.
 void readExternal(ObjectInput input)
          Reads the non-transient fields of this class from an external source.
private  boolean readOldVersion(ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone)
          Reads the non-transient fields of this class from an external source, which is not the current version.
protected  boolean readVersion(PagingSessionSpec thisObject, ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone)
          Reads the non-transient fields of this class from an external source.
 void setAllPersistable(boolean a_AllPersistable)
          Sets the value of the attribute: allPersistable.
 void setGroupFromIndex(int a_GroupFromIndex)
          Sets the value of the attribute: groupFromIndex.
 void writeExternal(ObjectOutput output)
          Writes the non-transient fields of this class to an external source.
 
Methods inherited from class wt.query.PageableQuerySpec
getBindParameterCount, getCorrelatedClassAttributes, getFetchSize, getOffset, getPrimaryClass, getPrimaryStatement, getQueryLimit, getRange, getResultBuilder, getResultCursor, getStatementBuilder, isAdvancedQuery, isAdvancedQueryEnabled, isAggregateSelect, isSingleResultCompatible, isUseBind, readVersion, setAdvancedQueryEnabled, setBindParameterAt, setFetchSize, setLocale, setOffset, setPrimaryStatement, setRange, setUseBind
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RESOURCE

private static final String RESOURCE
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME

totalSize

private int totalSize

sessionId

private long sessionId

allPersistable

private boolean allPersistable

groupFromIndex

private int groupFromIndex

serialVersionUID

static final long serialVersionUID
See Also:
Constant Field Values

EXTERNALIZATION_VERSION_UID

public static final long EXTERNALIZATION_VERSION_UID
See Also:
Constant Field Values

OLD_FORMAT_VERSION_UID

protected static final long OLD_FORMAT_VERSION_UID
See Also:
Constant Field Values
Constructor Detail

PagingSessionSpec

public PagingSessionSpec()


Supported API: false


PagingSessionSpec

public PagingSessionSpec(long a_sessionId)


Supported API: false

Parameters:
a_sessionId - Identifier a persistent paging session

PagingSessionSpec

PagingSessionSpec(StatementSpec a_primaryStatement,
                  long a_sessionId,
                  int a_totalSize)
            throws WTPropertyVetoException
Method Detail

writeExternal

public void writeExternal(ObjectOutput output)
                   throws IOException
Writes the non-transient fields of this class to an external source.

Supported API: false

Specified by:
writeExternal in interface Externalizable
Overrides:
writeExternal in class PageableQuerySpec
Parameters:
output -
Throws:
IOException

readExternal

public void readExternal(ObjectInput input)
                  throws IOException,
                         ClassNotFoundException
Reads the non-transient fields of this class from an external source.

Supported API: false

Specified by:
readExternal in interface Externalizable
Overrides:
readExternal in class PageableQuerySpec
Parameters:
input -
Throws:
IOException
ClassNotFoundException

readVersion

protected boolean readVersion(PagingSessionSpec thisObject,
                              ObjectInput input,
                              long readSerialVersionUID,
                              boolean passThrough,
                              boolean superDone)
                       throws IOException,
                              ClassNotFoundException
Reads the non-transient fields of this class from an external source.

Supported API: false

Parameters:
thisObject -
input -
readSerialVersionUID -
passThrough -
superDone -
Returns:
boolean
Throws:
IOException
ClassNotFoundException

readOldVersion

private boolean readOldVersion(ObjectInput input,
                               long readSerialVersionUID,
                               boolean passThrough,
                               boolean superDone)
                        throws IOException,
                               ClassNotFoundException
Reads the non-transient fields of this class from an external source, which is not the current version.

Parameters:
input -
readSerialVersionUID -
passThrough -
superDone -
Returns:
boolean
Throws:
IOException
ClassNotFoundException

getTotalSize

public int getTotalSize()
Gets the value of the attribute: totalSize; Specifies the total number of results that can be paged through.

Supported API: true

Returns:
int

getSessionId

public long getSessionId()
Gets the value of the attribute: sessionId; Identifies a persistent paging session.

Supported API: true

Returns:
long

isAllPersistable

public boolean isAllPersistable()
Gets the value of the attribute: allPersistable.

Supported API: false

Returns:
boolean

setAllPersistable

public void setAllPersistable(boolean a_AllPersistable)
                       throws WTPropertyVetoException
Sets the value of the attribute: allPersistable.

Supported API: false

Parameters:
a_AllPersistable -
Throws:
WTPropertyVetoException

getGroupFromIndex

public int getGroupFromIndex()
Gets the value of the attribute: groupFromIndex.

Supported API: false

Returns:
int

setGroupFromIndex

public void setGroupFromIndex(int a_GroupFromIndex)
                       throws WTPropertyVetoException
Sets the value of the attribute: groupFromIndex.

Supported API: false

Parameters:
a_GroupFromIndex -
Throws:
WTPropertyVetoException

bind

public boolean bind()

bindPagingParameter

private void bindPagingParameter(QuerySpec a_qs,
                                 int a_start,
                                 int a_end)