Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: passing data to wrapper component



On Tue, 17 Aug 2004 19:49:17 -0700, Sam Barnum
<email@hidden> wrote:
> Good advice, Dirk.  Just to flush in the 'read the apple docs' part:
> 
> A handy shortcut to use the value of a binding directly in a component
> is to use a special syntax to refer to the value of a binding.  THis is
> the carat symbol, followed by the binding name.
> So for the title of the page, add this:
> <html>
> <head>
> <title><WEBOBJECT NAME=titleString></WEBOBJECT></title>
> </head>
> 
> and define the value of the string as ^title
> 
> alternately, you could set the value of the string to title (without
> the carat) and provide the following accessor in your pagewrapper:
> 
> public String getTitle() {
>         return (String)valueForBinding("title");
> }
> 
> Once you get bindings figured out you can do some really nifty reusable
> components.


i've been doing this for a little while now and it is sorta doing what
I want.  However, how would i go about setting bind values for the
pageWrapper programmatically?  presently, I'm just setting them in
WOBuilder, but I'd like to set them from the .java file of the
contained component.  the problem is that their is no instance of the
pageWrapper class within the contained component... how do i go about
referencing it?

thanks,
will
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/email@hidden

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.