Overview | Package | Class | Tree | Deprecated | Index | Help
| SolarMetric Kodo JDO 3.3.5 generated on August 31 2005
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## kodo.util
Class Id

    java.lang.Object
      |
      +--kodo.util.Id

All Implemented Interfaces:
  Serializable

public class Id
extends Object
implements Serializable

Datastore identity type. Implementations may choose to use this type, or choose to use their own datastore identity values. The API for this class is aligned with JDO's single field identity; access to the internal state of `Id` objects through public fields is deprecated.

See Also:
  Serialized Form

Field Summary
`long` | `id` Deprecated. Use `getKey()`.
`Class` | `type` Deprecated. Use `getTargetClass()`.

Constructor Summary
`Id()` Deprecated.
`Id(Class cls, long key)` Construct from key value.
`Id(Class cls, Long key)` Construct from key value.
`Id(Class cls, String key)` Construct from the result of a `toString()` call on another instance.
`Id(Id oid)` Copy constructor.
`Id(long key, Class cls)` Deprecated. Use `Id(Class, long)`.
`Id(String str)` Create an id from the result of a `toString()` call on another instance.
`Id(String key, Class cls)` Deprecated. Use `Id(Class,String)`.
`Id(String str, ClassLoader loader)` Create an id from the result of an `toString()` call on another instance.
`Id(String str, JDOConfiguration conf, ClassLoader pmLoader)` Create an id from the result of an `toString()` call on another instance.

Method Summary
`boolean` | `equals(Object obj)`
`long` | `getKey()` Primary key.
`Class` | `getTargetClass()` Target class.
`Class` | `getTargetClass(ClassLoader loader)` Target class.
`Class` | `getTargetClass(JDOConfiguration conf, ClassLoader pmLoader)` Target class.
`String` | `getTargetClassName()` Target class name.
`int` | `hashCode()`
`String` | `toString()`

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

Field Detail

### id

    public long id

  Deprecated. Use `getKey()`.

### type

    public transient Class type

  Deprecated. Use `getTargetClass()`.

Constructor Detail

### Id

    public Id()

  Deprecated.

### Id

    public Id(String str)

  Create an id from the result of a `toString()` call on another instance.

### Id

    public Id(String str,
              JDOConfiguration conf,
              ClassLoader pmLoader)

  Create an id from the result of an `toString()` call on another instance.

### Id

    public Id(String str,
              ClassLoader loader)

  Create an id from the result of an `toString()` call on another instance.

### Id

    public Id(String key,
              Class cls)

  Deprecated. Use `Id(Class,String)`.

### Id

    public Id(Class cls,
              String key)

  Construct from the result of a `toString()` call on another instance.

### Id

    public Id(Class cls,
              Long key)

  Construct from key value.

### Id

    public Id(long key,
              Class cls)

  Deprecated. Use `Id(Class, long)`.

### Id

    public Id(Class cls,
              long key)

  Construct from key value.

### Id

    public Id(Id oid)

  Copy constructor.

Method Detail

### getKey

    public long getKey()

  Primary key.

### getTargetClassName

    public String getTargetClassName()

  Target class name.

### getTargetClass

    public Class getTargetClass()

  Target class. This method may return null if the instance has been serialized.

### getTargetClass

    public Class getTargetClass(JDOConfiguration conf,
                                ClassLoader pmLoader)

  Target class. This method will attempt to instantiate the target class from the target class name if this instance has been serialized. Uses the given configuration's class resolver and the given persistence manager class loader, which may be null.

### getTargetClass

    public Class getTargetClass(ClassLoader loader)

  Target class. This method will attempt to instantiate the target class from the target class name if this instance has been serialized. If the given class loader is null, the current thread's context loader will be used.

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `Object`

### equals

    public boolean equals(Object obj)

  Overrides:
    `equals` in class `Object`

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

Overview | Package | Class | Tree | Deprecated | Index | Help
| SolarMetric Kodo JDO 3.3.5 generated on August 31 2005
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

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