Re: Setting up horizontal inheritance
Re: Setting up horizontal inheritance
- Subject: Re: Setting up horizontal inheritance
- From: Paul Hoadley <email@hidden>
- Date: Wed, 5 Nov 2008 12:58:02 +1030
On 05/11/2008, at 12:30 PM, Chuck Hill wrote:
On Nov 4, 2008, at 3:53 PM, Paul Hoadley wrote:
On 05/11/2008, at 8:46 AM, Chuck Hill wrote:
Just a thought... Are you using Wonder to set the connection
dictionaries for both models?
I wasn't using Wonder, but I was using this:
EODatabaseContext.forceConnectionWithModel(model, overrides,
new EOEditingContext());
to change 'URL', 'username', and 'password' in Application's
constructor. The connection dictionaries should have been
identical after this.
Maybe similar? :-) If overrides does not have all the keys in the
connection dictionary, they won't be the same.
I certainly seemed to be overriding all the keys (looked at
connectionDictionary().allKeys() for all of them). But as I just
wrote elsewhere, I was calling forceConnectionWithModel once for each
model, and not doing this solved the problem, so I assume that was the
cause.
If the connection dictionaries are not _identical_ (and I do mean
indentical), that will cause problems. Perhaps this one. Mike
added something to Wonder, I think, to warn or throw if this
happens. I think...
I'm just using some parts of Wonder in this app at the moment, and
in particular I'm not extending ERXApplication, so I don't know
whether that prevented Wonder from helping me here.
I think you have to marry Wonder to get it to do this for you. Do
you have Practical WebObjects? Page 53 on show a much better way to
do this than what you have above.
Just checking it out now.
--
Paul.
w http://logicsquad.net/
h http://paul.hoadley.name/
_______________________________________________
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