|
db4o v1.10 | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
callback methods.
This interface only serves as a lists of all available callback methods.
Every method is called individually, independant of implementing this interface.
Using callbacks
Simply implement one or more of the listed methods in your application classes to
respond to activation, deactivation, delete, new or update.
Callback methods are typically used for:
- cascaded delete
- cascaded update
- cascaded activation
- restoring transient members on instantiation
Callback methods follow the regular Java calling conventions. Methods
in superclasses need to be called explicitely.
All method calls are implemented to occur only once, upon one event.
You can however implement infinite loops by constructs like "child updates
parent from objectOnUpdate
, parent updates child from
objectOnUpdate
".
Method Summary | |
void |
objectOnActivate(ObjectContainer container)
called upon activation of an object. |
void |
objectOnDeactivate(ObjectContainer container)
called upon deactivation of an object. |
void |
objectOnDelete(ObjectContainer container)
called after an object was deleted. |
void |
objectOnNew(ObjectContainer container)
called after a new object was stored. |
void |
objectOnUpdate(ObjectContainer container)
called after an object was updated. |
Method Detail |
public void objectOnActivate(ObjectContainer container)
container
- the ObjectContainer
the object is stored in.public void objectOnDeactivate(ObjectContainer container)
container
- the ObjectContainer
the object is stored in.public void objectOnDelete(ObjectContainer container)
container
- the ObjectContainer
the object was stored in.public void objectOnNew(ObjectContainer container)
container
- the ObjectContainer
the object is stored to.public void objectOnUpdate(ObjectContainer container)
container
- the ObjectContainer
the object is stored in.
|
db4o v1.10 | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |