org.jboss.ejb.plugins.cmp.jdbc2
Class DeclaredSQLQueryCommand
java.lang.Object
org.jboss.ejb.plugins.cmp.jdbc2.AbstractQueryCommand
org.jboss.ejb.plugins.cmp.jdbc2.DeclaredSQLQueryCommand
- All Implemented Interfaces:
- QueryCommand
public class DeclaredSQLQueryCommand
- extends AbstractQueryCommand
- Version:
- $Revision: 81030 $
- Author:
- Alexey Loubyansky
Methods inherited from class org.jboss.ejb.plugins.cmp.jdbc2.AbstractQueryCommand |
executeFetchOne, fetchCollection, fetchOne, getStoreManager, setEntityReader, setFieldReader, setFunctionReader, setLimitParam, setLimitValue, setOffsetParam, setOffsetValue, setParameters, setResultType, toInt |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DeclaredSQLQueryCommand
public DeclaredSQLQueryCommand(JDBCEntityBridge2 entity,
JDBCDeclaredQueryMetaData metadata)
throws DeploymentException
- Throws:
DeploymentException
parseParameters
protected String parseParameters(String sql,
JDBCDeclaredQueryMetaData metadata)
throws DeploymentException
- Replaces the parameters in the specific sql with question marks, and
initializes the parameter setting code. Parameters are encoded in curly
brackets use a zero based index.
- Parameters:
sql
- the sql statement that is parsed for parameters
- Returns:
- the original sql statement with the parameters replaced with a
question mark
- Throws:
DeploymentException
- if a error occures while parsing the sql
Copyright © 2009 JBoss, a division of Red Hat, Inc.. All Rights Reserved.