Re: binding trouble
Re: binding trouble
- Subject: Re: binding trouble
- From: Mark Morris <email@hidden>
- Date: Mon, 27 Jun 2005 21:06:21 -0500
The purpose of the java file in a WOComponent is to support the
interface, so having a method for each image is not per se a bad
thing. If it's cleaner in your case, have each cover method call one
main method, passing the appropriate parameter.
That said, I've used the suggested idea of overriding valueForKeyPath
before, and that's a good suggestion for this case.
Regards,
Mark
On Jun 27, 2005, at 3:36 PM, David LeBer wrote:
On 27-Jun-05, at 4:27 PM, Amedeo Mantica wrote:
because I have more than one image for each repetition
Amedeo
On 27/giu/05, at 21:55, Arturo Perez wrote:
Amedeo Mantica wrote:
Yes Arturo, but doing this I need a Java method for each image...
I'm trying to do it in an unique Java method, but I need to pass
it the variable.
Amedeo
You are in a repetition so why do you need a unique variable for
every image?
I still feel that the cleanest way to handle this would be to
create a reusable component that wraps a WOImage with it's src
bound to a method that creates the full path from a "fileName"
binding.
Add as many of these as you need inside the WORepetition. Binding
the fileName to each to the appropriate image string in your
iterator object.
No muss, no fuss, no duplicate methods.
;david
--
David LeBer
Codebase Software Systems
site: http://www.codebase.ca
blog: http://david.codebase.ca
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40onpointsoftware.com
This email sent to email@hidden
_______________________________________________
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