com.j256.ormlite.stmt.mapped
Class MappedUpdateId<T,ID>

java.lang.Object
  extended by com.j256.ormlite.stmt.mapped.BaseMappedStatement<T,ID>
      extended by com.j256.ormlite.stmt.mapped.MappedUpdateId<T,ID>

public class MappedUpdateId<T,ID>
extends BaseMappedStatement<T,ID>

Mapped statement for updating an object's ID field.

Author:
graywatson

Field Summary
 
Fields inherited from class com.j256.ormlite.stmt.mapped.BaseMappedStatement
argFieldTypes, clazz, idField, logger, statement, tableInfo
 
Method Summary
static
<T,ID> MappedUpdateId<T,ID>
build(DatabaseType databaseType, TableInfo<T,ID> tableInfo)
           
 int execute(DatabaseConnection databaseConnection, T data, ID newId, ObjectCache objectCache)
          Update the id field of the object in the database.
 
Methods inherited from class com.j256.ormlite.stmt.mapped.BaseMappedStatement
convertIdToFieldObject, getFieldObjects, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

execute

public int execute(DatabaseConnection databaseConnection,
                   T data,
                   ID newId,
                   ObjectCache objectCache)
            throws SQLException
Update the id field of the object in the database.

Throws:
SQLException

build

public static <T,ID> MappedUpdateId<T,ID> build(DatabaseType databaseType,
                                                TableInfo<T,ID> tableInfo)
                                  throws SQLException
Throws:
SQLException


This content is licensed by Gray Watson under the Creative Commons Attribution-Share Alike 3.0 License.