Oracle FAQ Your Portal to the Oracle Knowledge Grid

Home -> Community -> Usenet -> comp.databases.theory -> Re: Clean Object Class Design -- What is it?

Re: Clean Object Class Design -- What is it?

From: Bob Badour <>
Date: Mon, 3 Sep 2001 20:25:00 -0400
Message-ID: <obVk7.770$>

Craig Shearer wrote in message <3b92b65d$>...
>"Bob Badour" <> wrote in message
>> Craig Shearer wrote in message <3b8e9bff$>...
>> >
>> >"Sascha Bohnenkamp" <> wrote in message
>> >
>> >> > And
>> >> > for bi-directional associations, it enforces referential integrity.
>> >> which OODBMS does this and what is the kind of 'enforcement'?
>> >> Is it only a setting of the bi-link to NULL or more?
>> >> (rdbms forbid those actions or do a delete on cascade if you want them
>> >> to)
>> >
>> >The ODBMS I use (JADE) does this. You define inverse relationships
>> >reference properties (either singular references or collections) on
>> classes.
>> >When you define the inverse, you also define whether the relationship is
>> >parent-child or peer-peer. In the case of a parent-child relationship,
>> >the parent object is deleted, then this will cascade delete the child
>> >object. In the peer-peer case, deleting the object at one side of the
>> >relationship will automatically update the other object's reference to
>> to
>> >null.
>> Who says it should even allow the delete in the first place? Are all
>> references symmetric?
>If you're asking about Integrity Checking, then there is no formal
>for defining this.

This gives a huge advantage to the relational data model then, which does have such a formal mechanism.

>However, it is possible to define code in the destructor
>for the class that would raise an exception under certain circumstances,
>thus preventing deletion by forcing the transaction to abort.

Since the DBMS must support multiple applications and multiple programming environments, what prevents your Java programmers from omitting an important constraint in the destructor that your Smalltalk programmers rely on?

>I'm not certain what you mean by symmetric references, but I'll hazard a
>guess. When references between classes are defined, you specify an update
>mode - effectively which side is manually maintained. So, if the
>relationship defines manual on one side and automatic on the other, then
>compiler will reject (with a syntax error) code attempting to update the
>automatic side of the relationship. It is possible, though, to define both
>sides as manual/automatic, meaning that whichever side is maintained
>manually, the other side will be automatically maintained.

Symmetric means the user can use the value as to identify referencers as easily as the referenced. All of the above manual and automatic crap are just more physical implementation details forced on users. Received on Mon Sep 03 2001 - 19:25:00 CDT

Original text of this message