Re: Interfaces and Java Client
Re: Interfaces and Java Client
- Subject: Re: Interfaces and Java Client
- From: Chuck Hill <email@hidden>
- Date: Thu, 27 Apr 2006 10:25:07 -0700
And just to prove that there is no one, right answer. :-)
If I know that I will be fetching only on a single subclass then I
will keep these in separate tables. If I will be fetching further up
the inheritance hierarchy (i.e. fetches will return multiple
subclasses), then I keep it all in one table for performance
reasons. I don't really care if the data is the same or not.
It is worth noting that regardless of what you choose that the
resulting Java classes are the same (give or take the appearance of
an entity qualifier). This is an optimization / database design
decision, not an application design one.
Chuck
On Apr 27, 2006, at 10:10 AM, Ken Anderson wrote:
Inheritance can vastly improve the features of EOF if used
properly. In general, I usually make all super-entities abstract,
and have a different table for each leaf. However, if your data is
all the same and you just need inheritance for different behavior
in code, I typically use a single table and use well defined
qualifiers for the entities. A while ago (after much complaining),
the EOF engineers worked out a way to not do queries for all the
sub-entities if you're entity qualifier was straightforward like:
"type = 'A'". I highly suggest sticking with this for performance
reasons.
Ken
On Apr 27, 2006, at 1:00 PM, Chuck Hill wrote:
On Apr 27, 2006, at 1:13 AM, Paul Lynch wrote:
You may want to use entity inheritance to design your model; see
http://developer.apple.com/documentation/WebObjects/
UsingEOModeler/7ModelingInheritance/chapter_7_section_1.html
The only thing I'll add is that, from experience, most of the
times that using inheritance is possible, I choose to flatten out
the model instead. Other people may have different experiences.
From the OO viewpoint, a complex design has the same problems as
overnormalisation has in relational database design.
On the other side of this fence, I use inheritance whenever it
makes sense in the OO view. I have found that this greatly
simplifies many aspects of the application.
Chuck
--
Coming in late 2006 - an introduction to web applications using
WebObjects and Xcode http://www.global-village.net/wointro
Practical WebObjects - for developers who want to increase their
overall knowledge of WebObjects or who are trying to solve
specific problems. http://www.global-village.net/products/
practical_webobjects
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40anderhome.com
This email sent to email@hidden
--
Coming in late 2006 - an introduction to web applications using
WebObjects and Xcode http://www.global-village.net/wointro
Practical WebObjects - for developers who want to increase their
overall knowledge of WebObjects or who are trying to solve specific
problems. http://www.global-village.net/products/practical_webobjects
_______________________________________________
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