org.jboss.ejb.plugins.cmp.jdbc.metadata
Class JDBCQlQueryMetaData

java.lang.Object
  extended byorg.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCQlQueryMetaData
All Implemented Interfaces:
JDBCQueryMetaData (src)

public final class JDBCQlQueryMetaData
extends java.lang.Object
implements JDBCQueryMetaData (src)

Immutable class which contains information about an EJB QL query.


Constructor Summary
JDBCQlQueryMetaData(JDBCQlQueryMetaData (src)  defaults, JDBCReadAheadMetaData (src)  readAhead, java.lang.Class compiler, boolean lazyResultSetLoading)
          Constructs a JDBCQlQueryMetaData with data from the jdbcQueryMetaData and additional data from the xml element
JDBCQlQueryMetaData(JDBCQlQueryMetaData (src)  jdbcQueryMetaData, java.lang.reflect.Method method, JDBCReadAheadMetaData (src)  readAhead)
          Constructs a JDBCQlQueryMetaData with data from the jdbcQueryMetaData and additional data from the xml element
JDBCQlQueryMetaData(QueryMetaData (src)  queryMetaData, java.lang.reflect.Method method, java.lang.Class qlCompiler, boolean lazyResultSetLoading)
          Constructs a JDBCQlQueryMetaData which is defined by the queryMetaData and is invoked by the specified method.
 
Method Summary
 boolean equals(java.lang.Object o)
          Compares this JDBCQlQueryMetaData against the specified object.
 java.lang.String getEjbQl()
          Gets the EJB QL query which will be invoked.
 java.lang.reflect.Method getMethod()
          Gets the method which invokes this query.
 java.lang.Class getQLCompilerClass()
           
 JDBCReadAheadMetaData (src) getReadAhead()
          Gets the read ahead metadata for the query.
 int hashCode()
          Returns a hashcode for this JDBCQlQueryMetaData.
 boolean isLazyResultSetLoading()
           
 boolean isResultTypeMappingLocal()
          Is the result set of ejbSelect is mapped to local ejb objects or remote ejb objects.
 java.lang.String toString()
          Returns a string describing this JDBCQlQueryMetaData.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

JDBCQlQueryMetaData

public JDBCQlQueryMetaData(QueryMetaData (src)  queryMetaData,
                           java.lang.reflect.Method method,
                           java.lang.Class qlCompiler,
                           boolean lazyResultSetLoading)
Constructs a JDBCQlQueryMetaData which is defined by the queryMetaData and is invoked by the specified method.

Parameters:
queryMetaData - the metadata about this query which was loaded from the ejb-jar.xml file
method - the method which invokes this query

JDBCQlQueryMetaData

public JDBCQlQueryMetaData(JDBCQlQueryMetaData (src)  defaults,
                           JDBCReadAheadMetaData (src)  readAhead,
                           java.lang.Class compiler,
                           boolean lazyResultSetLoading)
Constructs a JDBCQlQueryMetaData with data from the jdbcQueryMetaData and additional data from the xml element


JDBCQlQueryMetaData

public JDBCQlQueryMetaData(JDBCQlQueryMetaData (src)  jdbcQueryMetaData,
                           java.lang.reflect.Method method,
                           JDBCReadAheadMetaData (src)  readAhead)
Constructs a JDBCQlQueryMetaData with data from the jdbcQueryMetaData and additional data from the xml element

Method Detail

getMethod

public java.lang.reflect.Method getMethod()
Description copied from interface: JDBCQueryMetaData (src)
Gets the method which invokes this query.

Specified by:
getMethod in interface JDBCQueryMetaData (src)
Returns:
the Method object which invokes this query

getQLCompilerClass

public java.lang.Class getQLCompilerClass()
Specified by:
getQLCompilerClass in interface JDBCQueryMetaData (src)
Returns:
EJBQL compiler implementation

getEjbQl

public java.lang.String getEjbQl()
Gets the EJB QL query which will be invoked.

Returns:
the ejb ql String for this query

isResultTypeMappingLocal

public boolean isResultTypeMappingLocal()
Description copied from interface: JDBCQueryMetaData (src)
Is the result set of ejbSelect is mapped to local ejb objects or remote ejb objects.

Specified by:
isResultTypeMappingLocal in interface JDBCQueryMetaData (src)
Returns:
true, if the result set is to be local objects

getReadAhead

public JDBCReadAheadMetaData (src)  getReadAhead()
Gets the read ahead metadata for the query.

Specified by:
getReadAhead in interface JDBCQueryMetaData (src)
Returns:
the read ahead metadata for the query.

isLazyResultSetLoading

public boolean isLazyResultSetLoading()
Specified by:
isLazyResultSetLoading in interface JDBCQueryMetaData (src)

equals

public boolean equals(java.lang.Object o)
Compares this JDBCQlQueryMetaData against the specified object. Returns true if the objects are the same. Two JDBCQlQueryMetaData are the same if they are both invoked by the same method.

Parameters:
o - the reference object with which to compare
Returns:
true if this object is the same as the object argument; false otherwise

hashCode

public int hashCode()
Returns a hashcode for this JDBCQlQueryMetaData. The hashcode is computed by the method which invokes this query.

Returns:
a hash code value for this object

toString

public java.lang.String toString()
Returns a string describing this JDBCQlQueryMetaData. The exact details of the representation are unspecified and subject to change, but the following may be regarded as typical:

"[JDBCQlQueryMetaData: method=public org.foo.User findByName(java.lang.String)]"

Returns:
a string representation of the object