<xml> </xml>

db4o |

# ObjectField.CascadeOnDelete Method

sets cascaded delete behaviour.

void CascadeOnDelete(
bool flag
);

#### Parameters

flag
  whether deletes are to be cascaded to the member object.

#### Remarks

sets cascaded delete behaviour.
Setting cascadeOnDelete to true will result in the deletion of the object attribute stored in this field on the parent object if the parent object is passed to ObjectContainer#delete() .
Caution !
This setting will also trigger deletion of the old member object, on calls to ObjectContainer#set() . An example of the behaviour can be found in ObjectClass#cascadeOnDelete()
The default setting is false.

#### See Also

ObjectField Interface | com.db4o.config Namespace | com.db4o.config.ObjectClass.CascadeOnDelete | com.db4o.ObjectContainer.Delete | Using callbacks