Overview | Package | Class | Tree | Serialized | Deprecated | Index | Help
| SolarMetric Kodo JDO 2.4.3 generated on March 27 2003
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.solarmetric.kodo.impl.jdbc.ormapping
Class FieldMapping

    java.lang.Object
      |
      +--com.solarmetric.kodo.impl.jdbc.ormapping.Mapping
            |
            +--com.solarmetric.kodo.impl.jdbc.ormapping.FieldMapping

Direct Known Subclasses:
  AbstractCollectionMapping, AbstractMapMapping, LobMapping, OneToOneMapping, ValueMapping

public abstract class FieldMapping
extends Mapping

A mapping between a field of a java class and its relational database representation.

Field Summary
`static String` | `COL_INDEX` Metadata extension key used to mark fields for indexing.
`static String` | `COL_LENGTH` Metadata extension key used to specify the maximum length of a field.
`static String` | `DATA_COL` Metadata extension key used to mark the name of the data column for this field.

Fields inherited from class com.solarmetric.kodo.impl.jdbc.ormapping.Mapping
`CUSTOM_MAPPING, dict, MAPPING, TABLE`

Constructor Summary
`FieldMapping()`

Method Summary
`void` | `compareToNull(ObjectSelect sel, boolean isNull)` Compare this column to null.
`Column[]` | `getDataColumns()` Return the primary data column(s) for this mapping.
`static FieldMapping` | `getInstance(FieldMetaData fmd)` Return the FieldMapping for the given FieldMetaData, creating it if necessary.
`static FieldMapping` | `getInstance(FieldMetaData fmd, boolean required)`
`FieldMetaData` | `getMetaData()` Return the metadata for the primary data column.
`void` | `join(ObjectSelect select)` Join this mapping to the given select statement.
`void` | `setDataColumns(Column[] data)` Set the primary data column(s) for this mapping.

Methods inherited from class com.solarmetric.kodo.impl.jdbc.ormapping.Mapping
`createMappings, createMappings, getConfiguration, getDictionary, getInstance, getTable`

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

Field Detail

### DATA_COL

    public static final String DATA_COL

  Metadata extension key used to mark the name of the data column for this field.

### COL_INDEX

    public static final String COL_INDEX

  Metadata extension key used to mark fields for indexing.

### COL_LENGTH

    public static final String COL_LENGTH

  Metadata extension key used to specify the maximum length of a field.

Constructor Detail

### FieldMapping

    public FieldMapping()

Method Detail

### getInstance

    public static FieldMapping getInstance(FieldMetaData fmd)

  Return the FieldMapping for the given FieldMetaData, creating it if necessary.

### getInstance

    public static FieldMapping getInstance(FieldMetaData fmd,
                                           boolean required)

### getDataColumns

    public Column[] getDataColumns()

  Return the primary data column(s) for this mapping. This will be the primary key column(s) for object mappings.

### setDataColumns

    public void setDataColumns(Column[] data)

  Set the primary data column(s) for this mapping. For primary table mappings, these columns should reside in the same table as the PK columns of this class. For mappings to other object types, these columns should hold the PK values for the related object.

### getMetaData

    public FieldMetaData getMetaData()

  Return the metadata for the primary data column.

### join

    public void join(ObjectSelect select)

  Join this mapping to the given select statement. For basic mappings, this no-op method implementation will suffice. Secondary table mappings should override this method to do the proper join.

### compareToNull

    public void compareToNull(ObjectSelect sel,
                              boolean isNull)

  Compare this column to null. For basic primary table mappings, the default definition of this method will suffice. More complex mappings should override this method.

Overview | Package | Class | Tree | Serialized | Deprecated | Index | Help
| SolarMetric Kodo JDO 2.4.3 generated on March 27 2003
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright 2001,2002 SolarMetric, Inc. All Rights Reserved.