|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.tivoli.twg.engine.TWGObject
Base class for engine objects (both non-persistent and persistent). Primary purpose is to generate a unique object ID and add the object to a global hask table.
Constructor Summary | |
---|---|
TWGObject()
Constructor for TWGObject: assign new ID and add object to hash table |
|
TWGObject(boolean do_insert)
Constructor for TWGObject: if insert requested, assign new ID and add object to hash table, if not, object ID is invalid. |
Method Summary | |
---|---|
static java.util.Enumeration |
AllObjects()
Enumerate all TWGObjects |
static java.util.Enumeration |
AllObjects(java.lang.Class cls)
Enumerate all TWGObject instances derived from a given class. |
void |
Delete()
Delete the object (without deleting any persistent state). |
void |
Destroy()
Destroy a TWGObject. |
static void |
DumpTWGObjects()
Dump list of all TWGObject instances (debug) |
static TWGObject |
FindObject(long oid)
Find object, given an object ID |
boolean |
isDeleted()
Test if object is deleted object |
boolean |
isNewObject()
Test if object is new object (doesn't have a valid object ID yet) |
boolean |
isPersistent()
Test if object is persistent object |
static boolean |
isPersistent(long oid)
Test if object is persistent object ID |
boolean |
isValid()
Test if object has valid object ID |
static boolean |
isValid(long oid)
Test if object has valid object ID |
long |
ObjectID()
Return the object ID |
long |
setDistinctObjectID()
Assign distinct initial dynamic object ID : used for making non-persistent objects constructed with the TWGObject(false) constructor valid. |
void |
SetObjectID(long oid)
Change the object ID to a new value |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public TWGObject(boolean do_insert)
do_insert
- - if true, insert in hash table, else do notpublic TWGObject()
Method Detail |
public void Delete()
public void Destroy() throws TWGObjectDestroyException
TWGObjectDestroyException
- if error during destroypublic long ObjectID() throws InvalidObjectIDException
InvalidObjectIDException
- if object ID is not validpublic void SetObjectID(long oid) throws DuplicateObjectIDException
oid
- - new object ID value
DuplicateObjectIDException
- if ID is duplicatepublic static TWGObject FindObject(long oid)
oid
- - object ID of object to find
public final boolean isValid()
public static final boolean isValid(long oid)
oid
- - object ID to be tested
public final boolean isPersistent()
public static final boolean isPersistent(long oid)
oid
- - object ID to be tested
public final boolean isDeleted()
public final boolean isNewObject()
public static java.util.Enumeration AllObjects(java.lang.Class cls)
cls
- - class to be scanned for
public static java.util.Enumeration AllObjects()
public static void DumpTWGObjects()
public long setDistinctObjectID()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |