org.datanucleus.store.query
Class QueryResultsMetaData

java.lang.Object
  extended by org.datanucleus.store.query.QueryResultsMetaData
All Implemented Interfaces:
java.io.Serializable

public class QueryResultsMetaData
extends java.lang.Object
implements java.io.Serializable

Metadata for query results. Can be for JDOQL, JPQL, or some other language in principle.

See Also:
Serialized Form

Constructor Summary
QueryResultsMetaData(java.lang.Class[] types)
          Constructor.
 
Method Summary
 int getExpressionCount()
          The number of expressions in the result
 java.lang.Class getExpressionType(int exprIndex)
          Returns the Java class of the expression referenced by the given index that is returned by the associated query.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QueryResultsMetaData

public QueryResultsMetaData(java.lang.Class[] types)
Constructor.

Parameters:
types - type of all expressions in the result
Method Detail

getExpressionCount

public int getExpressionCount()
The number of expressions in the result

Returns:
The number of expressions returned by the associated query.

getExpressionType

public java.lang.Class getExpressionType(int exprIndex)
Returns the Java class of the expression referenced by the given index that is returned by the associated query.

Parameters:
exprIndex - The 0-based index of the expression the type should be returned for.
Returns:
The Java class of the expression with the given index.
Throws:
java.lang.IndexOutOfBoundsException - if the index is out of range


Copyright © 2009. All Rights Reserved.