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

## org.apache.cayenne.access.trans
Class InsertTranslator

    java.lang.Object
      org.apache.cayenne.access.QueryTranslator
          org.apache.cayenne.access.trans.QueryAssembler
              org.apache.cayenne.access.trans.InsertTranslator

Deprecated. since 1.2 Object InsertQuery is not needed anymore. It shouldn't be used directly anyway, but in cases where one might want to have access to it, InsertBatchQuery is a reasonable substitute.

    public class InsertTranslator

extends QueryAssembler

Class implements default translation mechanism of org.apache.cayenne.query.InsertQuery objects to SQL INSERT statements. Note that in order for this query to execute successfully, ObjectId contained within InsertQuery must be fully initialized.

Author:
  Andrei Adamchik

Field Summary
`protected java.util.List` | `columnList` Deprecated.

Fields inherited from class org.apache.cayenne.access.trans.QueryAssembler
`attributes, values`

Fields inherited from class org.apache.cayenne.access.QueryTranslator
`adapter, connection, engine, entityResolver, query`

Constructor Summary
`InsertTranslator()` Deprecated.

Method Summary
`java.lang.String` | `aliasForTable(DbEntity dbEnt)` Deprecated. Returns a name that can be used as column alias.
`java.lang.String` | `createSqlString()` Deprecated. Method that converts an insert query into SQL string
`void` | `dbRelationshipAdded(DbRelationship dbRel)` Deprecated. Processes a join being added.
`InsertQuery` | `insertQuery()` Deprecated.
`protected void` | `prepareLists()` Deprecated. Creates 2 matching lists: columns names and values

Methods inherited from class org.apache.cayenne.access.trans.QueryAssembler
`addToParamList, aliasForTable, createStatement, initStatement, supportsTableAliases`

Methods inherited from class org.apache.cayenne.access.QueryTranslator
`createStatement, getAdapter, getCon, getConnection, getEngine, getEntityResolver, getQuery, getRootDbEntity, getRootEntity, getRootInheritanceTree, setAdapter, setCon, setConnection, setEngine, setEntityResolver, setQuery`

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

Field Detail

### columnList

    protected java.util.List columnList

  Deprecated.

Constructor Detail

### InsertTranslator

    public InsertTranslator()

  Deprecated.

Method Detail

### aliasForTable

    public java.lang.String aliasForTable(DbEntity dbEnt)

  Deprecated.
  Description copied from class: `QueryAssembler`
  Returns a name that can be used as column alias. This can be one of the following:
  - an alias for this table, if it uses aliases
  - a fully qualified table name, if not.
  CayenneRuntimeException is thrown if a table alias can not be created.

  Specified by:
    `aliasForTable` in class `QueryAssembler`

### dbRelationshipAdded

    public void dbRelationshipAdded(DbRelationship dbRel)

  Deprecated.
  Description copied from class: `QueryAssembler`
  Processes a join being added.

  Specified by:
    `dbRelationshipAdded` in class `QueryAssembler`

### createSqlString

    public java.lang.String createSqlString()
                                     throws java.lang.Exception

  Deprecated.
  Method that converts an insert query into SQL string

  Specified by:
    `createSqlString` in class `QueryAssembler`
  Throws:
    `java.lang.Exception`

### insertQuery

    public InsertQuery insertQuery()

  Deprecated.

### prepareLists

    protected void prepareLists()
                         throws java.lang.Exception

  Deprecated.
  Creates 2 matching lists: columns names and values

  Throws:
    `java.lang.Exception`

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

Copyright © 2001-2006 Apache.org All Rights Reserved.