Re: Mixing OO and DB

From: Patrick May <pjm_at_spe.com>
Date: Tue, 12 Feb 2008 07:01:32 -0500
Message-ID: <m24pce1izn.fsf_at_spe.com>


"David Cressey" <cressey73_at_verizon.net> writes:
> "Robert Martin" <unclebob_at_objectmentor.com> wrote:
>> Tables expose data and have no behavior. Objects hide data and
>> expose behavior.
>
> I have a different understanding.
>
> Objects do not always hide data. Specifically, they pass messages to each
> other in the form of data.

     Some messages may contain data, but many do not. Consider this, for example:

  Thread someThread = new SomeThreadImplementation();   someThread.run();

Unless you're considering the name of the class and/or the name of the method to be data, the message is solely about behavior.

> Going further, objects do not "see" the behavior of other objects.
> What they see is the data, written into messages, that is the result
> of behavior.

     Objects can invoke the behaviors of other objects without needing to monitor for any results.

> One could do a data centric analysis of an object world, by
> analyzing the data passed among the objects in that world.

     That would miss a great deal of information in a behavior-centric system.

Regards,

Patrick



S P Engineering, Inc. | Large scale, mission-critical, distributed OO
                       | systems design and implementation.
          pjm_at_spe.com  | (C++, Java, Common Lisp, Jini, middleware, SOA)
Received on Tue Feb 12 2008 - 13:01:32 CET

Original text of this message