Overview | Package | Class | Tree | Deprecated | Index | Help
| Kodo 4.1.0 generated on October 9 2006
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## kodo.jdbc.meta.strats
Class ColumnPerLockGroupVersionStrategy

    java.lang.Object
      org.apache.openjpa.jdbc.meta.strats.AbstractStrategy
          org.apache.openjpa.jdbc.meta.strats.AbstractVersionStrategy
              kodo.jdbc.meta.strats.ColumnPerLockGroupVersionStrategy

All Implemented Interfaces:
  org.apache.openjpa.jdbc.meta.Strategy, org.apache.openjpa.jdbc.meta.VersionStrategy

Direct Known Subclasses:
  LockGroupNumberVersionStrategy, LockGroupTimestampVersionStrategy

    public abstract class ColumnPerLockGroupVersionStrategy

extends org.apache.openjpa.jdbc.meta.strats.AbstractVersionStrategy

Uses a column and corresponding version object for each lock group.

Field Summary

Fields inherited from class org.apache.openjpa.jdbc.meta.strats.AbstractVersionStrategy
`vers`

Constructor Summary
`ColumnPerLockGroupVersionStrategy()`

Method Summary
`boolean` | `checkVersion(org.apache.openjpa.kernel.OpenJPAStateManager sm, org.apache.openjpa.jdbc.kernel.JDBCStore store, boolean updateVersion)`
`protected int` | `compare(Object v1, Object v2)` Compare the two versions.
`int` | `compareVersion(Object v1, Object v2)`
`void` | `delete(org.apache.openjpa.kernel.OpenJPAStateManager sm, org.apache.openjpa.jdbc.kernel.JDBCStore store, org.apache.openjpa.jdbc.sql.RowManager rm)`
`protected abstract int` | `getJavaType()` Return the code from `JavaTypes` for the version values this strategy uses.
`void` | `insert(org.apache.openjpa.kernel.OpenJPAStateManager sm, org.apache.openjpa.jdbc.kernel.JDBCStore store, org.apache.openjpa.jdbc.sql.RowManager rm)`
`void` | `load(org.apache.openjpa.kernel.OpenJPAStateManager sm, org.apache.openjpa.jdbc.kernel.JDBCStore store, org.apache.openjpa.jdbc.sql.Result res)`
`void` | `map(boolean adapt)`
`protected abstract Object` | `nextVersion(Object version)` Return the next version given the current one, which may be null.
`boolean` | `select(org.apache.openjpa.jdbc.sql.Select sel, org.apache.openjpa.jdbc.meta.ClassMapping mapping)`
`void` | `update(org.apache.openjpa.kernel.OpenJPAStateManager sm, org.apache.openjpa.jdbc.kernel.JDBCStore store, org.apache.openjpa.jdbc.sql.RowManager rm)`

Methods inherited from class org.apache.openjpa.jdbc.meta.strats.AbstractVersionStrategy
`afterLoad, setVersion`

Methods inherited from class org.apache.openjpa.jdbc.meta.strats.AbstractStrategy
`customDelete, customInsert, customUpdate, getAlias, initialize, isCustomDelete, isCustomInsert, isCustomUpdate`

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

Methods inherited from interface org.apache.openjpa.jdbc.meta.Strategy
`customDelete, customInsert, customUpdate, getAlias, initialize, isCustomDelete, isCustomInsert, isCustomUpdate`

Constructor Detail

### ColumnPerLockGroupVersionStrategy

    public ColumnPerLockGroupVersionStrategy()

Method Detail

### getJavaType

    protected abstract int getJavaType()

  Return the code from `JavaTypes` for the version values this strategy uses. This method is only used during mapping installation.

### nextVersion

    protected abstract Object nextVersion(Object version)

  Return the next version given the current one, which may be null.

### compare

    protected int compare(Object v1,
                          Object v2)

  Compare the two versions. Defaults to assuming the version objects implement `Comparable`.

  See Also:
    `Comparator.compare(T, T)`

### map

    public void map(boolean adapt)

  Specified by:
    `map` in interface `org.apache.openjpa.jdbc.meta.Strategy`
  Overrides:
    `map` in class `org.apache.openjpa.jdbc.meta.strats.AbstractStrategy`

### insert

    public void insert(org.apache.openjpa.kernel.OpenJPAStateManager sm,
                       org.apache.openjpa.jdbc.kernel.JDBCStore store,
                       org.apache.openjpa.jdbc.sql.RowManager rm)
                throws SQLException

  Specified by:
    `insert` in interface `org.apache.openjpa.jdbc.meta.Strategy`
  Overrides:
    `insert` in class `org.apache.openjpa.jdbc.meta.strats.AbstractStrategy`
  Throws:
    `SQLException`

### update

    public void update(org.apache.openjpa.kernel.OpenJPAStateManager sm,
                       org.apache.openjpa.jdbc.kernel.JDBCStore store,
                       org.apache.openjpa.jdbc.sql.RowManager rm)
                throws SQLException

  Specified by:
    `update` in interface `org.apache.openjpa.jdbc.meta.Strategy`
  Overrides:
    `update` in class `org.apache.openjpa.jdbc.meta.strats.AbstractStrategy`
  Throws:
    `SQLException`

### delete

    public void delete(org.apache.openjpa.kernel.OpenJPAStateManager sm,
                       org.apache.openjpa.jdbc.kernel.JDBCStore store,
                       org.apache.openjpa.jdbc.sql.RowManager rm)
                throws SQLException

  Specified by:
    `delete` in interface `org.apache.openjpa.jdbc.meta.Strategy`
  Overrides:
    `delete` in class `org.apache.openjpa.jdbc.meta.strats.AbstractStrategy`
  Throws:
    `SQLException`

### select

    public boolean select(org.apache.openjpa.jdbc.sql.Select sel,
                          org.apache.openjpa.jdbc.meta.ClassMapping mapping)

  Specified by:
    `select` in interface `org.apache.openjpa.jdbc.meta.VersionStrategy`
  Overrides:
    `select` in class `org.apache.openjpa.jdbc.meta.strats.AbstractVersionStrategy`

### load

    public void load(org.apache.openjpa.kernel.OpenJPAStateManager sm,
                     org.apache.openjpa.jdbc.kernel.JDBCStore store,
                     org.apache.openjpa.jdbc.sql.Result res)
              throws SQLException

  Specified by:
    `load` in interface `org.apache.openjpa.jdbc.meta.VersionStrategy`
  Overrides:
    `load` in class `org.apache.openjpa.jdbc.meta.strats.AbstractVersionStrategy`
  Throws:
    `SQLException`

### checkVersion

    public boolean checkVersion(org.apache.openjpa.kernel.OpenJPAStateManager sm,
                                org.apache.openjpa.jdbc.kernel.JDBCStore store,
                                boolean updateVersion)
                         throws SQLException

  Specified by:
    `checkVersion` in interface `org.apache.openjpa.jdbc.meta.VersionStrategy`
  Overrides:
    `checkVersion` in class `org.apache.openjpa.jdbc.meta.strats.AbstractVersionStrategy`
  Throws:
    `SQLException`

### compareVersion

    public int compareVersion(Object v1,
                              Object v2)

  Specified by:
    `compareVersion` in interface `org.apache.openjpa.jdbc.meta.VersionStrategy`
  Overrides:
    `compareVersion` in class `org.apache.openjpa.jdbc.meta.strats.AbstractVersionStrategy`

Overview | Package | Class | Tree | Deprecated | Index | Help
| Kodo 4.1.0 generated on October 9 2006
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright 2001-2006 BEA Systems, Inc. All Rights Reserved.