|
db4o 8.0 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ObjectClass
configuration interface for classes.
Use the global CommonConfiguration.objectClass(Object)
to configure
object class settings.
Method Summary | |
---|---|
void |
callConstructor(boolean flag)
advises db4o to try instantiating objects of this class with/without calling constructors. |
void |
cascadeOnActivate(boolean flag)
sets cascaded activation behaviour. |
void |
cascadeOnDelete(boolean flag)
sets cascaded delete behaviour. |
void |
cascadeOnUpdate(boolean flag)
sets cascaded update behaviour. |
void |
compare(ObjectAttribute attributeProvider)
Deprecated. since version 7.0 |
void |
enableReplication(boolean setting)
Deprecated. As of version 8.0 please use generateUUIDs(boolean) and FileConfiguration.generateCommitTimestamps(boolean) instead |
void |
generateUUIDs(boolean setting)
generate UUIDs for stored objects of this class. |
void |
generateVersionNumbers(boolean setting)
Deprecated. As of version 8.0 please use FileConfiguration.generateCommitTimestamps(boolean) instead |
void |
indexed(boolean flag)
turns the class index on or off. |
void |
maximumActivationDepth(int depth)
sets the maximum activation depth to the desired value. |
int |
minimumActivationDepth()
gets the configured minimum activation depth. |
void |
minimumActivationDepth(int depth)
sets the minimum activation depth to the desired value. |
ObjectField |
objectField(java.lang.String fieldName)
returns an ObjectField object
to configure the specified field. |
void |
persistStaticFieldValues()
turns on storing static field values for this class. |
void |
rename(java.lang.String newName)
renames a stored class. |
void |
storeTransientFields(boolean flag)
allows to specify if transient fields are to be stored. |
void |
translate(ObjectTranslator translator)
registers a translator for this class. |
void |
updateDepth(int depth)
specifies the updateDepth for this class. |
Method Detail |
---|
void callConstructor(boolean flag)
Configuration.callConstructors(boolean)
.
flag
- - specify true, to request calling constructors, specify
false to request not calling constructors.Configuration.callConstructors(boolean)
void cascadeOnActivate(boolean flag)
flag
- whether activation is to be cascaded to member objects.ObjectField.cascadeOnActivate(boolean)
,
ObjectContainer.activate(java.lang.Object, int)
,
Using callbacks
,
Why activation?
void cascadeOnDelete(boolean flag)
ObjectContainer.delete(Object)
.
ObjectContainer.store(Object)
.
ObjectContainer con;
Bar bar1 = new Bar();
Bar bar2 = new Bar();
foo.bar = bar1;
con.store(foo); // bar1 is stored as a member of foo
foo.bar = bar2;
con.store(foo); // bar2 is stored as a member of foo
flag
- whether deletes are to be cascaded to member objects.ObjectField.cascadeOnDelete(boolean)
,
ObjectContainer.delete(Object)
,
Using callbacks
void cascadeOnUpdate(boolean flag)
ObjectContainer.store(Object)
.
flag
- whether updates are to be cascaded to member objects.ObjectField.cascadeOnUpdate(boolean)
,
com.db4o.ObjectContainer#set
,
Using callbacks
void compare(ObjectAttribute attributeProvider)
attributeProvider
- the attribute provider to be usedvoid enableReplication(boolean setting)
generateUUIDs(boolean)
and FileConfiguration.generateCommitTimestamps(boolean)
instead
setting
- void generateUUIDs(boolean setting)
setting
- void generateVersionNumbers(boolean setting)
FileConfiguration.generateCommitTimestamps(boolean)
instead
setting
- void indexed(boolean flag)
void maximumActivationDepth(int depth)
global setting
depth
- the desired maximum activation depthWhy activation?
,
cascadeOnActivate(boolean)
void minimumActivationDepth(int depth)
global setting
depth
- the desired minimum activation depthWhy activation?
,
cascadeOnActivate(boolean)
int minimumActivationDepth()
ObjectField objectField(java.lang.String fieldName)
ObjectField
object
to configure the specified field.
fieldName
- the name of the field to be configured.ObjectField
object for configuration.void persistStaticFieldValues()
objectContainer.query().constrain(Foo.class); // Java
objectContainer.Query().Constrain(typeof(Foo)); // C#
objectContainer.store(Foo.staticMember); // Java
void rename(java.lang.String newName)
newName
- the new fully qualified class name.void storeTransientFields(boolean flag)
false
.
flag
- whether or not transient fields are to be stored.void translate(ObjectTranslator translator)
ObjectTranslator
is not
compatible with the use of an
internal class ObjectMarshaller.
translator
- this may be an ObjectTranslator
or an ObjectConstructor
ObjectTranslator
,
ObjectConstructor
void updateDepth(int depth)
ObjectContainer.store(Object)
for further details.ObjectContainer.store(Object)
will be updated.
depth
- the depth of the desired update for this class.Configuration.updateDepth(int)
,
cascadeOnUpdate(boolean)
,
ObjectField.cascadeOnUpdate(boolean)
,
Using callbacks
|
db4o 8.0 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |