struts2 annotations

2010-09-05 Thread Daniel Rindt
Hello,

i am using struts2-core 2.2.1 via maven2 in my project. My problem is,
that i can't find the annotations. The installation of the package
struts2-annotations 1.0.5 doesn't help.
Where can i use the annotations again?

Thanks for reading, understanding, answering ;-)
Daniel


signature.asc
Description: This is a digitally signed message part


Re: struts2 annotations

2010-09-05 Thread Vinicius Ferraz
Whats the annotation do you want?  Result, Results?

include convention plugin in pom.xml

Vinícius Ferraz Campos Florentino
https://sites.google.com/site/viniciusferraz/
Stefanini IT Solutions - Desenvolvedor Java
CAIXA - Analista Júnior.
(061) 8147-6464


On Sun, Sep 5, 2010 at 2:13 PM, Daniel Rindt dri...@visetics.com wrote:

 Hello,

 i am using struts2-core 2.2.1 via maven2 in my project. My problem is,
 that i can't find the annotations. The installation of the package
 struts2-annotations 1.0.5 doesn't help.
 Where can i use the annotations again?

 Thanks for reading, understanding, answering ;-)
 Daniel



Re: How do I get wibble[0][something]=blah to parse into an action?

2010-09-05 Thread Rahul Mohan
Hi Andy,

This seems to be a problem with S2. ( See: 
http://struts-2.464677.n5.nabble.com/Ognl-problem-td1672158.html#a1672158 
and http://www.mail-archive.com/user@struts.apache.org/msg96386.html ). I 
struggled with this for some time but finally went ahead with a 
work-around - changed the listmap to a list of a new container class 
which has the map in it (see code below).

private ListRowData; 

class RowData {
 private MapString,Object cellData;
}

- Rahul



From:
Andy Chapman andrew.chap...@brighterworking.com
To:
user@struts.apache.org
Date:
04-09-2010 06:29
Subject:
How do I get wibble[0][something]=blah to parse into an action?



  I've got a 3rd party javascript tool that posts parameters like:

wibble[0][something] = /babble
wibble[0][foo] = 3
wibble[0][bar] = seventeen
wibble[1][something] = /bloop
wibble[1][foo] = 12
wibble[1][bar] = Only on Wednesdays

I can't figure out how to get the ParametersInterceptor to put the 
values it into my setter.
I've tried all sorts of things, but the [something] is failing to get 
through. My best effort was something like this,

public MyActionClass extends ActionSupport {

 ArrayListMapString, String wibble = null;

...execute etc. don't really matter...

 public ArrayListMapString, String getWibble() {
 if (this.wibble==null) {
 this.wibble = new ArrayListMapString, String();
 }
 return this.wibble;
 }

 public void setWibble(ArrayListMapString, String wibble) {
 this.wibble = wibble;
 }
}

In debug I can see the struts2 innards calling getWibble for each post 
parameter and creating the 0'th or 1'th element of the ArrayList but 
then it seems to resolve [something] by looking for a property or method 
(setSomething?) on the MyActionClass instance in the context rather than 
the ArrayList instance it got previously (which never goes into the 
context).

Obviously, I can make the action RequestAware and parse out the 
parameters myself or write/extend an interceptor, but it would be nice 
to have the base ParameterInterceptor and OGNL do it .

Any ideas?

-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org



=-=-=
Notice: The information contained in this e-mail
message and/or attachments to it may contain 
confidential or privileged information. If you are 
not the intended recipient, any dissemination, use, 
review, distribution, printing or copying of the 
information contained in this e-mail message 
and/or attachments to it are strictly prohibited. If 
you have received this communication in error, 
please notify us by reply e-mail or telephone and 
immediately and permanently delete the message 
and any attachments. Thank you




Re: struts2 annotations

2010-09-05 Thread Hantsy Bai

 于 2010/9/6 1:13, Daniel Rindt 写道:

Hello,

i am using struts2-core 2.2.1 via maven2 in my project. My problem is,
that i can't find the annotations. The installation of the package
struts2-annotations 1.0.5 doesn't help.
Where can i use the annotations again?

Thanks for reading, understanding, answering ;-)
Daniel

Use convention plugin[1] please, it is shipped with struts2 dist package.

[1]https://cwiki.apache.org/confluence/display/WW/Convention%20Plugin

Regards

Hantsy


-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org