Saturday, July 23, 2005

[Opf3] Firebird storage ready, Rights on persistent objects

The Firebird storage for Opf3 is ready. We had to add a new interface to support the storage. Firebird does not support boolean (nor bit) as native type. Therefore we had to create an interface that allows a storage to convert values to any other type. This has to be done during load and during save. The interface is only implemented by the Firebird storage (right now) and has no inpact on other storages (which was the main goal of the interface).

We created also the possiblity to set rights on persistent objects. You may have persistent objects that should only be loaded and not inserted, deleted or updated. This can be accomplished by setting the right to "Load" and deny all other rights. It's very simple to use those rights:

// Rights are set to "Load" - other rights are denied.
[Persistent("FOO", Rights = PersistentRights.Load)]
public class Foo
    // Properties and other code...

// Allows to load and insert.
[Persistent("BAR", Rights = PersistentRights.Load | PersistentRights.Insert)]
public class Bar
    // Properties and other code...

We are waiting to publish the next version because we want to write other test cases and add features. We are currently also testing the framework in some applications (I'm testing it at Sarix and Marco in his applications).

I guess the next update of the framework will be released with the RC1 of the .NET framework (which is targeted to August).


Post a Comment

<< Home