ICommonConfiguration.

ExceptionsOnNotStorable Property

Summary

configures whether Exceptions are to be thrown, if objects can not be stored.

Syntax

bool ExceptionsOnNotStorable { set; }

Remarks

configures whether Exceptions are to be thrown, if objects can not be stored.

db4o requires the presence of a constructor that can be used to instantiate objects. If no default public constructor is present, all available constructors are tested, whether an instance of the class can be instantiated. Null is passed to all constructor parameters. The first constructor that is successfully tested will be used throughout the running db4o session. If an instance of the class can not be instantiated, the object will not be stored. By default, execution will be stopped with an Exception. This method can be used to configure db4o to not throw an Db4objects.Db4o.Ext.ObjectNotStorableException if an object can not be stored.

The default for this setting is true.

In a client/server environment it is good practice to configure the client and the server in exactly the same way.

Value

Type Description
bool true to throw Exceptions if objects can not be stored.