Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.ejb.plugins.cmp.jdbc
Class JDBCIdentityColumnCreateCommand

    java.lang.Object
      org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand
          org.jboss.ejb.plugins.cmp.jdbc.JDBCIdentityColumnCreateCommand

All Implemented Interfaces:
  JDBCCreateCommand

Direct Known Subclasses:
  JDBC30GeneratedKeysCreateCommand, JDBCDB2IdentityValLocalCreateCommand, JDBCHsqldbCreateCommand, JDBCInformixCreateCommand, JDBCMySQLCreateCommand, JDBCOracleCreateCommand, JDBCPostgreSQLCreateCommand, JDBCSQLServerCreateCommand, JDBCSybaseCreateCommand

public abstract class JDBCIdentityColumnCreateCommand
extends JDBCAbstractCreateCommand

Base class for create commands where the PK value is generated as side effect of performing the insert operation. This is typically associated with database platforms that use identity columns

Author:
  Jeremy Boynes

Field Summary
`protected JDBCCMPFieldBridge` | `pkField`
`protected String` | `pkSQL`

Fields inherited from class org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand
`createAllowed, debug, entity, exceptionProcessor, insertAfterEjbPostCreate, insertFields, insertSQL, log, securityManager, trace`

Constructor Summary
`JDBCIdentityColumnCreateCommand()`

Method Summary
`protected int` | `executeInsert(int paramIndex, PreparedStatement ps, EntityEnterpriseContext ctx)`
`protected void` | `initGeneratedFields()`
`protected boolean` | `isInsertField(JDBCFieldBridge field)`
`protected SQLException` | `processException(Throwable t)` Helper for subclasses that use reflection to avoid driver dependencies.

Methods inherited from class org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand
`afterInsert, beforeInsert, checkCreateAllowed, execute, generateFields, getGeneratedPKField, getPrimaryKey, init, initEntityCommand, initInsertFields, initInsertSQL, performInsert, prepareStatement`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### pkField

    protected JDBCCMPFieldBridge pkField

### pkSQL

    protected String pkSQL

Constructor Detail

### JDBCIdentityColumnCreateCommand

    public JDBCIdentityColumnCreateCommand()

Method Detail

### isInsertField

    protected boolean isInsertField(JDBCFieldBridge field)

  Overrides:
    `isInsertField` in class `JDBCAbstractCreateCommand`

### initGeneratedFields

    protected void initGeneratedFields()
                                throws org.jboss.deployment.DeploymentException

  Overrides:
    `initGeneratedFields` in class `JDBCAbstractCreateCommand`
  Throws:
    `org.jboss.deployment.DeploymentException`

### executeInsert

    protected int executeInsert(int paramIndex,
                                PreparedStatement ps,
                                EntityEnterpriseContext ctx)
                         throws SQLException

  Overrides:
    `executeInsert` in class `JDBCAbstractCreateCommand`
  Throws:
    `SQLException`

### processException

    protected SQLException processException(Throwable t)

  Helper for subclasses that use reflection to avoid driver dependencies.

  Parameters:
    `t` - an Exception raised by a reflected call
  Returns:
    SQLException extracted from the Throwable

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

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