Re: [OS-webwork] Velocity Views

2003-02-07 Thread Rickard Öberg
Scott Farquhar wrote:

Rickard Öberg wrote:

He never said that he wasn't using the WebworkVelocityServlet. The 
method he describes is mostly just to get access to the action as a 
Velocity object. Otherwise it would be impossible to call methods, as 
he described.

I'm confused.  Isn't the action at the top of the valuestack after it is 
called?  so $abc calls action.getAbc() ?

Yeah, but if you want to do action.getAbc(foo) that is impossible (i.e. 
a parameterized call). The only way to do that is to have a getAction() 
method in the action so that you can do $action.getAbc(foo) in Velocity.

/Rickard

--
Rickard Öberg
[EMAIL PROTECTED]
Senselogic

Got blog? I do. http://dreambean.com



---
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] Action Properties & HttpSession

2003-02-07 Thread Andre Mermegas
That would be excellent.

Regards,
-Andre Mermegas
 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of
Rickard Öberg
Sent: Friday, February 07, 2003 3:49 AM
To: [EMAIL PROTECTED]
Subject: Re: [OS-webwork] Action Properties & HttpSession

Chris Nokleberg wrote:
>>I have an idea: how about adding an interface "Model" that has one 
>>method "Object getModel()". It would be implemented in ActionSupport
as:
>>public Object getModel() { return this; }
> 
> It is a good idea. Maverick does something similar, I think.
> 
> Might I suggest that the method be:
>Object model()
> 
> "getModel" makes it a property, which then becomes part of the model 
> itself.

hm.. IIRC model() is also a property (both "getModel" and "model" is 
tested if the "model" property is accessed.

*If* I recall correctly we might as well use getModel(), since it looks 
cleaner.

/Rickard

-- 
Rickard Öberg
[EMAIL PROTECTED]
Senselogic

Got blog? I do. http://dreambean.com



---
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



Re: [OS-webwork] Velocity Views

2003-02-07 Thread Scott Farquhar


Rickard Öberg wrote:

He never said that he wasn't using the WebworkVelocityServlet. The 
method he describes is mostly just to get access to the action as a 
Velocity object. Otherwise it would be impossible to call methods, as he 
described.

I'm confused.  Isn't the action at the top of the valuestack after it is 
called?  so $abc calls action.getAbc() ?

--

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


RE: [OS-webwork] where might info on this be?

2003-02-07 Thread Andre Mermegas
Ah k that’s what I thought. Thanks =)

Regards,
-Andre Mermegas
 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of
Jason Carreira
Sent: Friday, February 07, 2003 5:40 PM
To: [EMAIL PROTECTED]
Subject: RE: [OS-webwork] where might info on this be?

If you want to save things in the Session, you need to do it explicitly.
The ValueStack is only valid during one request / response cycle.

> -Original Message-
> From: Andre Mermegas [mailto:[EMAIL PROTECTED]] 
> Sent: Friday, February 07, 2003 2:23 PM
> To: [EMAIL PROTECTED]
> Subject: RE: [OS-webwork] where might info on this be?
> 
> 
> Hey all,
>  
> Is there a new value stack created for every view coming from 
> an Action? Or is it possible to back reference previous 
> Actions executed, basically what I'm getting at is the value 
> stack "session" like? If so how?
> 
> From my tests it doesn't seem to be, but I could be doing it wrong =)
> 
> Regards,
> -Andre Mermegas
> 
> 
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]] On 
> Behalf Of Mike Cannon-Brookes
> Sent: Monday, February 03, 2003 7:28 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [OS-webwork] where might info on this be?
> 
> Almost, but not quite. :)
> 
> RULES OF THE STACK:
> 
> 1) The stack is just a stack of objects.
> 
> 2) Initially the stack contains the Action executed (this is 
> why as you say value="foo" calls action.getFoo())
> 
> 3) New objects are placed onto the stack during the body of 
> various tags (like  or  for example)
> 
> 4) Using the expression language you can navigate UP the 
> stack (ie ../ to move up the stack, / to root an expression 
> from the top of the stack)
> 
> 5) Using the expression language you can navigate DOWN the 
> object graph from any point on the stack (ie / to move down 
> the object's methods)
> 
> 
> How is that for a brief primer? Should we put this on the 
> Wiki? Anyone have any other rules to add?
> 
> -mike
> 
> On 4/2/03 10:15 AM, "Andre Mermegas" ([EMAIL PROTECTED]) penned the
> words:
> 
> > Yeah, I've been looking at the wiki and saw that document, 
> it is very 
> > helpful for the syntax, thanks.
> > 
> > As far as the value stack goes, I've been thinking about it 
> a bit, and 
> > this is what I've come up with, The stack begins with whatever 
> > properties comes from the Action directly, so "errors" is a base 
> > property because it has a getter/setter in ActionSupport 
> and through 
> > inheritance my Action. As witnessed by:
> > 
> > 
> >  key=, value= > value="value"/> 
> > 
> > Anything attached to the Action say for instance a bean that has a 
> > getter/setter; its properties are not visible from the base of the
> stack
> > because the getters and setters for the beans properties are not in
> the
> > action but are in the bean, so to access them you must prefix the 
> > property value with objectName/propertyname.
> > 
> > As witenessed by:
> > name=
> > 
> > I think I get it now.
> > 
> > Regards,
> > -Andre Mermegas
> > 
> > 
> > -Original Message-
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED]] 
> On Behalf Of 
> > boxed
> > Sent: Monday, February 03, 2003 5:36 PM
> > To: [EMAIL PROTECTED]
> > Subject: Re: [OS-webwork] where might info on this be?
> > 
> >> 3.) A list of all possible views.properties entries like
> >> action.* what is available and what does it do. I'm aware of the
> basic
> > ones:
> >> foo.action, foo.success, foo.error, foo.none, foo.input, foo.login
> for
> >> having looked at the Action interface but are there any other
> > possible? I
> >> don't know.
> > 
> > The suffixes are just strings. An action returns a String, and that 
> > return value is what you map in the views.properties file. Nothing 
> > more, nothing
> > less.
> > 
> >> 2.) A good explanation of how exactly the value stack works,
> > 
> > The wiki has a reference:
> >
> http://www.opensymphony.com:8668/space/WebWork+Expression+Lang
> uage+Synta
> > x
> > 
> > Anders Hovmöller
> > [EMAIL PROTECTED] http://boxed.killingar.net
> > 
> > 
> > 
> > ---
> > 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

RE: [OS-webwork] where might info on this be?

2003-02-07 Thread Jason Carreira
If you want to save things in the Session, you need to do it explicitly. The 
ValueStack is only valid during one request / response cycle.

> -Original Message-
> From: Andre Mermegas [mailto:[EMAIL PROTECTED]] 
> Sent: Friday, February 07, 2003 2:23 PM
> To: [EMAIL PROTECTED]
> Subject: RE: [OS-webwork] where might info on this be?
> 
> 
> Hey all,
>  
> Is there a new value stack created for every view coming from 
> an Action? Or is it possible to back reference previous 
> Actions executed, basically what I'm getting at is the value 
> stack "session" like? If so how?
> 
> From my tests it doesn't seem to be, but I could be doing it wrong =)
> 
> Regards,
> -Andre Mermegas
> 
> 
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]] On 
> Behalf Of Mike Cannon-Brookes
> Sent: Monday, February 03, 2003 7:28 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [OS-webwork] where might info on this be?
> 
> Almost, but not quite. :)
> 
> RULES OF THE STACK:
> 
> 1) The stack is just a stack of objects.
> 
> 2) Initially the stack contains the Action executed (this is 
> why as you say value="foo" calls action.getFoo())
> 
> 3) New objects are placed onto the stack during the body of 
> various tags (like  or  for example)
> 
> 4) Using the expression language you can navigate UP the 
> stack (ie ../ to move up the stack, / to root an expression 
> from the top of the stack)
> 
> 5) Using the expression language you can navigate DOWN the 
> object graph from any point on the stack (ie / to move down 
> the object's methods)
> 
> 
> How is that for a brief primer? Should we put this on the 
> Wiki? Anyone have any other rules to add?
> 
> -mike
> 
> On 4/2/03 10:15 AM, "Andre Mermegas" ([EMAIL PROTECTED]) penned the
> words:
> 
> > Yeah, I've been looking at the wiki and saw that document, 
> it is very 
> > helpful for the syntax, thanks.
> > 
> > As far as the value stack goes, I've been thinking about it 
> a bit, and 
> > this is what I've come up with, The stack begins with whatever 
> > properties comes from the Action directly, so "errors" is a base 
> > property because it has a getter/setter in ActionSupport 
> and through 
> > inheritance my Action. As witnessed by:
> > 
> > 
> >  key=, value= > value="value"/> 
> > 
> > Anything attached to the Action say for instance a bean that has a 
> > getter/setter; its properties are not visible from the base of the
> stack
> > because the getters and setters for the beans properties are not in
> the
> > action but are in the bean, so to access them you must prefix the 
> > property value with objectName/propertyname.
> > 
> > As witenessed by:
> > name=
> > 
> > I think I get it now.
> > 
> > Regards,
> > -Andre Mermegas
> > 
> > 
> > -Original Message-
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED]] 
> On Behalf Of 
> > boxed
> > Sent: Monday, February 03, 2003 5:36 PM
> > To: [EMAIL PROTECTED]
> > Subject: Re: [OS-webwork] where might info on this be?
> > 
> >> 3.) A list of all possible views.properties entries like
> >> action.* what is available and what does it do. I'm aware of the
> basic
> > ones:
> >> foo.action, foo.success, foo.error, foo.none, foo.input, foo.login
> for
> >> having looked at the Action interface but are there any other
> > possible? I
> >> don't know.
> > 
> > The suffixes are just strings. An action returns a String, and that 
> > return value is what you map in the views.properties file. Nothing 
> > more, nothing
> > less.
> > 
> >> 2.) A good explanation of how exactly the value stack works,
> > 
> > The wiki has a reference:
> >
> http://www.opensymphony.com:8668/space/WebWork+Expression+Lang
> uage+Synta
> > x
> > 
> > Anders Hovmöller
> > [EMAIL PROTECTED] http://boxed.killingar.net
> > 
> > 
> > 
> > ---
> > 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 =omething 2 
> See! http://www.vasoftware.com 
> ___
> Opensymphony-webwork mailing list 
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
> 
> 
> 
> 
> 

Re: [OS-webwork] Action Properties & HttpSession

2003-02-07 Thread Chris Nokleberg
On Fri, Feb 07, 2003 at 09:49:20AM +0100, Rickard Öberg wrote:
> hm.. IIRC model() is also a property (both "getModel" and "model" is 
> tested if the "model" property is accessed.
> 
> *If* I recall correctly we might as well use getModel(), since it looks 
> cleaner.

According to the javabeans spec (1.0.1, section 8.3), you need the "get"
for it to be considered a property by the Introspector under normal
circumstances. "is" is allowed for boolean properties. You can customize
things through BeanInfo, of course.

-Chris



---
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] file ui tag for jsps

2003-02-07 Thread Jason Carreira
I just don't think anyone ever did it. I think it's a good idea.

> -Original Message-
> From: Justen Stepka [mailto:[EMAIL PROTECTED]] 
> Sent: Friday, February 07, 2003 4:31 PM
> To: [EMAIL PROTECTED]
> Subject: [OS-webwork] file ui tag for jsps
> 
> 
> Hey guys...
> 
> The time has come that I need to use the file upload features 
> of webwork and I'm wondering why there isn't a UI tag for file upload?
> 
> The case wishing such a feature existed is because I may want 
> to send the user back to the form with a status message of 
> "You must supply a filename" or something similar.
> 
> I'm pretty sure that I'll end up coding something to handle 
> this on my own, but is there a reason this doesn't existing 
> in the UI core?
> 
> Thanks,
> 
> Justen Stepka
> 
> 
> 
> ---
> 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] file ui tag for jsps

2003-02-07 Thread Justen Stepka
Hey guys...

The time has come that I need to use the file upload features of webwork and
I'm wondering why there isn't a UI tag for file upload?

The case wishing such a feature existed is because I may want to send the
user back to the form with a status message of "You must supply a filename"
or something similar.

I'm pretty sure that I'll end up coding something to handle this on my own,
but is there a reason this doesn't existing in the UI core?

Thanks,

Justen Stepka



---
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] ui:textfield id attribute is missing

2003-02-07 Thread Kirk Rasmussen



Awesome.  Thanks so much.  I think it just disappeared from the 
*.tld file from what I can tell.

  -Original Message-From: matt baldree 
  [mailto:[EMAIL PROTECTED]]Sent: Friday, February 07, 2003 6:40 
  AMTo: [EMAIL PROTECTED]Subject: 
  Re: [OS-webwork] ui:textfield id attribute is missing
  This should not have dropped out. I just noticed 
  this myself on our project as we were migrating. I'll make the appropriate 
  fixes for 1.3.
  
- Original Message - 
From: 
Kirk Rasmussen 
To: [EMAIL PROTECTED] 

Sent: Thursday, February 06, 2003 7:42 
PM
Subject: [OS-webwork] ui:textfield id 
attribute is missing

Does anyone know 
why the "id" attribute was removed from the ui tags?  

I now get the 
following runtime error:
 

unexpected 
attribute `id' in `ui:textfield'
 
This now became 
a very big issue with my migration from 1.2 to 1.3.  I'm willing to 
do
the work to put 
it back in but I was just curious on the reason (e.g. 
oversight).
 
Thanks,
Kirk 
Rasmussen
Lucasfilm 
Ltd.
 


RE: [OS-webwork] where might info on this be?

2003-02-07 Thread Andre Mermegas
Hey all,
 
Is there a new value stack created for every view coming from an Action?
Or is it possible to back reference previous Actions executed, basically
what I'm getting at is the value stack "session" like? If so how?

>From my tests it doesn’t seem to be, but I could be doing it wrong =)

Regards,
-Andre Mermegas


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of
Mike Cannon-Brookes
Sent: Monday, February 03, 2003 7:28 PM
To: [EMAIL PROTECTED]
Subject: Re: [OS-webwork] where might info on this be?

Almost, but not quite. :)

RULES OF THE STACK:

1) The stack is just a stack of objects.

2) Initially the stack contains the Action executed (this is why as you
say
value="foo" calls action.getFoo())

3) New objects are placed onto the stack during the body of various tags
(like  or  for example)

4) Using the expression language you can navigate UP the stack (ie ../
to
move up the stack, / to root an expression from the top of the stack)

5) Using the expression language you can navigate DOWN the object graph
from
any point on the stack (ie / to move down the object's methods)


How is that for a brief primer? Should we put this on the Wiki? Anyone
have
any other rules to add?

-mike

On 4/2/03 10:15 AM, "Andre Mermegas" ([EMAIL PROTECTED]) penned the
words:

> Yeah, I've been looking at the wiki and saw that document, it is very
> helpful for the syntax, thanks.
> 
> As far as the value stack goes, I've been thinking about it a bit, and
> this is what I've come up with, The stack begins with whatever
> properties comes from the Action directly, so "errors" is a base
> property because it has a getter/setter in ActionSupport and through
> inheritance my Action.
> As witnessed by:
> 
> 
>  key=, value= value="value"/>
> 
> 
> Anything attached to the Action say for instance a bean that has a
> getter/setter; its properties are not visible from the base of the
stack
> because the getters and setters for the beans properties are not in
the
> action but are in the bean, so to access them you must prefix the
> property value with objectName/propertyname.
> 
> As witenessed by:
> name=
> 
> I think I get it now.
> 
> Regards,
> -Andre Mermegas
> 
> 
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]] On Behalf Of
> boxed
> Sent: Monday, February 03, 2003 5:36 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [OS-webwork] where might info on this be?
> 
>> 3.) A list of all possible views.properties entries like
>> action.* what is available and what does it do. I'm aware of the
basic
> ones:
>> foo.action, foo.success, foo.error, foo.none, foo.input, foo.login
for
>> having looked at the Action interface but are there any other
> possible? I
>> don't know.
> 
> The suffixes are just strings. An action returns a String, and that
> return
> value is what you map in the views.properties file. Nothing more,
> nothing
> less.
> 
>> 2.) A good explanation of how exactly the value stack works,
> 
> The wiki has a reference:
>
http://www.opensymphony.com:8668/space/WebWork+Expression+Language+Synta
> x
> 
> Anders Hovmöller
> [EMAIL PROTECTED] http://boxed.killingar.net
> 
> 
> 
> ---
> 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 =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



Re: [OS-webwork] Action Properties & HttpSession

2003-02-07 Thread Patrick Lightbody
-1 on adding it in the base Action interface. The minimum level the core
XWork framework should do is execute(), that's it.

-Pat

- Original Message -
From: "Jason Carreira" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, February 07, 2003 6:07 AM
Subject: RE: [OS-webwork] Action Properties & HttpSession


> > -Original Message-
> > From: Rickard Öberg [mailto:[EMAIL PROTECTED]]
> >
> > I have an idea: how about adding an interface "Model" that has one
> > method "Object getModel()". It would be implemented in
> > ActionSupport as: public Object getModel() { return this; }
> >
> > However, for those cases where a separate bean is used (e.g. a value
> > object from EJB) it would be overriden by the action as:
> > public Object getModel() { return someModelBean; }
> >
> > When the dispatcher has executed an action and needs to
> > decide what to
> > put on the ValueStack it simply checks for the Model
> > interface and uses
> > it if available. If not available, then the action itself is used.
> >
> > This would be largely transparent, but would allow for easy
> > use of the
> > "form bean" concept in Struts. If you need it it's there, but the
> > default is that action=model.
> >
> > By using this one could avoid doing form names such as
> > "myBean/oneProperty" and simply use "oneProperty" instead, if the
> > getModel() method returns the model to be used both as "input" and as
> > "result".
> >
> > What say ye?
> >
> > /Rickard
>
> +1. Sounds good to me. I've added a Jira task to add this to WW2.0.
Speaking of which, can someone make it so people can comment on Jira Issues?
And maybe make it so I can assign things to myself?
>
> I'm thinking for WW2.0 this can be put directly into the Action Interface,
and have the default behavior described by Rickard in ActionSupport.
>
> Jason
>
>
> ---
> This SF.NET email is sponsored by:
> SourceForge Enterprise Edition + IBM + LinuxWorld
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] CVS access

2003-02-07 Thread Philipp Meier
On Fri, Feb 07, 2003 at 08:12:45AM -0800, Erik Beeson wrote:
> Why don't you send diffs to the list and a regular committer can add them.

Because I'm the mantainer of the XSLT view layer and I will surely
commit often. 

-billy.

-- 
Meisterbohne   Söflinger Straße 100  Tel: +49-731-399 499-0
   eLösungen   89077 Ulm Fax: +49-731-399 499-9



msg01684/pgp0.pgp
Description: PGP signature


Re: [OS-webwork] CVS access

2003-02-07 Thread Erik Beeson
Why don't you send diffs to the list and a regular committer can add them.

--Erik

On Fri, 7 Feb 2003, Philipp Meier wrote:

> could please someone re-grant cvs write access to me ("llucifer"). I
> have some important bug fixes for XSLTServlet that should go into 1.3
>
> -billy.
> --



---
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] CVS access

2003-02-07 Thread Philipp Meier
Hello,

could please someone re-grant cvs write access to me ("llucifer"). I
have some important bug fixes for XSLTServlet that should go into 1.3

-billy.
-- 
Meisterbohne   Söflinger Straße 100  Tel: +49-731-399 499-0
   eLösungen   89077 Ulm Fax: +49-731-399 499-9



msg01682/pgp0.pgp
Description: PGP signature


RE: [OS-webwork] Help needed with parametric action

2003-02-07 Thread Sebastiano Pilla
At 15.21 07/02/2003, Jason Carreira wrote:

Please post any details you have, and a sample app that shows the
problem, if possible.


Well, I have made some progress... Without changing the Java code (a class 
that extends ActionSupport and implements ApplicationAware and 
ParameterAware) I tried a different JSP approach.

I now have testblog.jsp and testblog2.jsp: the former includes the latter as



  
  



and testblog2.jsp is:

<%@ taglib uri="WebWorkTags" prefix="webwork" %>



With this arrangement, my BlogPostAction class can now see the parameters: 
the setParameters method gets called, and in the log I see:

[2003-02-07 16:38:44,457] DEBUG com.datafaber.action.content.BlogPostAction 
content.BlogPostAction - Action executing..
[2003-02-07 16:38:44,457] DEBUG com.datafaber.action.content.BlogPostAction 
content.BlogPostAction - doExecute - mParameters = 
{lowerBoundDay=[Ljava.lang.String;@50d45b, 
upperBoundDay=[Ljava.lang.String;@49105b}
[2003-02-07 16:38:44,467] DEBUG com.datafaber.action.content.BlogPostAction 
content.BlogPostAction - v = [3]
[2003-02-07 16:38:44,467] DEBUG com.datafaber.action.content.BlogPostAction 
content.BlogPostAction - v = [-1]
[2003-02-07 16:38:44,807] DEBUG com.datafaber.action.content.BlogPostAction 
content.BlogPostAction - doExecute - result = []
[2003-02-07 16:38:44,807] DEBUG com.datafaber.action.content.BlogPostAction 
content.BlogPostAction - Action execution done
[2003-02-07 16:38:44,807] DEBUG com.datafaber.action.content.BlogPostAction 
content.BlogPostAction - Action executed in 350 ms

The mParameters variable is set in the setParameters() method of 
BlogPostAction, of course.

So, in the end I'm happy that I got it to work, but I still feel I do not 
understand WebWork as much as I'd like. I thought that I could pass 
parameters to actions via the param tag, and obviously it appears that I 
was wrong. Could someone enlighten me as to why the following syntax does 
not work as I originally thought?

<%@ taglib uri="WebWorkTags" prefix="webwork" %>

  
  


Dunno if it matters, the setup I'm currently running is WebWork 1.2.1 and 
Tomcat 4.1.12.

Regards

Sebastiano Pilla
E-TREE S.p.a.  Via Fonderia 43 - 31100 Treviso (Italy)
phone +39.0422.3107  fax   +39.0422.310888
http://www.e-tree.com  http://www.webanana.com



---
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] Action Properties & HttpSession

2003-02-07 Thread Rickard Öberg
Dick Zetterberg wrote:

By using this one could avoid doing form names such as
"myBean/oneProperty" and simply use "oneProperty" instead, if the
getModel() method returns the model to be used both as "input" and as
"result".


But if your bean contains other beans then you still have to use names like
"otherBean/newProperty", and if you today use several beans in your action
you would have to create a wrapper class for them to use as the model
(instead of just adding a get method for each bean in the action).


In that case you could continue to use the action as the "wrapper".


So I do not see a very big practical advantage with the proposed addition.


For the cases you mention, sure. But there's quite a number of cases 
where only one bean is being used as input/output and for that case it 
becomes much cleaner.

However, I am not "against" it if you find it useful, as long as the old way
of doing it still works.


As I noted the default would be that it works exactly like today.

/Rickard

--
Rickard Öberg
[EMAIL PROTECTED]
Senselogic

Got blog? I do. http://dreambean.com



---
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] Action Properties & HttpSession

2003-02-07 Thread Dick Zetterberg
- Original Message -
From: "Rickard Öberg" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, February 07, 2003 9:19 AM
Subject: Re: [OS-webwork] Action Properties & HttpSession


>
> By using this one could avoid doing form names such as
> "myBean/oneProperty" and simply use "oneProperty" instead, if the
> getModel() method returns the model to be used both as "input" and as
> "result".

But if your bean contains other beans then you still have to use names like
"otherBean/newProperty", and if you today use several beans in your action
you would have to create a wrapper class for them to use as the model
(instead of just adding a get method for each bean in the action).
So I do not see a very big practical advantage with the proposed addition.
However, I am not "against" it if you find it useful, as long as the old way
of doing it still works.

Cheers,

Dick

[EMAIL PROTECTED]





---
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] ui:textfield id attribute is missing

2003-02-07 Thread matt baldree



This should not have dropped out. I just noticed 
this myself on our project as we were migrating. I'll make the appropriate fixes 
for 1.3.

  - Original Message - 
  From: 
  Kirk Rasmussen 
  To: [EMAIL PROTECTED] 
  
  Sent: Thursday, February 06, 2003 7:42 
  PM
  Subject: [OS-webwork] ui:textfield id 
  attribute is missing
  
  Does anyone know 
  why the "id" attribute was removed from the ui tags?  

  I now get the 
  following runtime error:
   
  
  unexpected 
  attribute `id' in `ui:textfield'
   
  This now became a 
  very big issue with my migration from 1.2 to 1.3.  I'm willing to 
  do
  the work to put it 
  back in but I was just curious on the reason (e.g. 
  oversight).
   
  Thanks,
  Kirk 
  Rasmussen
  Lucasfilm 
  Ltd.
   


RE: [OS-webwork] Help needed with parametric action

2003-02-07 Thread Jason Carreira
Please post any details you have, and a sample app that shows the
problem, if possible.

> -Original Message-
> From: Sebastiano Pilla [mailto:[EMAIL PROTECTED]] 
> Sent: Friday, February 07, 2003 9:22 AM
> To: [EMAIL PROTECTED]
> Subject: RE: [OS-webwork] Help needed with parametric action
> 
> 
> At 15.09 07/02/2003, Jason Carreira wrote:
> >Did you ever get this resolved?
> 
> No, unfortunately I haven't... Problem is, I can't seem to be able to 
> pinpoint the exact problem, not even after a good night's sleep. I'm 
> reasonably sure it's my fault, but I haven't got a clue.
> 
> > > However, the Map object passed to setParameters is empty!
> 
> Sebastiano Pilla
> E-TREE S.p.a.  Via Fonderia 43 - 31100 Treviso (Italy)
> phone +39.0422.3107  fax   +39.0422.310888
> http://www.e-tree.com  http://www.webanana.com
> 
> 
> 
> ---
> 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] Followup to the IRC meeting: ThreadLocal impl

2003-02-07 Thread Jason Carreira
> -Original Message-
> From: Rickard Öberg [mailto:[EMAIL PROTECTED]] 
> 
> The context is set by the dispatcher:
> * Set context
> * Create action
> * Invoke action (which may invoke other actions)

I've checked this into the sandbox. It doesn't work exactly like this as I've checked 
it in. Instead, the ActionContext is created and set during the init() of the 
ActionInvocation. This allows the Dispatcher to be VERY simple. All it needs to do is 
create a new ActionInvocation with the Action name and (optional) namespace, and then 
invoke() it. 

Patrick checked in some mods last night to what I did to make action chaining work by 
saving out and passing on the ValueStack to the next ActionInvocation (and 
corresponding ActionContext).

Check out the sandbox and feel free to comment.

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] Help needed with parametric action

2003-02-07 Thread Sebastiano Pilla
At 15.09 07/02/2003, Jason Carreira wrote:

Did you ever get this resolved?


No, unfortunately I haven't... Problem is, I can't seem to be able to 
pinpoint the exact problem, not even after a good night's sleep. I'm 
reasonably sure it's my fault, but I haven't got a clue.

> However, the Map object passed to setParameters is empty!


Sebastiano Pilla
E-TREE S.p.a.  Via Fonderia 43 - 31100 Treviso (Italy)
phone +39.0422.3107  fax   +39.0422.310888
http://www.e-tree.com  http://www.webanana.com



---
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] Action Properties & HttpSession

2003-02-07 Thread Jason Carreira
> -Original Message-
> From: Rickard Öberg [mailto:[EMAIL PROTECTED]] 
> 
> I have an idea: how about adding an interface "Model" that has one 
> method "Object getModel()". It would be implemented in 
> ActionSupport as: public Object getModel() { return this; }
> 
> However, for those cases where a separate bean is used (e.g. a value 
> object from EJB) it would be overriden by the action as:
> public Object getModel() { return someModelBean; }
> 
> When the dispatcher has executed an action and needs to 
> decide what to 
> put on the ValueStack it simply checks for the Model 
> interface and uses 
> it if available. If not available, then the action itself is used.
> 
> This would be largely transparent, but would allow for easy 
> use of the 
> "form bean" concept in Struts. If you need it it's there, but the 
> default is that action=model.
> 
> By using this one could avoid doing form names such as 
> "myBean/oneProperty" and simply use "oneProperty" instead, if the 
> getModel() method returns the model to be used both as "input" and as 
> "result".
> 
> What say ye?
> 
> /Rickard

