|
SolarMetric Kodo JDO 3.0.3 generated on February 20 2004 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--kodo.meta.DelegatingExtensions
|
+--kodo.meta.DelegatingClassMetaData
|
+--kodo.jdbc.meta.ClassMapping
|
+--kodo.jdbc.meta.VerticalClassMapping
Mapping for classes that use a separate primary table than their parent class.
| Field Summary | |
static String |
TYPE
|
| Fields inherited from class kodo.jdbc.meta.ClassMapping |
AUTO_INCREMENT, CLASS_IND, CLASS_INDEXED, CLASS_MAP, REF_DELETE_ACTION, SEQUENCE_FACTORY, VERSION_IND, VERSION_INDEXED |
| Fields inherited from interface kodo.meta.ClassMetaData |
DATA_CACHE, DATA_CACHE_TIMEOUT, DETACH_OID_FIELD, DETACH_STATE_FIELD, DETACHABLE, ID_APPLICATION, ID_DATASTORE, ID_NONDURABLE, VALIDATE_ALL, VALIDATE_NONE, VALIDATE_NORESOLVE, VALIDATE_RUNTIME, VALIDATE_UNENHANCED |
| Constructor Summary | |
VerticalClassMapping(ClassMetaData meta)
Constructor. |
|
| Method Summary | |
void |
delete(KodoStateManager sm,
RowManager rm)
Set the where values appropriately to delete the proper instance, and set all relations on non-secondary tables as updates. |
void |
fromMappingInfo(MappingInfo info,
boolean adapt)
Deserialize this mapping from a simple MappingInfo
instance parsed from XML or some other format. |
ClassIndicator |
getClassIndicator()
Return the class indicator for this class. |
JoinableMapping |
getJoinableMapping(Column col)
Return the joinable mapping for the given column. |
String |
getMappingType()
Return the abbreviated name of this mapping, or the full class name if it is a custom mapping. |
Column[] |
getPrimaryKeyColumns()
Return the columns this mapping uses to uniquely identify an object. |
ForeignKey |
getRefForeignKey()
Return the foreign key linking this mapping to the parent table. |
Table |
getTable()
Return the mapping's primary data table. |
VersionIndicator |
getVersionIndicator()
Return the version indicator for this class. |
void |
insert(KodoStateManager sm,
RowManager rm)
Set values for the mapping into the proper rows. |
boolean |
isPrimaryKeyObjectId(boolean hasAll)
Return true if the this class' primary key columns correspond to the base class' primary key columns used to construct oid values. |
void |
joinSuperclass(Joins joins)
Join the mapping to its superclass table. |
boolean |
map()
Map a new instance of this mapping type. |
void |
refSchemaComponents()
Increment the reference count of all used schema components. |
void |
resolve()
For implementation use. |
void |
reverseMap(SchemaGroup schema,
ReverseMappingTool tool)
Create mappings from the schema, using the given tool. |
void |
setClassIndicator(ClassIndicator cls)
Set the class indicator for this class. |
void |
setRefForeignKey(ForeignKey fk)
Set the foreign key linking this mapping to the parent table. |
void |
setVersionIndicator(VersionIndicator version)
Set the version indicator for this class. |
void |
toMappingInfo(MappingInfo info)
Serialize this mapping to a simple MappingInfo instance
for transfer to XML or some other format. |
void |
update(KodoStateManager sm,
RowManager rm)
Set values for the mapping into the proper rows. |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final String TYPE
| Constructor Detail |
public VerticalClassMapping(ClassMetaData meta)
| Method Detail |
public ForeignKey getRefForeignKey()
public void setRefForeignKey(ForeignKey fk)
public VersionIndicator getVersionIndicator()
ClassMappinggetVersionIndicator in class ClassMappingpublic void setVersionIndicator(VersionIndicator version)
ClassMappingsetVersionIndicator in class ClassMappingpublic ClassIndicator getClassIndicator()
ClassMappinggetClassIndicator in class ClassMappingpublic void setClassIndicator(ClassIndicator cls)
ClassMappingsetClassIndicator in class ClassMappingpublic JoinableMapping getJoinableMapping(Column col)
ClassMappinggetJoinableMapping in class ClassMappingpublic Table getTable()
Mappingpublic Column[] getPrimaryKeyColumns()
ClassMappinggetPrimaryKeyColumns in class ClassMappingpublic boolean isPrimaryKeyObjectId(boolean hasAll)
ClassMappingisPrimaryKeyObjectId in class ClassMappingkodo.jdbc.meta.ClassMappinghasAll - if true, there must be a primary key column for every
base class primary key column; if false the primary key
must only match a subset of the base class primary key
columnspublic String getMappingType()
Mappingpublic void toMappingInfo(MappingInfo info)
MappingMappingInfo instance
for transfer to XML or some other format.
public void fromMappingInfo(MappingInfo info,
boolean adapt)
MappingMappingInfo
instance parsed from XML or some other format. If the info is
incompatible and adapt is true, try to adapt to the new
info. This method must validate
the given mapping information using the SchemaGroup.findTable(kodo.jdbc.schema.Table)
method to find any needed tables, the Table.getColumn(java.lang.String) method
to retrieve columns from those tables, and the
Column.isCompatible(int, int) method to check all column types.
This validation is important, as some schema groups use these methods
to build themselves up dynamically rather than reading schema
information from the database.kodo.jdbc.meta.MappingMappingInfoNotFoundException - if the given info is invalidpublic boolean map()
Mapping
public void reverseMap(SchemaGroup schema,
ReverseMappingTool tool)
MappingreverseMap in class ClassMappingpublic void refSchemaComponents()
Mappingpublic void joinSuperclass(Joins joins)
ClassMappingjoinSuperclass in class ClassMapping
public void insert(KodoStateManager sm,
RowManager rm)
throws SQLException
Mapping
public void update(KodoStateManager sm,
RowManager rm)
throws SQLException
Mappingkodo.jdbc.meta.MappingMapping.insert(kodo.runtime.KodoStateManager, kodo.jdbc.sql.RowManager)
public void delete(KodoStateManager sm,
RowManager rm)
throws SQLException
Mappingkodo.jdbc.meta.MappingMapping.insert(kodo.runtime.KodoStateManager, kodo.jdbc.sql.RowManager)public void resolve()
ClassMetaDataresolve in class ClassMapping
|
SolarMetric Kodo JDO 3.0.3 generated on February 20 2004 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||