|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ODB
The main ODB public interface: It is what the user sees.
Method Summary | ||
---|---|---|
void |
addDeleteTrigger(java.lang.Class clazz,
DeleteTrigger trigger)
USed to add a delete trigger callback for the specific class |
|
void |
addInsertTrigger(java.lang.Class clazz,
InsertTrigger trigger)
Used to add an insert trigger callback for the specific class |
|
void |
addSelectTrigger(java.lang.Class clazz,
SelectTrigger trigger)
Used to add a select trigger callback for the specific class |
|
void |
addUpdateTrigger(java.lang.Class clazz,
UpdateTrigger trigger)
Used to add an update trigger callback for the specific class |
|
void |
close()
Closes the database. |
|
void |
commit()
Commit all the change of the database @ |
|
java.math.BigInteger |
count(CriteriaQuery query)
Returns the number of objects that satisfy the query |
|
CriteriaQuery |
criteriaQuery(java.lang.Class clazz)
|
|
CriteriaQuery |
criteriaQuery(java.lang.Class clazz,
ICriterion criterio)
|
|
void |
defragmentTo(java.lang.String newFileName)
Defragment ODB Database |
|
OID |
delete(java.lang.Object object)
Delete an object from database |
|
OID |
deleteCascade(java.lang.Object object)
Delete an object and all its sub objects |
|
void |
deleteObjectWithId(OID oid)
Delete an object from the database with the id |
|
void |
disconnect(java.lang.Object object)
Used to disconnect the object from the current session. |
|
ODBExt |
ext()
Get the extension of ODB to get access to advanced functions |
|
ClassRepresentation |
getClassRepresentation(java.lang.Class clazz)
Get an abstract representation of a class |
|
ClassRepresentation |
getClassRepresentation(java.lang.String fullClassName)
Get an abstract representation of a class |
|
ClassRepresentation |
getClassRepresentation(java.lang.String fullClassName,
boolean laodClass)
|
|
java.lang.String |
getName()
Return the name of the database |
|
java.lang.Object |
getObjectFromId(OID id)
Get the object with a specific id * |
|
OID |
getObjectId(java.lang.Object object)
Get the id of an ODB-aware object |
|
|
getObjects(java.lang.Class clazz)
Get all objects of a specific type |
|
|
getObjects(java.lang.Class clazz,
boolean inMemory)
Get all objects of a specific type |
|
|
getObjects(java.lang.Class clazz,
boolean inMemory,
int startIndex,
int endIndex)
|
|
|
getObjects(IQuery query)
Search for objects that matches the query. |
|
|
getObjects(IQuery query,
boolean inMemory)
Search for objects that matches the native query. |
|
|
getObjects(IQuery query,
boolean inMemory,
int startIndex,
int endIndex)
Return a list of objects that matches the query |
|
IRefactorManager |
getRefactorManager()
Returns the object used to refactor the database |
|
Values |
getValues(IValuesQuery query)
Search for objects that matches the query. |
|
boolean |
isClosed()
|
|
void |
reconnect(java.lang.Object object)
Deprecated. Reconnection is now automatic Used to reconnect an object to the current session |
|
void |
rollback()
Undo all uncommitted changes |
|
OID |
store(java.lang.Object object)
Store a plain java Object in the ODB Database |
Method Detail |
---|
void commit()
void rollback()
void close()
OID store(java.lang.Object object)
object
- A plain Java Object<T> Objects<T> getObjects(java.lang.Class clazz)
clazz
- The type of the objects
<T> Objects<T> getObjects(java.lang.Class clazz, boolean inMemory)
clazz
- The type of the objectsinMemory
- if true, preload all objects,if false,load on demand
<T> Objects<T> getObjects(java.lang.Class clazz, boolean inMemory, int startIndex, int endIndex)
clazz
- The type of the objectsinMemory
- if true, preload all objects,if false,load on demandstartIndex
- The index of the first objectendIndex
- The index of the last object that must be returned
OID delete(java.lang.Object object)
object
- OID deleteCascade(java.lang.Object object)
object
- cascade
-
void deleteObjectWithId(OID oid)
oid
- The object id to be deletedValues getValues(IValuesQuery query)
query
-
<T> Objects<T> getObjects(IQuery query)
query
-
<T> Objects<T> getObjects(IQuery query, boolean inMemory)
query
- inMemory
-
<T> Objects<T> getObjects(IQuery query, boolean inMemory, int startIndex, int endIndex)
query
- inMemory
- if true, preload all objects,if false,load on demandstartIndex
- The index of the first objectendIndex
- The index of the last object that must be returned
java.math.BigInteger count(CriteriaQuery query)
query
-
OID getObjectId(java.lang.Object object)
object
-
java.lang.Object getObjectFromId(OID id)
id
-
void defragmentTo(java.lang.String newFileName)
newFileName
- ClassRepresentation getClassRepresentation(java.lang.Class clazz)
clazz
-
ClassRepresentation getClassRepresentation(java.lang.String fullClassName)
fullClassName
-
ClassRepresentation getClassRepresentation(java.lang.String fullClassName, boolean laodClass)
void addUpdateTrigger(java.lang.Class clazz, UpdateTrigger trigger)
trigger
- void addInsertTrigger(java.lang.Class clazz, InsertTrigger trigger)
trigger
- void addDeleteTrigger(java.lang.Class clazz, DeleteTrigger trigger)
trigger
- void addSelectTrigger(java.lang.Class clazz, SelectTrigger trigger)
trigger
- IRefactorManager getRefactorManager()
ODBExt ext()
void reconnect(java.lang.Object object)
void disconnect(java.lang.Object object)
boolean isClosed()
CriteriaQuery criteriaQuery(java.lang.Class clazz, ICriterion criterio)
CriteriaQuery criteriaQuery(java.lang.Class clazz)
java.lang.String getName()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |