站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBoss 3.2.7 server API Documentation 英文版文档

JDBCCreateEntityCommand (JBoss Server API) - JBoss 3.2.7 server API Documentation 英文版文档


org.jboss.ejb.plugins.jaws.jdbc
Class JDBCCreateEntityCommand

java.lang.Object
  extended byorg.jboss.ejb.plugins.jaws.jdbc.JDBCCommand
      extended byorg.jboss.ejb.plugins.jaws.jdbc.JDBCUpdateCommand
          extended byorg.jboss.ejb.plugins.jaws.jdbc.JDBCCreateEntityCommand
All Implemented Interfaces:
JPMCreateEntityCommand

public class JDBCCreateEntityCommand
extends JDBCUpdateCommand
implements JPMCreateEntityCommand

JAWSPersistenceManager JDBCCreateEntityCommand

Version:
$Revision: 1.12.2.1 $

Revisions:

20010812 vincent.harcq@hubmethods.com:

  • Get Rid of debug flag, use log4j instead
Author:
Rickard 脰berg, Marc Fleury, Joe Shevland, Justin Forder
See Also:

Field Summary
 
Fields inherited from class org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand
factory, jawsEntity, name
 
Constructor Summary
JDBCCreateEntityCommand(JDBCCommandFactory factory)
           
 
Method Summary
 Object execute(Method m, Object[] args, EntityEnterpriseContext ctx)
           
protected  Object handleResult(int rowsAffected, Object argOrArgs)
          Handle the result of successful execution of the update.
protected  void setParameters(PreparedStatement stmt, Object argOrArgs)
          Default implementation does nothing.
 
Methods inherited from class org.jboss.ejb.plugins.jaws.jdbc.JDBCUpdateCommand
executeStatementAndHandleResult
 
Methods inherited from class org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand
getCMPFieldValue, getConnection, getJawsCMPFieldJDBCType, getJDBCType, getJDBCTypeName, getName, getPkColumnList, getPkColumnWhereList, getPkFieldValue, getResultObject, getResultObject, getSQL, getState, isBinaryType, jdbcExecute, setCMPFieldValue, setParameter, setPrimaryKeyParameters, setSQL
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JDBCCreateEntityCommand

public JDBCCreateEntityCommand(JDBCCommandFactory factory)
Method Detail

execute

public Object execute(Method m,
                      Object[] args,
                      EntityEnterpriseContext ctx)
               throws javax.ejb.CreateException
Specified by:
execute in interface JPMCreateEntityCommand
Throws:
javax.ejb.CreateException

setParameters

protected void setParameters(PreparedStatement stmt,
                             Object argOrArgs)
                      throws Exception
Description copied from class: JDBCCommand
Default implementation does nothing. Override if parameters need to be set.

Overrides:
setParameters in class JDBCCommand
Parameters:
stmt - the PreparedStatement which will be executed by this Command.
argOrArgs - argument or array of arguments passed in from subclass execute method.
Throws:
Exception - if parameter setting fails.

handleResult

protected Object handleResult(int rowsAffected,
                              Object argOrArgs)
                       throws Exception
Description copied from class: JDBCUpdateCommand
Handle the result of successful execution of the update.

Specified by:
handleResult in class JDBCUpdateCommand
Parameters:
argOrArgs - argument or array of arguments passed in from subclass execute method.
Returns:
any result needed by the subclass execute.
Throws:
Exception - if result handling fails.


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.