+1. Sounds good to me. I've added a Jira task to add this to WW2.0. Speaking of which, 
+can someone make it so people can comment on Jira Issues? And maybe make it so I can 
+assign things to myself? 

I'm thinking for WW2.0 this can be put directly into the Action Interface, and have 
the default behavior described by Rickard in ActionSupport.

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] Help needed with parametric action

2003-02-07 Thread Jason Carreira
Did you ever get this resolved?

> -Original Message-
> From: Sebastiano Pilla [mailto:[EMAIL PROTECTED]] 
> Sent: Thursday, February 06, 2003 11:04 AM
> To: [EMAIL PROTECTED]
> Subject: [OS-webwork] Help needed with parametric action
> 
> 
> Greetings,
> 
> I'm having some troubles when trying to pass parameters to one of my 
> actions and I'm stumped: I believe I must be missing something 
> embarassingly simple, but it appears I'm too dumb to figure 
> it out for 
> myself...
> 
> The problem: I have a class that extends ActionSupport and 
> implements both 
> ApplicationAware and ParameterAware, but the setParameters 
> method always 
> receives an empty map...
> 
> I call this action in a JSP page in this way:
> 
> <%@ taglib uri="WebWorkTags" prefix="webwork" %> 
> 
>
> 
> 
> 
> I've placed some logging calls in doExecute() and 
> setParameters(), and 
> they're both called as I expect:
> 
> [2003-02-06 16:51:44,822] DEBUG 
> com.datafaber.action.content.BlogPostAction  - setParameters 
> - pParameters = {} [2003-02-06 16:51:44,952] DEBUG 
> com.datafaber.action.content.BlogPostAction 
> content.BlogPostAction - Action executing..
> [2003-02-06 16:51:44,962] DEBUG 
> com.datafaber.action.content.BlogPostAction 
> content.BlogPostAction - doExecute - mParameters = {}
> 
> However, the Map object passed to setParameters is empty!
> 
> What I'm doing wrong? Am I using an incorrect syntax in my JSP? Am I 
> totally off-base here and should be doing this in an entirely 
> different way?
> 
> Thanks for any help.
> 
> Sebastiano Pilla
> E-TREE S.p.a.  Via Fonderia 43 - 31100 Treviso (Italy)
> phone +39.0422.3107  fax   +39.0422.310888
> http://www.e-tree.com  http://www.webanana.com
> 
> 
> 
> ---
> 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] Velocity Views

2003-02-07 Thread Rickard Öberg
Scott Farquhar wrote:

What advantage does this have over the included WebworkVelocityServlet?


He never said that he wasn't using the WebworkVelocityServlet. The 
method he describes is mostly just to get access to the action as a 
Velocity object. Otherwise it would be impossible to call methods, as he 
described.

/Rickard

--
Rickard Öberg
[EMAIL PROTECTED]
Senselogic

Got blog? I do. http://dreambean.com



---
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] Velocity Views

2003-02-07 Thread Scott Farquhar
What advantage does this have over the included WebworkVelocityServlet?

In this model, you don't have access to the valuestack?

Cheers,
Scott

Marco Papini wrote:

I'm actually using Velocity for everything.
For data retrieving, I created a generic Action class (that extends 
ActionSupport) which is extended by all actions.
I've placed a getAction() method that returns the action itself so it 
can be accessed from the velocity template as $action.
For instance, if I need to retrieve a particular user I'll put:

#set($aUser = $action.getUser($userId))

Hope this can be of any help.

Kelvin Tan wrote:

Thanks. Thought as much...

I'm guessing most WW users don't use Velocity?

KT





--

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



Re: [OS-webwork] XSLTServlet not woking when included (patch)

2003-02-07 Thread Scott Farquhar
Is there a link to Jira from the opensymphony.com page?


Yes - the top right hand images, next to "SourceForge".



--

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



RE: [OS-webwork] XSLTServlet not woking when included (patch)

2003-02-07 Thread Jason Carreira
Please add this as a bug in Jira:

http://jira.opensymphony.com/secure/BrowseProject.jspa?id=10030

Is there a link to Jira from the opensymphony.com page?

> -Original Message-
> From: Peter Antman [mailto:[EMAIL PROTECTED]] 
> Sent: Friday, February 07, 2003 4:13 AM
> To: [EMAIL PROTECTED]
> Subject: [OS-webwork] XSLTServlet not woking when included (patch)
> 
> 
> Hi, I could not find a place to submit patches so I try this way:
> 
> I have been trying to include the outpout from an action with 
> an XSLT view in a jsp -page. At least on Jetty this does 
> currently not work: the XSLTServlet is invoked; but when it 
> tries to get the xslt-file but
> getServletPath() it instead receives the name of the original 
> JSP page it was included from. 
> 
> By checking if javax.servlet.include.servlet_path is 
> available this is possible to fix. Here is a new version of 
> getTemplates() that fixes the problem (i.e makes it possible 
> to inlucde actions with xslt-views from
> jsp):
> 
>protected Templates getTemplates(HttpServletRequest request)
>   throws TransformerException, java.io.IOException {
>   String uri = (String)
>  request.getAttribute("javax.servlet.include.servlet_path");
>   if ( uri == null) {
>  uri = request.getServletPath();
>   } 
>   
>   String   path = getServletContext().getRealPath(uri);
>   if (path == null) {
>  throw new TransformerException("Stylesheet " + path 
> + " not found");
>   }
>   
>   Templates templates = (Templates) templatesCache.get(path);
>   if (templates == null) {
>  synchronized (templatesCache) {
> // This may result in the template being put into 
> the cache multiple times
> // if concurrent requests are made, but that's ok.
> log.debug("Preparing new XSLT stylesheet: " + path);
> TransformerFactory factory = 
> TransformerFactory.newInstance();
> templates = factory.newTemplates(new 
> StreamSource(new File(path)));
> templatesCache.put(path, templates);
>  }
>   }
>   return templates;
>}
> 
> //Peter
> -- 
> 
> Peter Antman  Chief Technology Officer, Development
> Technology in Media, Box 34105 100 26 Stockholm
> WWW: http://www.tim.seWWW: http://www.backsource.org
> Email: [EMAIL PROTECTED]  
> Phone: +46-(0)8-506 381 11 Mobile: +46-(0)704 20 58 11
> 
> 
> 
> 
> ---
> 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] Action Properties & HttpSession

2003-02-07 Thread Simon Stewart

On Friday, Feb 7, 2003, at 08:49 Europe/London, Rickard Öberg wrote:


hm.. IIRC model() is also a property (both "getModel" and "model" is 
tested if the "model" property is accessed.

*If* I recall correctly we might as well use getModel(), since it 
looks cleaner.

exposeModel() perhaps? Or fetchModel()?

Regards,

Simon



---
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] XSLTServlet not woking when included (patch)

2003-02-07 Thread Peter Antman
Hi, I could not find a place to submit patches so I try this way:

I have been trying to include the outpout from an action with an XSLT
view in a jsp -page. At least on Jetty this does currently not work: the
XSLTServlet is invoked; but when it tries to get the xslt-file but
getServletPath() it instead receives the name of the original JSP page
it was included from. 

By checking if javax.servlet.include.servlet_path is available this is
possible to fix. Here is a new version of getTemplates() that fixes the
problem (i.e makes it possible to inlucde actions with xslt-views from
jsp):

   protected Templates getTemplates(HttpServletRequest request)
  throws TransformerException, java.io.IOException {
  String uri = (String)
 request.getAttribute("javax.servlet.include.servlet_path");
  if ( uri == null) {
 uri = request.getServletPath();
  } 
  
  String   path = getServletContext().getRealPath(uri);
  if (path == null) {
 throw new TransformerException("Stylesheet " + path + " not
found");
  }
  
  Templates templates = (Templates) templatesCache.get(path);
  if (templates == null) {
 synchronized (templatesCache) {
// This may result in the template being put into the cache
multiple times
// if concurrent requests are made, but that's ok.
log.debug("Preparing new XSLT stylesheet: " + path);
TransformerFactory factory =
TransformerFactory.newInstance();
templates = factory.newTemplates(new StreamSource(new
File(path)));
templatesCache.put(path, templates);
 }
  }
  return templates;
   }

//Peter
-- 

Peter AntmanChief Technology Officer, Development
Technology in Media, Box 34105 100 26 Stockholm
WWW: http://www.tim.se  WWW: http://www.backsource.org
Email: [EMAIL PROTECTED]
Phone: +46-(0)8-506 381 11 Mobile: +46-(0)704 20 58 11




---
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] Velocity Views

2003-02-07 Thread Marco Papini
I'm actually using Velocity for everything.
For data retrieving, I created a generic Action class (that extends 
ActionSupport) which is extended by all actions.
I've placed a getAction() method that returns the action itself so it 
can be accessed from the velocity template as $action.
For instance, if I need to retrieve a particular user I'll put:

#set($aUser = $action.getUser($userId))

Hope this can be of any help.

Kelvin Tan wrote:
Thanks. Thought as much...

I'm guessing most WW users don't use Velocity?

KT


--

Marco Papini



---
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] Action Properties & HttpSession

2003-02-07 Thread boxed
> I have an idea: how about adding an interface "Model" that has one
> method "Object getModel()". It would be implemented in ActionSupport as:
> public Object getModel() { return this; }

The only beef I have with this is that this prohibits you from having a
property "model" in the action. Having a little more obscure name would
probably do to fix this, but we should consider not having get* syntax on
this method. Other than that it sounds like a great idea.

// Anders Hovmöller



---
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] Velocity Views

2003-02-07 Thread Joseph Ottinger
On Fri, 7 Feb 2003, Kelvin Tan wrote:

> Interesting.
>
> I happen to come from the Turbine + hardcore Velocity (JSP sucks,
> mostly) camp, so would be interested to know why you choose JSP + Velocity, and
> not either. 

> Does it have anything to do with WebWork support for either?

Probably has something to do with view neutrality and the fact that
WebWork is a COMPONENT and not a way to force people into doing things in
ONE WAY and ONE WAY only. Come on, man, think. If you're going to troll,
try harder. Even Struts is view-neutral (for the most part).

-
Joseph B. Ottinger [EMAIL PROTECTED]
http://enigmastation.comIT Consultant



---
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] Action Properties & HttpSession

2003-02-07 Thread Rickard Öberg
Chris Nokleberg wrote:

I have an idea: how about adding an interface "Model" that has one 
method "Object getModel()". It would be implemented in ActionSupport as:
public Object getModel() { return this; }

It is a good idea. Maverick does something similar, I think.

Might I suggest that the method be:
   Object model()

"getModel" makes it a property, which then becomes part of the model 
itself.

hm.. IIRC model() is also a property (both "getModel" and "model" is 
tested if the "model" property is accessed.

*If* I recall correctly we might as well use getModel(), since it looks 
cleaner.

/Rickard

--
Rickard Öberg
[EMAIL PROTECTED]
Senselogic

Got blog? I do. http://dreambean.com



---
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] Commons Jelly

2003-02-07 Thread Joseph Ottinger
Depends on the use. I don't think there'd be a problem eventually allowing
Jelly's use, but depending on Jelly would be a Bad Thing.

On Fri, 7 Feb 2003, Kelvin Tan wrote:

> Did a search in the archives and didn't find anything noteworthy re: WW +
> Jelly, so thought I'd bring it up.
>
> Has this been discussed before? Perhaps not just using it as "another view",
> but in a more integrated fashion, ala OGNL and the current EL? After all, Jelly
> has a large collection of existing taglibs, and support for JEXL...
>
> Regards,
> Kelvin
>
> 
> The book giving manifesto - http://how.to/sharethisbook
>
>
>
>
> ---
> This SF.NET email is sponsored by:
> SourceForge Enterprise Edition + IBM + LinuxWorld http://www.vasoftware.com
> ___
> Opensymphony-webwork mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
>

-
Joseph B. Ottinger [EMAIL PROTECTED]
http://enigmastation.comIT Consultant



---
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] Action Properties & HttpSession

2003-02-07 Thread Chris Nokleberg
On Fri, Feb 07, 2003 at 09:19:07AM +0100, Rickard Öberg wrote:
> I have an idea: how about adding an interface "Model" that has one 
> method "Object getModel()". It would be implemented in ActionSupport as:
> public Object getModel() { return this; }

It is a good idea. Maverick does something similar, I think.

Might I suggest that the method be:
   Object model()

"getModel" makes it a property, which then becomes part of the model 
itself.

-Chris


---
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] Action Properties & HttpSession

2003-02-07 Thread Rickard Öberg
Dick Zetterberg wrote:

Hi Andre,
Putting the properties in its own bean would work fine. However when you
write that you would do this "via BeanUtils", I suspect that you mean you
would write your own code for this using "BeanUtil.setProperties"?
(I know there is one example doing that). Just so you know, you do not have
to do that manually. You can let WW do it for you. Just set the names to
something like "myBean/oneProperty", for example:

That would be similar to:   myAction.getMyBean().setOneProperty("abc");


This touches upon an interesting issue. The above exposes a little too 
much about the implementation of the action, really.

I have an idea: how about adding an interface "Model" that has one 
method "Object getModel()". It would be implemented in ActionSupport as:
public Object getModel() { return this; }

However, for those cases where a separate bean is used (e.g. a value 
object from EJB) it would be overriden by the action as:
public Object getModel() { return someModelBean; }

When the dispatcher has executed an action and needs to decide what to 
put on the ValueStack it simply checks for the Model interface and uses 
it if available. If not available, then the action itself is used.

This would be largely transparent, but would allow for easy use of the 
"form bean" concept in Struts. If you need it it's there, but the 
default is that action=model.

By using this one could avoid doing form names such as 
"myBean/oneProperty" and simply use "oneProperty" instead, if the 
getModel() method returns the model to be used both as "input" and as 
"result".

What say ye?

/Rickard

--
Rickard Öberg
[EMAIL PROTECTED]
Senselogic

Got blog? I do. http://dreambean.com



---
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] Action Properties & HttpSession

2003-02-07 Thread Dick Zetterberg

- Original Message -
From: Andre Mermegas
To: [EMAIL PROTECTED]

1.) An action has 10 properties on it; I want these properties to be
available for the life of the HttpSession for other views to use, and I want
them accessible in a beanlike manner, In order to accomplish this I have to
do the following as far as I can tell.
Write a bean that has the same property code basically as inside the action;
populate it with the info from the action's properties.
Place that bean into the HttpSession inside my action, and proceed

This feels very kludgey to me, so I must be thinking incorrectly.

My question is there a better way to do this? The only thing I can think of
is to not have the properties on the Action, but in its own bean to begin
with via Beanutils, and then add that to the session.


Hi Andre,
Putting the properties in its own bean would work fine. However when you
write that you would do this "via BeanUtils", I suspect that you mean you
would write your own code for this using "BeanUtil.setProperties"?
(I know there is one example doing that). Just so you know, you do not have
to do that manually. You can let WW do it for you. Just set the names to
something like "myBean/oneProperty", for example:

That would be similar to:   myAction.getMyBean().setOneProperty("abc");

Cheers,

Dick

[EMAIL PROTECTED]






---
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] Irc.werken.com

2003-02-07 Thread Peter Kelley
We did discuss migration at some length and the consensus seemed to be
that we would attempt to maintain compatibility with 1.3 where possible
but that for compelling new features that there would be some migration
required. In particular the areas of config files and expression
language were discussed.

The expression language discussion became fairly convoluted so I'll
attempt to give you my recollection from about 2 in the morning. Others
may jump in and correct me.

The expression language syntax will be changing to the OGNL syntax
although this is not a radical change. In particular foo/bar will become
foo.bar and the .. construct becomes something else weird. The intention
was to provide some sort of migration tool either at runtime so old
pages/templates/reports would work or as a static once off conversion
tool.

The release date for webwork on top of xwork (2 products) was estimated
at somewhere between 3 and 6 months from now with strong interest in
making it 3 months and not 6.

Obviously the choice is up to you but I would say that the migration
effort shouldn't be too onerous.



On Fri, 2003-02-07 at 13:01, Kelvin Tan wrote:
> Uh, this question is obviously pre-mature, but I can't keep it down.
> 
> Is there any indication of a proposed date for initial release for xwork? 
> What's the recommendation for someone planning to start using webwork? hold out 
> for xwork, or jump in and use webwork as it is now and look to migrate (faint!) 
> later? In other words, was there any mention of backwards compatibility and/or 
> migration path...
> 
> KT
> 

-- 
Peter Kelley <[EMAIL PROTECTED]>
Moveit Pty Ltd



---
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