RE: [OS-webwork] Partition XWork [Was: Re: XWork flux]

2003-01-31 Thread Jason Carreira
 -Original Message-
 From: Erik Beeson [mailto:[EMAIL PROTECTED]] 
 Sent: Thursday, January 30, 2003 7:57 PM
 To: [EMAIL PROTECTED]
 Subject: Re: [OS-webwork] Partition XWork [Was: Re: XWork flux]
 
 
 Jason says 7 jars, Hani says 1, Pat says 2. I have two things to say.

Ummm... No. I said the real question was  Then said I thought one
Webwork jar was enough.

 
 First, should webwork-2.0.jar include the code in 
 xwork-1.0.jar, or should it depend on it? One way makes 
 webwork-2.0.jar stand alone, the other keeps the webwork (not 
 xwork) specific code abstracted from xwork code.

I think we could include the xwork-1.0.jar in the distribution, and it
would need to be in the classpath when you run webwork, just like it
needs commons-logging, etc.

 
 Second, maybe there should be one separate jar for the view code?

Why? Webwork is going to be almost ALL view code, since we're
abstracting out the command pattern stuff into xwork. So I guess in a
way, there is a separate jar for the view code, it's just called Webwork
:-)

 
 Third, all of this should be configurable via 
 build.properties, so one could have a single webwork-2.0.jar 
 with everything included, or one could have more smaller jars 
 as Jason suggested.

Again, I didn't suggest it, and don't think it's a good idea. I also
don't think building xwork into webwork is a good idea, since they'll be
separate CVS modules.

 
 I guess the real question is what should the default be? 
 Maybe 2 files, like Pat said, and have the web tied view code 
 in webwork.jar and the non web view code in xwork.jar?
 
 Ok, so 3 things to say.
 
 --Erik
 
 
Jason


---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork



Re: [OS-webwork] Parameters and the ValueStack

2003-01-31 Thread Erik Beeson
I'm talking about webwork 2.0. Should everything be lookedup on the stack?
Pat's TextfieldTag currently doesn't. I just want some clear standard to
be decided upon.

--Erik

On Sat, 1 Feb 2003, Scott Farquhar wrote:

 Erik,

 Which values are not looked up on the stack?  I know that id isn't (in
 iterator tag).  Anything else?

 I don't think that this can be fixed in current webwork, as we would not
 be able to maintain backwards compatibility?  You should add this as a
 feature to webwork 2.0.

 Cheers,
 Scott

 Erik Beeson wrote:
  The biggest complaint that I hear about the ww taglib is the when to and
  when not to enclose params in single quotes. Currently, the best method
  for figuring this out seems to be to check the source to see if the param
  is ever looked up on the stack. Could there be some standard agreement
  made as to what is and what isn't looked up on the stack? Thoughts?
 
  --Erik
 
 
 
  ---
  This SF.NET email is sponsored by:
  SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
  http://www.vasoftware.com
  ___
  Opensymphony-webwork mailing list
  [EMAIL PROTECTED]
  https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
 

 --

 ATLASSIAN - http://www.atlassian.com
 Expert J2EE Software, Services and Support
 ---
 Need a simple, powerful way to track and manage issues?
 Try JIRA - http://www.atlassian.com/software/jira



 ---
 This SF.NET email is sponsored by:
 SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
 http://www.vasoftware.com
 ___
 Opensymphony-webwork mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork




---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork



[OS-webwork] how to access bean property?

2003-01-31 Thread Andre Mermegas
Hey all,
If I'm doing something like:

In my Action.doExecute()
ActionContext ac = new ActionContext();
BeanUtil.setProperties(ac.getParameters(),new TestBean());

TestBean has one property name.

How do I access the name property using the ww taglibs?

ww:property value=name/ doesn't seem to be hitting the bean.
ww:property value=$name/ does work, picking up the request parameter
directly.

I thought maybe I had to name the object bean and then pass it in, like
TestBean tb = new TestBean(); and then pass in the tb object and do
ww:property value=tb/name/ but that doesn't work either.

I've been looking through the docs, but I cant find it. I know I'm not
hitting the Bean on the view.

Regards,
-Andre Mermegas





Regards,
-Andre Mermegas



attachment: winmail.dat

[OS-webwork] Report to Recipient(s)

2003-01-31 Thread notes . mis
Incident Information:-

Originator: [EMAIL PROTECTED]
Recipients: [EMAIL PROTECTED]
Subject:[OS-webwork] how to access bean property?

Message from [EMAIL PROTECTED] was
quarantined because it contained something  potentially damaging to the
computers and/or may affect the performance of the Keells network.
___
CONFIDENTIALITY AND DISCLAIMER

This communication is privileged and confidential, and is directed to and
for the use of the addressee only. If this message reaches any person other
than the intended recipient, we request such person to preserve its
confidentiality,  not read, reproduce, copy, disseminate or in any manner
distribute it. We further request such recipient to notify us immediately
by email that such message has been received and delete the original
message.


Please note that we reserve the right to monitor all email communications
through our network.

__







---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork



RE: [OS-webwork] Parameters and the ValueStack

2003-01-31 Thread Jason Carreira
I think id is the only thing not looked up, and should be the only thing
not looked up. The reason is that id is a standard attribute to set
something into the page request with a certain name, and it's not
dynamic anywhere else.

 -Original Message-
 From: Erik Beeson [mailto:[EMAIL PROTECTED]] 
 Sent: Friday, January 31, 2003 8:49 PM
 To: [EMAIL PROTECTED]
 Subject: Re: [OS-webwork] Parameters and the ValueStack
 
 
 I'm talking about webwork 2.0. Should everything be lookedup 
 on the stack? Pat's TextfieldTag currently doesn't. I just 
 want some clear standard to be decided upon.
 
 --Erik
 
 On Sat, 1 Feb 2003, Scott Farquhar wrote:
 
  Erik,
 
  Which values are not looked up on the stack?  I know that 
 id isn't 
  (in iterator tag).  Anything else?
 
  I don't think that this can be fixed in current webwork, as 
 we would 
  not be able to maintain backwards compatibility?  You 
 should add this 
  as a feature to webwork 2.0.
 
  Cheers,
  Scott
 
  Erik Beeson wrote:
   The biggest complaint that I hear about the ww taglib is 
 the when to 
   and when not to enclose params in single quotes. 
 Currently, the best 
   method for figuring this out seems to be to check the 
 source to see 
   if the param is ever looked up on the stack. Could there be some 
   standard agreement made as to what is and what isn't looked up on 
   the stack? Thoughts?
  
   --Erik
  
  
  
   ---
   This SF.NET email is sponsored by:
   SourceForge Enterprise Edition + IBM + LinuxWorld = 
 Something 2 See! 
   http://www.vasoftware.com 
   ___
   Opensymphony-webwork mailing list 
   [EMAIL PROTECTED]
   https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
  
 
  --
 
  ATLASSIAN - http://www.atlassian.com
  Expert J2EE Software, Services and Support
  ---
  Need a simple, powerful way to track and manage issues?
  Try JIRA - http://www.atlassian.com/software/jira
 
 
 
  ---
  This SF.NET email is sponsored by:
  SourceForge Enterprise Edition + IBM + LinuxWorld = 
 Something 2 See! 
  http://www.vasoftware.com 
  ___
  Opensymphony-webwork mailing list 
  [EMAIL PROTECTED]
  https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
 
 
 
 
 ---
 This SF.NET email is sponsored by:
 SourceForge Enterprise Edition + IBM + LinuxWorld = Something 
 2 See! http://www.vasoftware.com 
 ___
 Opensymphony-webwork mailing list 
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
 


---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork



RE: [OS-webwork] how to access bean property?

2003-01-31 Thread Jason Carreira
Title: RE: [OS-webwork] how to access bean property?






Andre,


You'll want to do ActionContext.getContext() instead of new ActionContext().


ActionContext.getContext() gets the ThreadLocal instance which is populated by the ServletDispatcher.


You'll probably also want to maintain a reference to your TestBean :-)


Here's an example:


public class TestAction extends ActionSupport {

 private TestBean myBean;


 public TestBean getMyBean() {

 return myBean;

 }


 public void setMyBean(TestBean myBean) {

 this.myBean = myBean;

 }


 protected String doExecute() throws Exception {

 myBean = new TestBean();

 BeanUtil.setProperties(ActionContext.getContext().getParameters(), myBean);

 return SUCCESS;

 }

}


Then, in your success.jsp, which is mapped as the success result of TestAction in the views.properties or actions.xml (see the docs for how to configure actions and view mappings), you can do this:

webwork:property value=myBean !-- This will call getMyBean() on your action and put it on the top of the value stack --

The name is: webwork:property value=name/ !-- This will call getName() on your TestBean and print it to the page

/webwork:property


This is a good way to do it if you have several parameters from the TestBean that you want to display, but, if you have just one, like in this case, it's probably better to do this:

webwork:property value=myBean/name/


Which will call getMyBean.getName() and print that out to the page.


Hope that helps.


I've also put this up on the Wiki:


http://www.opensymphony.com:8668/space/How+do+I+populate+a+form+bean+and+get+the+value+using+the+taglib%3F


-Original Message-

From:  [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] On Behalf Of Andre Mermegas

Sent: Friday, January 31, 2003 9:00 PM

To: [EMAIL PROTECTED]

Subject: [OS-webwork] how to access bean property?


Hey all,

If Im doing something like:


In my Action.doExecute()

ActionContext ac = new ActionContext(); BeanUtil.setProperties(ac.getParameters(),new TestBean());


TestBean has one property name.


How do I access the name property using the ww taglibs?


ww:property value=name/ doesnt seem to be hitting the bean. ww:property value=$name/ does work, picking up the request parameter directly.

I thought maybe I had to name the object bean and then pass it in, like TestBean tb = new TestBean(); and then pass in the tb object and do ww:property value=tb/name/ but that doesnt work either.

I've been looking through the docs, but I cant find it. I know I'm not hitting the Bean on the view.


Regards,

-Andre Mermegas






Regards,

-Andre Mermegas






RE: [OS-webwork] how to access bean property?

2003-01-31 Thread Andre Mermegas
Title: RE: [OS-webwork] how to access bean property?









Thanks,
for the help Jason, Great explanation. Its working now and Im
back on my way to happily exploring more stuff =D





Regards,

-Andre Mermegas





-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Jason Carreira
Sent: Friday, January 31, 2003
9:51 PM
To:
[EMAIL PROTECTED]
Subject: RE: [OS-webwork] how to
access bean property?



Andre, 

You'll want to do
ActionContext.getContext() instead of new ActionContext(). 

ActionContext.getContext()
gets the ThreadLocal instance which is populated by the ServletDispatcher.


You'll probably also want
to maintain a reference to your TestBean :-) 

Here's an example:


public class TestAction
extends ActionSupport { 
 private TestBean myBean; 

 public
TestBean getMyBean() { 
 return myBean;

 } 

 public
void setMyBean(TestBean myBean) { 
 this.myBean =
myBean; 
 } 


protected String doExecute() throws Exception { 
 myBean = new
TestBean(); 

BeanUtil.setProperties(ActionContext.getContext().getParameters(), myBean);

 return SUCCESS;

 } 
} 

Then, in your
success.jsp, which is mapped as the success result of TestAction in the
views.properties or actions.xml (see the docs for how to configure actions and
view mappings), you can do this:

webwork:property
value=myBean !-- This will call getMyBean() on your action
and put it on the top of the value stack --

The name is:
webwork:property value=name/ !-- This will call
getName() on your TestBean and print it to the page 
/webwork:property 

This is a good way to do
it if you have several parameters from the TestBean that you want to display,
but, if you have just one, like in this case, it's probably better to do this:

webwork:property
value=myBean/name/ 

Which will call
getMyBean.getName() and print that out to the page. 

Hope that helps.


I've also put this up on
the Wiki: 

http://www.opensymphony.com:8668/space/How+do+I+populate+a+form+bean+and+get+the+value+using+the+taglib%3F


-Original Message-

From:  [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of
Andre
Mermegas

Sent:
Friday,
January 31, 2003 9:00 PM 
To: [EMAIL PROTECTED]

Subject:
[OS-webwork]
how to access bean property? 

Hey all, 
If
Im doing something like: 

In my Action.doExecute()

ActionContext
ac = new ActionContext(); BeanUtil.setProperties(ac.getParameters(),new
TestBean()); 

TestBean has one property
name. 

How do I access the
name property using the ww taglibs? 

ww:property
value=name/ doesnt seem to be hitting the bean.
ww:property value=$name/ does work, picking up the request
parameter directly.

I thought maybe I had to
name the object bean and then pass it in, like TestBean tb = new TestBean();
and then pass in the tb object and do ww:property
value=tb/name/ but that doesnt work either.

I've been looking through
the docs, but I cant find it. I know I'm not hitting the Bean on the view.


Regards, 
-Andre
Mermegas 






Regards, 
-Andre Mermegas 










RE: [OS-webwork] how to access bean property?

2003-01-31 Thread Erik Beeson
Read Jason's email again carefully. For that to work, you need to have the
ww:property value=name / tag inside the body of the first tag. Like I
said, check Jason's example again carefully.

To the developers who don't want to break up PropertyTag, here we see the
problem with a single tag that tries to do too much.

--Erik


On Fri, 31 Jan 2003, Andre Mermegas wrote:

 Oh, one thing, I tried pushing the testBean to the top of the value
 stack by doing

 ww:property value=testBean/

 and then accessing it

 ww:property value=name/



 But the first ww:property is actually outputting, not pushing the bean
 to the top of the value stack I think.

 com.versionary.beans.TestBean@a33d00







 Regards,

 -Andre Mermegas



 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]] On Behalf Of
 Jason Carreira
 Sent: Friday, January 31, 2003 9:51 PM
 To: [EMAIL PROTECTED]
 Subject: RE: [OS-webwork] how to access bean property?



 Andre,

 You'll want to do ActionContext.getContext() instead of new
 ActionContext().

 ActionContext.getContext() gets the ThreadLocal instance which is
 populated by the ServletDispatcher.

 You'll probably also want to maintain a reference to your TestBean :-)

 Here's an example:

 public class TestAction extends ActionSupport {
 private TestBean myBean;

 public TestBean getMyBean() {
 return myBean;
 }

 public void setMyBean(TestBean myBean) {
 this.myBean = myBean;
 }

 protected String doExecute() throws Exception {
 myBean = new TestBean();

 BeanUtil.setProperties(ActionContext.getContext().getParameters(),
 myBean);
 return SUCCESS;
 }
 }

 Then, in your success.jsp, which is mapped as the success result of
 TestAction in the views.properties or actions.xml (see the docs for how
 to configure actions and view mappings), you can do this:

 webwork:property value=myBean !-- This will call getMyBean() on
 your action and put it on the top of the value stack --

 The name is: webwork:property value=name/ !-- This will call
 getName() on your TestBean and print it to the page
 /webwork:property

 This is a good way to do it if you have several parameters from the
 TestBean that you want to display, but, if you have just one, like in
 this case, it's probably better to do this:

 webwork:property value=myBean/name/

 Which will call getMyBean.getName() and print that out to the page.

 Hope that helps.

 I've also put this up on the Wiki:


 http://www.opensymphony.com:8668/space/How+do+I+populate+a+form+bean+an
 d+get+the+value+using+the+taglib%3F
 http://www.opensymphony.com:8668/space/How+do+I+populate+a+form+bean+and
 +get+the+value+using+the+taglib%3F

  -Original Message-
 From:   [EMAIL PROTECTED] [
 mailto:[EMAIL PROTECTED]
 mailto:[EMAIL PROTECTED]]  On Behalf Of
 Andre Mermegas

 Sent:   Friday, January 31, 2003 9:00 PM
 To: [EMAIL PROTECTED]
 Subject:[OS-webwork] how to access bean property?

 Hey all,
 If I'm doing something like:

 In my Action.doExecute()
 ActionContext ac = new ActionContext();
 BeanUtil.setProperties(ac.getParameters(),new TestBean());

 TestBean has one property name.

 How do I access the name property using the ww taglibs?

 ww:property value=name/ doesn't seem to be hitting the bean.
 ww:property value=$name/ does work, picking up the request parameter
 directly.

 I thought maybe I had to name the object bean and then pass it in, like
 TestBean tb = new TestBean(); and then pass in the tb object and do
 ww:property value=tb/name/ but that doesn't work either.

 I've been looking through the docs, but I cant find it. I know I'm not
 hitting the Bean on the view.

 Regards,
 -Andre Mermegas






 Regards,
 -Andre Mermegas







---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork



RE: [OS-webwork] how to access bean property?

2003-01-31 Thread Andre Mermegas
Ahh ok. Thanks. Read it too quickly.

Regards,
-Andre Mermegas


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of
Erik Beeson
Sent: Friday, January 31, 2003 10:34 PM
To: [EMAIL PROTECTED]
Subject: RE: [OS-webwork] how to access bean property?

Read Jason's email again carefully. For that to work, you need to have
the
ww:property value=name / tag inside the body of the first tag. Like
I
said, check Jason's example again carefully.

To the developers who don't want to break up PropertyTag, here we see
the
problem with a single tag that tries to do too much.

--Erik


On Fri, 31 Jan 2003, Andre Mermegas wrote:

 Oh, one thing, I tried pushing the testBean to the top of the value
 stack by doing

 ww:property value=testBean/

 and then accessing it

 ww:property value=name/



 But the first ww:property is actually outputting, not pushing the bean
 to the top of the value stack I think.

 com.versionary.beans.TestBean@a33d00







 Regards,

 -Andre Mermegas



 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]] On Behalf Of
 Jason Carreira
 Sent: Friday, January 31, 2003 9:51 PM
 To: [EMAIL PROTECTED]
 Subject: RE: [OS-webwork] how to access bean property?



 Andre,

 You'll want to do ActionContext.getContext() instead of new
 ActionContext().

 ActionContext.getContext() gets the ThreadLocal instance which is
 populated by the ServletDispatcher.

 You'll probably also want to maintain a reference to your TestBean :-)

 Here's an example:

 public class TestAction extends ActionSupport {
 private TestBean myBean;

 public TestBean getMyBean() {
 return myBean;
 }

 public void setMyBean(TestBean myBean) {
 this.myBean = myBean;
 }

 protected String doExecute() throws Exception {
 myBean = new TestBean();

 BeanUtil.setProperties(ActionContext.getContext().getParameters(),
 myBean);
 return SUCCESS;
 }
 }

 Then, in your success.jsp, which is mapped as the success result of
 TestAction in the views.properties or actions.xml (see the docs for
how
 to configure actions and view mappings), you can do this:

 webwork:property value=myBean !-- This will call getMyBean() on
 your action and put it on the top of the value stack --

 The name is: webwork:property value=name/ !-- This will call
 getName() on your TestBean and print it to the page
 /webwork:property

 This is a good way to do it if you have several parameters from the
 TestBean that you want to display, but, if you have just one, like in
 this case, it's probably better to do this:

 webwork:property value=myBean/name/

 Which will call getMyBean.getName() and print that out to the page.

 Hope that helps.

 I've also put this up on the Wiki:



http://www.opensymphony.com:8668/space/How+do+I+populate+a+form+bean+an
 d+get+the+value+using+the+taglib%3F

http://www.opensymphony.com:8668/space/How+do+I+populate+a+form+bean+and
 +get+the+value+using+the+taglib%3F

  -Original Message-
 From:   [EMAIL PROTECTED] [
 mailto:[EMAIL PROTECTED]
 mailto:[EMAIL PROTECTED]]  On Behalf Of
 Andre Mermegas

 Sent:   Friday, January 31, 2003 9:00 PM
 To: [EMAIL PROTECTED]
 Subject:[OS-webwork] how to access bean property?

 Hey all,
 If I'm doing something like:

 In my Action.doExecute()
 ActionContext ac = new ActionContext();
 BeanUtil.setProperties(ac.getParameters(),new TestBean());

 TestBean has one property name.

 How do I access the name property using the ww taglibs?

 ww:property value=name/ doesn't seem to be hitting the bean.
 ww:property value=$name/ does work, picking up the request
parameter
 directly.

 I thought maybe I had to name the object bean and then pass it in,
like
 TestBean tb = new TestBean(); and then pass in the tb object and do
 ww:property value=tb/name/ but that doesn't work either.

 I've been looking through the docs, but I cant find it. I know I'm not
 hitting the Bean on the view.

 Regards,
 -Andre Mermegas






 Regards,
 -Andre Mermegas







---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork




---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork



RE: [OS-webwork] how to access bean property?

2003-01-31 Thread Jason Carreira
I agree. PropertyTag does too much. In WW 2.0 we're planning on having
ww:property JUST do the output of the value, and have the pushing onto
the value stack be done by 

ww:push
...use value here...
/ww:push

 -Original Message-
 From: Erik Beeson [mailto:[EMAIL PROTECTED]] 
 Sent: Friday, January 31, 2003 10:34 PM
 To: [EMAIL PROTECTED]
 Subject: RE: [OS-webwork] how to access bean property?
 
 
 Read Jason's email again carefully. For that to work, you 
 need to have the ww:property value=name / tag inside the 
 body of the first tag. Like I said, check Jason's example 
 again carefully.
 
 To the developers who don't want to break up PropertyTag, 
 here we see the problem with a single tag that tries to do too much.
 
 --Erik
 
 
 On Fri, 31 Jan 2003, Andre Mermegas wrote:
 
  Oh, one thing, I tried pushing the testBean to the top of the value 
  stack by doing
 
  ww:property value=testBean/
 
  and then accessing it
 
  ww:property value=name/
 
 
 
  But the first ww:property is actually outputting, not 
 pushing the bean 
  to the top of the value stack I think.
 
  com.versionary.beans.TestBean@a33d00
 
 
 
 
 
 
 
  Regards,
 
  -Andre Mermegas
 
 
 
  -Original Message-
  From: [EMAIL PROTECTED]
  [mailto:[EMAIL PROTECTED]] 
 On Behalf Of 
  Jason Carreira
  Sent: Friday, January 31, 2003 9:51 PM
  To: [EMAIL PROTECTED]
  Subject: RE: [OS-webwork] how to access bean property?
 
 
 
  Andre,
 
  You'll want to do ActionContext.getContext() instead of new 
  ActionContext().
 
  ActionContext.getContext() gets the ThreadLocal instance which is 
  populated by the ServletDispatcher.
 
  You'll probably also want to maintain a reference to your 
 TestBean :-)
 
  Here's an example:
 
  public class TestAction extends ActionSupport {
  private TestBean myBean;
 
  public TestBean getMyBean() {
  return myBean;
  }
 
  public void setMyBean(TestBean myBean) {
  this.myBean = myBean;
  }
 
  protected String doExecute() throws Exception {
  myBean = new TestBean();
 
  BeanUtil.setProperties(ActionContext.getContext().getParameters(),
  myBean);
  return SUCCESS;
  }
  }
 
  Then, in your success.jsp, which is mapped as the success result of 
  TestAction in the views.properties or actions.xml (see the docs for 
  how to configure actions and view mappings), you can do this:
 
  webwork:property value=myBean !-- This will call 
 getMyBean() on 
  your action and put it on the top of the value stack --
 
  The name is: webwork:property value=name/ !-- This will call
  getName() on your TestBean and print it to the page 
  /webwork:property
 
  This is a good way to do it if you have several parameters from the 
  TestBean that you want to display, but, if you have just 
 one, like in 
  this case, it's probably better to do this:
 
  webwork:property value=myBean/name/
 
  Which will call getMyBean.getName() and print that out to the page.
 
  Hope that helps.
 
  I've also put this up on the Wiki:
 
 
  
 http://www.opensymphony.com:8668/space/How+do+I+populate+a+form+bean+
  an
  d+get+the+value+using+the+taglib%3F
  
 http://www.opensymphony.com:8668/space/How+do+I+populate+a+form+bean+a
  nd
  +get+the+value+using+the+taglib%3F
 
   -Original Message-
  From:   [EMAIL PROTECTED] [
  mailto:[EMAIL PROTECTED]
  mailto:[EMAIL PROTECTED]]  
 On Behalf Of 
  Andre Mermegas
 
  Sent:   Friday, January 31, 2003 9:00 PM
  To: [EMAIL PROTECTED]
  Subject:[OS-webwork] how to access bean property?
 
  Hey all,
  If I'm doing something like:
 
  In my Action.doExecute()
  ActionContext ac = new ActionContext(); 
  BeanUtil.setProperties(ac.getParameters(),new TestBean());
 
  TestBean has one property name.
 
  How do I access the name property using the ww taglibs?
 
  ww:property value=name/ doesn't seem to be hitting the bean. 
  ww:property value=$name/ does work, picking up the request 
  parameter directly.
 
  I thought maybe I had to name the object bean and then pass it in, 
  like TestBean tb = new TestBean(); and then pass in the tb 
 object and 
  do ww:property value=tb/name/ but that doesn't work either.
 
  I've been looking through the docs, but I cant find it. I 
 know I'm not 
  hitting the Bean on the view.
 
  Regards,
  -Andre Mermegas
 
 
 
 
 
 
  Regards,
  -Andre Mermegas
 
 
 
 
 
 
 
 ---
 This SF.NET email is sponsored by:
 SourceForge Enterprise Edition + IBM + LinuxWorld = Something 
 2 See! http://www.vasoftware.com 
 ___
 Opensymphony-webwork mailing list 
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
 


