org.ow2.jonas.deployment.ejb
Class MethodCmp2Desc

java.lang.Object
  extended by org.ow2.jonas.deployment.ejb.MethodDesc
      extended by org.ow2.jonas.deployment.ejb.MethodCmp2Desc

public class MethodCmp2Desc
extends MethodDesc

Class to hold meta-information related to CMP2 find/select methods

Author:
Christophe Ney [cney@batisseurs.com] : Initial developer, Helene Joanin

Field Summary
protected  EntityDesc entityDesc
           
protected  String query
           
protected  ASTEJBQL queryNode
           
protected  boolean resultTypeMappingRemote
           
 
Fields inherited from class org.ow2.jonas.deployment.ejb.MethodDesc
APPLY_TO, APPLY_TO_BEAN, APPLY_TO_BEAN_METHOD, APPLY_TO_BEAN_METHOD_NAME, APPLY_TO_CLASS, APPLY_TO_CLASS_METHOD, APPLY_TO_CLASS_METHOD_NAME, APPLY_TO_NOTHING, beanDesc, TX_MANDATORY, TX_NEVER, TX_NOT_SET, TX_NOT_SUPPORTED, TX_NULL, TX_REQUIRED, TX_REQUIRES_NEW, TX_STR_DEFAULT_VALUE, TX_STR_DEFAULT_VALUE_4_MDB, TX_SUPPORTS
 
Method Summary
 boolean getPrefetch()
          Get the prefetch tag value for this method.
 String getQuery()
          get EJB-QL query when defined
 ASTEJBQL getQueryNode()
           
 boolean isResultTypeMappingRemote()
          get result type mapping state (remote/local)
static String queryMethodElementToString(QueryMethod m)
          String representation of the given element
 void setQuery(String query)
          set EJB-QL query.
 void setResultTypeMapping(String resultTypeMapping)
          set the state of resultTypeMappingRemote
 String toString()
          String representation of the object for test purpose
 
Methods inherited from class org.ow2.jonas.deployment.ejb.MethodDesc
getBeanDesc, getIndex, getMethod, getRoleName, getTxAttribute, getTxAttributeName, getTxAttributeName, getTxAttributeStatus, isEjbSelect, isEjbSelect, isExcluded, isFindByPrimaryKey, isFindByPrimaryKey, isFinder, isFinder, matchPattern, matchPattern, methodElementToString, methodElementToString, setExcluded, setIndex, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

query

protected String query

queryNode

protected ASTEJBQL queryNode

resultTypeMappingRemote

protected boolean resultTypeMappingRemote

entityDesc

protected EntityDesc entityDesc
Method Detail

getQuery

public String getQuery()
get EJB-QL query when defined

Returns:
possibly null String containing the EJB-QL query for the method

setQuery

public void setQuery(String query)
              throws ParseException
set EJB-QL query. Because of the deployment descriptor structure, the query is set after the object is created.

Throws:
ParseException

getQueryNode

public ASTEJBQL getQueryNode()

isResultTypeMappingRemote

public boolean isResultTypeMappingRemote()
get result type mapping state (remote/local)

Returns:
true when remote

setResultTypeMapping

public void setResultTypeMapping(String resultTypeMapping)
                          throws DeploymentDescException
set the state of resultTypeMappingRemote

Throws:
DeploymentDescException

getPrefetch

public boolean getPrefetch()
Get the prefetch tag value for this method. May be true only for finder methods (not for ejbSelect methods)


queryMethodElementToString

public static String queryMethodElementToString(QueryMethod m)
String representation of the given element

Parameters:
m - an element
Returns:
String representation of the given element method

toString

public String toString()
String representation of the object for test purpose

Overrides:
toString in class MethodDesc
Returns:
String representation of this object


Copyright © 2010 OW2 Consortium. All Rights Reserved.