Re: Direct to Java Client and frameworks
Re: Direct to Java Client and frameworks
- Subject: Re: Direct to Java Client and frameworks
- From: email@hidden
- Date: Mon, 3 Oct 2005 15:04:46 +0200
Make sure your EO classes really are
available to your client. For the client to use them they should be inside
the JAR file in the WebServerResources directory of your framework. They
should also be in the JAR file inside the Resources directory for the server
side code to use them.
Make usre you don't use any EOAccess
class inside your EOs or classes they refer to. EOAccess is not available
on the client.
If you use the same EO classes on both
client and server make sure to specify your default values in awakeFromInsertion()
like this:
if (someAttribute() == null)
{
setSomeAttribute(defaultValue);
}
Hope this helps.
Pierre
webobjects-dev-bounces+pierre.bernard=email@hidden
wrote on 10/03/2005 12:28:24 PM:
> 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
>
**********************************************************************
This email and any files transmitted with it are intended solely for
the use of the individual or entity to whom they are addressed.
If you have received this email in error please notify the sender
of this message. (email@hidden)
This email message has been checked for the presence of computer
viruses; however this protection does not ensure this message is
virus free.
Banque centrale du Luxembourg; Tel ++352-4774-1; http://www.bcl.lu
**********************************************************************
_______________________________________________
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