Package net.ontopia.persistence.proxy
Class PrimitiveFieldInfo
- java.lang.Object
-
- net.ontopia.persistence.proxy.AbstractFieldInfo
-
- net.ontopia.persistence.proxy.PrimitiveFieldInfo
-
- All Implemented Interfaces:
FieldHandlerIF
,FieldInfoIF
public class PrimitiveFieldInfo extends AbstractFieldInfo
INTERNAL: A field that references a primitive value class.
-
-
Field Summary
Fields Modifier and Type Field Description protected String
colname
protected int
sqltype
-
Fields inherited from class net.ontopia.persistence.proxy.AbstractFieldInfo
cardinality, field, getter, index, is_collection, name, parent_cinfo, readonly, setter, value_class
-
Fields inherited from interface net.ontopia.persistence.proxy.FieldInfoIF
MANY_TO_MANY, ONE_TO_MANY, ONE_TO_ONE
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
bind(Object value, PreparedStatement stm, int stmt_index)
INTERNAL: Binds the object field value starting from the given offset in the prepared statement.int
getColumnCount()
INTERNAL: Returns the number of columns that the field spans.int
getSQLType()
ClassInfoIF
getValueClassInfo()
INTERNAL: Gets the class info for the field's value type.String[]
getValueColumns()
INTERNAL: Returns the names of the columns that the field spans.boolean
isIdentityField()
INTERNAL: Returns true if the field handler references an object identity field.Object
load(AccessRegistrarIF registrar, TicketIF ticket, ResultSet rs, int rsindex, boolean direct)
INTERNAL: Loads a single primitive value.void
retrieveFieldValues(Object value, List<Object> field_values)
void
retrieveSQLValues(Object value, List<SQLValueIF> sql_values)
String
toString()
-
Methods inherited from class net.ontopia.persistence.proxy.AbstractFieldInfo
getCardinality, getDescriptor, getGetterMethod, getIndex, getJoinKeys, getJoinTable, getManyKeys, getName, getParentClassInfo, getSetterMethod, getTable, getValue, getValueClass, isAggregateField, isCollectionField, isPrimitiveField, isReadOnly, isReferenceField, setValue
-
-
-
-
Field Detail
-
colname
protected String colname
-
sqltype
protected int sqltype
-
-
Method Detail
-
getSQLType
public int getSQLType()
-
getValueClassInfo
public ClassInfoIF getValueClassInfo()
Description copied from interface:FieldInfoIF
INTERNAL: Gets the class info for the field's value type. Note that primitive value classes don't have a class info.
-
getColumnCount
public int getColumnCount()
Description copied from interface:FieldHandlerIF
INTERNAL: Returns the number of columns that the field spans.
-
isIdentityField
public boolean isIdentityField()
Description copied from interface:FieldHandlerIF
INTERNAL: Returns true if the field handler references an object identity field.
-
getValueColumns
public String[] getValueColumns()
Description copied from interface:FieldInfoIF
INTERNAL: Returns the names of the columns that the field spans.
-
load
public Object load(AccessRegistrarIF registrar, TicketIF ticket, ResultSet rs, int rsindex, boolean direct) throws SQLException
INTERNAL: Loads a single primitive value.- Throws:
SQLException
-
bind
public void bind(Object value, PreparedStatement stm, int stmt_index) throws SQLException
Description copied from interface:FieldHandlerIF
INTERNAL: Binds the object field value starting from the given offset in the prepared statement. The number of columns actually bound depends on the type of object field.- Throws:
SQLException
-
retrieveSQLValues
public void retrieveSQLValues(Object value, List<SQLValueIF> sql_values)
-
-