Re: Direct to Java Client and frameworks (reposted)
Re: Direct to Java Client and frameworks (reposted)
- Subject: Re: Direct to Java Client and frameworks (reposted)
- From: David Avendasora <email@hidden>
- Date: Thu, 31 Aug 2006 12:36:35 -0400
Jarvis,
Are you still around? Did you ever find a solution for
awakeFromInsertion() not firing on the client-side?
I'm running into this exact same problem with my _very_ simple
application.
The way it appears that Java Client stuff works is that on the Server
Side, awakeFromInsertion isn't called until you save (as you found
out). Defaults (contrary to Apple's Java Client Documentation) should
be setup on the client, which only makes sense since it is a UI
thing, not really a business logic thing.
The major problem, as far as I can tell, is that the client-side
class is NOT being called when the "new" button is clicked, even
though the client-side class is correctly defined in the EOModel. It
appears that the client is simply using EOGenericRecord to
instantiate my class instead.
Any input you have would be greatly appreciated.
Dave
On Dec 27, 2005, at 11:42 AM, Jarvis Cochrane wrote:
From: Jarvis Cochrane <email@hidden>
Date: 3 October 2005 6:28:24 PM
To: email@hidden
Subject: Direct to Java Client and frameworks
Hello,
I'm trying to get my head around Direct to Java Client...
I've created a Framework to contain my EOModel and classes and
associated logic. I would like to create a direct to java client
as a separate project, which references the framework.
I'm trying to factor my "business logic" out into a framework that
doesn't need to know anything about direct to java or web pages
or any of that stuff!
Initially things worked ok - the d2jc application would allow me
to create data records, and perform searches, and so on.
The next step was to add an awakeFromInsertion() method on one of
the classes in my framework to supply default values for
properties. This doesn't appear to be being invoked on the client
(no default values), but is invoked on the server when the client
saves the data record (which means that it changes the value that
user has entered!).
I've tried reading Apple's documentation, but I can't make head
nor tail of it - at least where this issue is concerned.
So... How do you set up a d2jc project / application to say "use
the model and classes from this framework", and "use the server
side method in preference to a local method"?
Hoping someone can help,
jarvis
_______________________________________________
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