Re: Subclassing and Reusable Components
Re: Subclassing and Reusable Components
- Subject: Re: Subclassing and Reusable Components
- From: Jaime Magiera <email@hidden>
- Date: Tue, 26 Oct 2004 00:53:40 -0400
On Oct 26, 2004, at 12:29 AM, Chuck Hill wrote:
Ah, right. Subclassing is an OO concept that does not translate well
into
a relational database.
I didn't want to go any further until I really understood what's going
on.
If you use something other than single table
inheritance you will not be able to apply FK constraints at the
database
level. I just leave them off and trust in EOF.
Ah, right. It's in the EO Manual, but for some reason didn't sink in.
Now it's clear. Thanks.
I'd have one component that displays the common stuff, and one for each
subclass for the unique stuff. Both would get used to display
different
parts of the same EO. You can use the Entity name of the object to
map to
the relevant editor component and get WOSwitchcomponent to show the
correct one. In the subclass specifc editor subcomponent just cast
the EO
to what it really it.
Ok, that makes sense since JavaClient uses entityName and
Switchcomponents now that I think about it (note to self: start
drinking coffee). Thanks again Chuck, one of these days I'm going to
have to buy you a coffee. You've been amazingly helpful.
Jaime
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden