Package com.db4o.internal
Class Config4Field
- java.lang.Object
-
- com.db4o.internal.Config4Abstract
-
- com.db4o.internal.Config4Field
-
- All Implemented Interfaces:
ObjectField
,DeepClone
public class Config4Field extends Config4Abstract implements ObjectField, DeepClone
-
-
Field Summary
-
Fields inherited from class com.db4o.internal.Config4Abstract
_config
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
Config4Field(Config4Class a_class, KeySpecHashtable4 config)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
deepClone(java.lang.Object param)
The parameter allows passing one new object so parent references can be corrected on children.void
indexed(boolean flag)
turns indexing on or off.void
initOnUp(Transaction systemTrans, FieldMetadata fieldMetadata)
void
rename(java.lang.String newName)
renames a field of a stored class.boolean
used()
void
used(boolean flag)
-
Methods inherited from class com.db4o.internal.Config4Abstract
cascadeOnActivate, cascadeOnActivate, cascadeOnDelete, cascadeOnDelete, cascadeOnUpdate, cascadeOnUpdate, equals, getName, hashCode, putThreeValued, putThreeValuedInt, setName
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.db4o.config.ObjectField
cascadeOnActivate, cascadeOnDelete, cascadeOnUpdate
-
-
-
-
Constructor Detail
-
Config4Field
protected Config4Field(Config4Class a_class, KeySpecHashtable4 config)
-
-
Method Detail
-
deepClone
public java.lang.Object deepClone(java.lang.Object param)
Description copied from interface:DeepClone
The parameter allows passing one new object so parent references can be corrected on children.
-
rename
public void rename(java.lang.String newName)
Description copied from interface:ObjectField
renames a field of a stored class.
Use this method to refactor classes.
In client-server environment this setting should be used on both client and server.
This setting can NOT be applied to an open object container.- Specified by:
rename
in interfaceObjectField
- Parameters:
newName
- the new field name.
-
indexed
public void indexed(boolean flag)
Description copied from interface:ObjectField
turns indexing on or off.
Field indices dramatically improve query performance but they may considerably reduce storage and update performance.
The best benchmark whether or not an index on a field achieves the desired result is the completed application - with a data load that is typical for it's use.
This configuration setting is only checked when theObjectContainer
is opened. If the setting is set to true and an index does not exist, the index will be created. If the setting is set to false and an index does exist the index will be dropped.
In client-server environment this setting should be used on both client and server.
If this setting is applied to an open ObjectContainer it will take an effect on the next time ObjectContainer is opened.- Specified by:
indexed
in interfaceObjectField
- Parameters:
flag
- specify true or false to turn indexing on for this field
-
initOnUp
public void initOnUp(Transaction systemTrans, FieldMetadata fieldMetadata)
-
used
public void used(boolean flag)
-
used
public boolean used()
-
-