public interface Row
UpdateManager is responsible for
implementing rows to do something useful when the values are set.| Modifier and Type | Field and Description |
|---|---|
static int |
ACTION_DELETE
Mark the row for deletion.
|
static int |
ACTION_INSERT
Mark the row for inserttion.
|
static int |
ACTION_UNKNOWN
Symbolic constant reserved for situations when a row operation
is unknown.
|
static int |
ACTION_UPDATE
Mark the row for update.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getAction()
Return the action for this row.
|
java.lang.Object |
getFailedObject()
Return the failed object to include in optimistic lock exceptions.
|
OpenJPAStateManager |
getPrimaryKey()
Return the instance that controls this row.
|
Table |
getTable()
Return the table for this row.
|
boolean |
isValid()
Whether this row has information set on it.
|
void |
setArray(Column col,
java.sql.Array val)
Set the value of the given column in this row.
|
void |
setAsciiStream(Column col,
java.io.InputStream val,
int length)
Set the value of the given column in this row.
|
void |
setBigDecimal(Column col,
java.math.BigDecimal val)
Set the value of the given column in this row.
|
void |
setBigInteger(Column col,
java.math.BigInteger val)
Set the value of the given column in this row.
|
void |
setBinaryStream(Column col,
java.io.InputStream val,
int length)
Set the value of the given column in this row.
|
void |
setBlob(Column col,
java.sql.Blob val)
Set the value of the given column in this row.
|
void |
setBoolean(Column col,
boolean val)
Set the value of the given column in this row.
|
void |
setByte(Column col,
byte val)
Set the value of the given column in this row.
|
void |
setBytes(Column col,
byte[] val)
Set the value of the given column in this row.
|
void |
setCalendar(Column col,
java.util.Calendar val)
Set the value of the given column in this row.
|
void |
setChar(Column col,
char val)
Set the value of the given column in this row.
|
void |
setCharacterStream(Column col,
java.io.Reader val,
int length)
Set the value of the given column in this row.
|
void |
setClob(Column col,
java.sql.Clob val)
Set the value of the given column in this row.
|
void |
setDate(Column col,
java.util.Date val)
Set the value of the given column in this row.
|
void |
setDate(Column col,
java.sql.Date val,
java.util.Calendar cal)
Set the value of the given column in this row.
|
void |
setDouble(Column col,
double val)
Set the value of the given column in this row.
|
void |
setFailedObject(java.lang.Object failed)
Set the failed object to include in the optimistic lock exception
that will be thrown if this update results in an update count of 0
when executed.
|
void |
setFloat(Column col,
float val)
Set the value of the given column in this row.
|
void |
setForeignKey(ForeignKey fk,
ColumnIO io,
OpenJPAStateManager sm)
Set the value of the given foreign key to the given object.
|
void |
setForeignKey(ForeignKey fk,
OpenJPAStateManager sm)
Set the value of the given foreign key to the given object.
|
void |
setInt(Column col,
int val)
Set the value of the given column in this row.
|
void |
setLocale(Column col,
java.util.Locale val)
Set the value of the given column in this row.
|
void |
setLong(Column col,
long val)
Set the value of the given column in this row.
|
void |
setNull(Column col)
Set the value of the given column in this row.
|
void |
setNull(Column col,
boolean overrideDefault)
Set the value of the given column in this row.
|
void |
setNumber(Column col,
java.lang.Number val)
Set the value of the given column in this row.
|
void |
setObject(Column col,
java.lang.Object val)
Set the value of the given column in this row.
|
void |
setPrimaryKey(ColumnIO io,
OpenJPAStateManager sm)
Set the primary key to represent the given object.
|
void |
setPrimaryKey(OpenJPAStateManager sm)
Set the primary key to represent the given object.
|
void |
setRaw(Column col,
java.lang.String value)
Set a DB understood value for the given column.
|
void |
setRelationId(Column col,
OpenJPAStateManager sm,
RelationId rel)
Set the value of the given column to the identity of given instance,
using the given callback to create the column value.
|
void |
setShort(Column col,
short val)
Set the value of the given column in this row.
|
void |
setString(Column col,
java.lang.String val)
Set the value of the given column in this row.
|
void |
setTime(Column col,
java.sql.Time val,
java.util.Calendar cal)
Set the value of the given column in this row.
|
void |
setTimestamp(Column col,
java.sql.Timestamp val,
java.util.Calendar cal)
Set the value of the given column in this row.
|
void |
setValid(boolean valid)
Whether this row has information set on it.
|
void |
whereArray(Column col,
java.sql.Array val)
Set an equality condition on the value of the given column in this row.
|
void |
whereAsciiStream(Column col,
java.io.InputStream val,
int length)
Set an equality condition on the value of the given column in this row.
|
void |
whereBigDecimal(Column col,
java.math.BigDecimal val)
Set an equality condition on the value of the given column in this row.
|
void |
whereBigInteger(Column col,
java.math.BigInteger val)
Set an equality condition on the value of the given column in this row.
|
void |
whereBinaryStream(Column col,
java.io.InputStream val,
int length)
Set an equality condition on the value of the given column in this row.
|
void |
whereBlob(Column col,
java.sql.Blob val)
Set an equality condition on the value of the given column in this row.
|
void |
whereBoolean(Column col,
boolean val)
Set an equality condition on the value of the given column in this row.
|
void |
whereByte(Column col,
byte val)
Set an equality condition on the value of the given column in this row.
|
void |
whereBytes(Column col,
byte[] val)
Set an equality condition on the value of the given column in this row.
|
void |
whereCalendar(Column col,
java.util.Calendar val)
Set an equality condition on the value of the given column in this row.
|
void |
whereChar(Column col,
char val)
Set an equality condition on the value of the given column in this row.
|
void |
whereCharacterStream(Column col,
java.io.Reader val,
int length)
Set an equality condition on the value of the given column in this row.
|
void |
whereClob(Column col,
java.sql.Clob val)
Set an equality condition on the value of the given column in this row.
|
void |
whereDate(Column col,
java.util.Date val)
Set an equality condition on the value of the given column in this row.
|
void |
whereDate(Column col,
java.sql.Date val,
java.util.Calendar cal)
Set an equality condition on the value of the given column in this row.
|
void |
whereDouble(Column col,
double val)
Set an equality condition on the value of the given column in this row.
|
void |
whereFloat(Column col,
float val)
Set an equality condition on the value of the given column in this row.
|
void |
whereForeignKey(ForeignKey fk,
OpenJPAStateManager sm)
Set the foreign key equality criteria to link to the given object.
|
void |
whereInt(Column col,
int val)
Set an equality condition on the value of the given column in this row.
|
void |
whereLocale(Column col,
java.util.Locale val)
Set an equality condition on the value of the given column in this row.
|
void |
whereLong(Column col,
long val)
Set an equality condition on the value of the given column in this row.
|
void |
whereNull(Column col)
Set an equality condition on the value of the given column in this row.
|
void |
whereNumber(Column col,
java.lang.Number val)
Set an equality condition on the value of the given column in this row.
|
void |
whereObject(Column col,
java.lang.Object val)
Set an equality condition on the value of the given column in this row.
|
void |
wherePrimaryKey(OpenJPAStateManager sm)
Set the primary key equality criteria for this row.
|
void |
whereRaw(Column col,
java.lang.String value)
Set a DB understood where condition for the given column.
|
void |
whereShort(Column col,
short val)
Set an equality condition on the value of the given column in this row.
|
void |
whereString(Column col,
java.lang.String val)
Set an equality condition on the value of the given column in this row.
|
void |
whereTime(Column col,
java.sql.Time val,
java.util.Calendar cal)
Set an equality condition on the value of the given column in this row.
|
void |
whereTimestamp(Column col,
java.sql.Timestamp val,
java.util.Calendar cal)
Set an equality condition on the value of the given column in this row.
|
static final int ACTION_UNKNOWN
static final int ACTION_UPDATE
static final int ACTION_INSERT
static final int ACTION_DELETE
Table getTable()
int getAction()
java.lang.Object getFailedObject()
void setFailedObject(java.lang.Object failed)
boolean isValid()
void setValid(boolean valid)
OpenJPAStateManager getPrimaryKey()
setPrimaryKey(org.apache.openjpa.kernel.OpenJPAStateManager) method does not necessarily have to be called
to know the owning instance, nor does this row's table have to have
an actual primary key.void setPrimaryKey(OpenJPAStateManager sm) throws java.sql.SQLException
java.sql.SQLExceptionvoid setPrimaryKey(ColumnIO io, OpenJPAStateManager sm) throws java.sql.SQLException
io - information on which columns are settable; may be nulljava.sql.SQLExceptionvoid wherePrimaryKey(OpenJPAStateManager sm) throws java.sql.SQLException
java.sql.SQLExceptionvoid setForeignKey(ForeignKey fk, OpenJPAStateManager sm) throws java.sql.SQLException
java.sql.SQLExceptionvoid setForeignKey(ForeignKey fk, ColumnIO io, OpenJPAStateManager sm) throws java.sql.SQLException
io - information on which columns are settable; may be nulljava.sql.SQLExceptionvoid whereForeignKey(ForeignKey fk, OpenJPAStateManager sm) throws java.sql.SQLException
java.sql.SQLExceptionvoid setArray(Column col, java.sql.Array val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setAsciiStream(Column col, java.io.InputStream val, int length) throws java.sql.SQLException
java.sql.SQLExceptionvoid setBigDecimal(Column col, java.math.BigDecimal val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setBigInteger(Column col, java.math.BigInteger val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setBinaryStream(Column col, java.io.InputStream val, int length) throws java.sql.SQLException
java.sql.SQLExceptionvoid setBlob(Column col, java.sql.Blob val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setBoolean(Column col, boolean val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setByte(Column col, byte val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setBytes(Column col, byte[] val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setCalendar(Column col, java.util.Calendar val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setChar(Column col, char val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setCharacterStream(Column col, java.io.Reader val, int length) throws java.sql.SQLException
java.sql.SQLExceptionvoid setClob(Column col, java.sql.Clob val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setDate(Column col, java.util.Date val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setDate(Column col, java.sql.Date val, java.util.Calendar cal) throws java.sql.SQLException
java.sql.SQLExceptionvoid setDouble(Column col, double val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setFloat(Column col, float val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setInt(Column col, int val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setLong(Column col, long val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setLocale(Column col, java.util.Locale val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setNull(Column col) throws java.sql.SQLException
java.sql.SQLExceptionvoid setNull(Column col, boolean overrideDefault) throws java.sql.SQLException
overrideDefault - whether to set this column to null even if this
is an insert and the column has a defaultjava.sql.SQLExceptionvoid setNumber(Column col, java.lang.Number val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setObject(Column col, java.lang.Object val) throws java.sql.SQLException
col - the column being setval - the value for the columnjava.sql.SQLExceptionvoid setRaw(Column col, java.lang.String value) throws java.sql.SQLException
java.sql.SQLExceptionvoid setRelationId(Column col, OpenJPAStateManager sm, RelationId rel) throws java.sql.SQLException
java.sql.SQLExceptionvoid setShort(Column col, short val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setString(Column col, java.lang.String val) throws java.sql.SQLException
java.sql.SQLExceptionvoid setTime(Column col, java.sql.Time val, java.util.Calendar cal) throws java.sql.SQLException
java.sql.SQLExceptionvoid setTimestamp(Column col, java.sql.Timestamp val, java.util.Calendar cal) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereArray(Column col, java.sql.Array val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereAsciiStream(Column col, java.io.InputStream val, int length) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereBigDecimal(Column col, java.math.BigDecimal val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereBigInteger(Column col, java.math.BigInteger val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereBinaryStream(Column col, java.io.InputStream val, int length) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereBlob(Column col, java.sql.Blob val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereBoolean(Column col, boolean val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereByte(Column col, byte val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereBytes(Column col, byte[] val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereCalendar(Column col, java.util.Calendar val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereChar(Column col, char val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereCharacterStream(Column col, java.io.Reader val, int length) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereClob(Column col, java.sql.Clob val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereDate(Column col, java.util.Date val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereDate(Column col, java.sql.Date val, java.util.Calendar cal) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereDouble(Column col, double val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereFloat(Column col, float val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereInt(Column col, int val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereLong(Column col, long val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereLocale(Column col, java.util.Locale val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereNull(Column col) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereNumber(Column col, java.lang.Number val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereObject(Column col, java.lang.Object val) throws java.sql.SQLException
col - the column being setval - the value for the columnjava.sql.SQLExceptionvoid whereRaw(Column col, java.lang.String value) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereShort(Column col, short val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereString(Column col, java.lang.String val) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereTime(Column col, java.sql.Time val, java.util.Calendar cal) throws java.sql.SQLException
java.sql.SQLExceptionvoid whereTimestamp(Column col, java.sql.Timestamp val, java.util.Calendar cal) throws java.sql.SQLException
java.sql.SQLExceptionCopyright © 2006-2013 Apache Software Foundation. All Rights Reserved.