Re: Object-relational impedence
Date: Mon, 10 Mar 2008 20:05:55 -0500
Message-ID: <2008031020055529560-unclebob_at_objectmentorcom>
On 2008-03-08 21:39:37 -0600, JOG <jog_at_cs.nott.ac.uk> said:
> On Mar 9, 2:23 am, Robert Martin <uncle..._at_objectmentor.com> wrote:
>> On 2008-03-06 06:37:19 -0600, JOG <j..._at_cs.nott.ac.uk> said:
>>
>>> On Mar 6, 6:26 am, Robert Martin <uncle..._at_objectmentor.com> wrote:
>>>> That's not inferrence.
>>
>>> Well that all jolly-well looks like inference to me.
>>
>> I agree that you can infer what elements a subclass has by knowing the
>> elements of the base class.
>
> Well then you have conceded defeat, given our conversation has gone as
> follows:
>
> jog: "So why not treat all 'inheritance' in this way [as inference]?"
> Robert: "Because all inheritance is not about inference."
> jog: show me an example when it is not.
> Robert: I'll ignore that, and just describe the OO mechanism again.
> jog: Look, here is how everything you have listed could have been
> described through inference
> Robert: Ok, I agree that all inheritance can be described via
> inference.
Here's the starting point of the conversation. You wrote:
>> Name(x, Aristotle) -> Species(x, Man) >> Species(x, Man) -> Mortality(x, Mortal) >> |= Name(x, Aristotle) -> Mortalilty(x, Mortal)
>
>> No types or reification in sight. Instead I had two groups of >> statements: >> People = {Name, Species, Bday} >> Entities = {Species, Mortality}
>
>> A join of the two statements gave me the inference I required: {Name, >> Mortality}. All of a sudden it seemed simple. So some questions:
>
>> 1) So why not treat all 'inheritance' in this way? >> 2) Could one extend to include 'behaviour' as well? >> 3) And is this a crazy thing to suggest in a cross post to an OO >> group?
I responded to your first question that when you need to make
inferences, an inference engine is a good tool. Inheritance is not an
inference engine. And you challenged me:
To which I described what inheritance is:
>> Interesting story. Yes, when you have a problem of inference, it's
>> good to use an inference engine.
>>
>>> So some questions:
>>
>>> 1) So why not treat all 'inheritance' in this way?
>>
>> Because all inheritance is not about inference.
>
> Hmmm. Then might you give an example of a situation where inheritance
> cannot be described in terms of inference?
> Inheritance is simply the redeclaration of functions and variables in a
> subscope. That's not inferrence.
To which you said "subscope" was a nonsense word, and we had to define our terms. (sigh).
JOG, you're original question was: Why not treat all inheritance as the kind of inferrence you get from a database join.
Answer: Because inheritance is not inference. Inheritance is the
redeclaration of variables and functions in a subscope.
> I think because of your OO focus you haven't
On the contrary, your initial question was:
> recognized that (in this case) there is a danger of putting the cart
> before the horse. Logic first, mechanism second, not t'other way
> around.
Why can't the mechanism be treated like the logic.