---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___

RE: [OS-webwork] Xwork 1.0 / Webwork 2.0 design session

2003-01-31 Thread Jason Carreira
Oops, forgot to list the time... I was thinking 2PM Eastern time Monday
2/3...

 -Original Message-
 From: Jason Carreira 
 Sent: Saturday, February 01, 2003 12:23 AM
 To: [EMAIL PROTECTED]
 Subject: [OS-webwork] Xwork 1.0 / Webwork 2.0 design session
 
 
 On the table is the ThreadLocal issue and how to re-introduce 
 it. The current Xwork code uses an ActionInvocation which is 
 passed to each of the interceptors and holds the state of the 
 request processing. In order to make Actions (more) backward 
 compatible in WW 2.0, we need to re-introduce the ThreadLocal 
 state management concept from WW 1.2/1.3. 
 
 Rickard, etc. let me know if this is a good time for you. 
 Anyone who plans to attend, please look through the sandbox 
 code first. If you have any other issues you'd like to 
 discuss, please post them to this list so people have time to 
 think about them beforehand.
 
 Patrick has suggested we do this on #xwork on irc.werken.com, 
 so that it can be logged at http://irc.werken.com/channels/.
 
 Jason
 
 --
 Jason Carreira
 Technical Architect, Notiva Corp.
 phone:585.240.2793
   fax:585.272.8118
 email:[EMAIL PROTECTED]
 ---
 Notiva - optimizing trade relationships (tm)
  
 
 
 ---
 This SF.NET email is sponsored by:
 SourceForge Enterprise Edition + IBM + LinuxWorld =omething 2 
 See! http://www.vasoftware.com 
 ___
 Opensymphony-webwork mailing list 
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
 


---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork