struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alex Coles" <alex.co...@gmail.com>
Subject Re: json-plugin and Annotations (OR, implementations of Result that DO not inherit from StrutsResultSupport)
Date Sun, 12 Oct 2008 03:29:56 GMT
Hi Wes,

Thanks for your response!

On Sun, Oct 12, 2008 at 5:15 AM, Wes Wannemacher <wesw@wantii.com> wrote:
> It's funny that you happened to ask this tonight, I am working on a JSON
> result with annotations as I am writing this...
>
> First off, are you using a plugin to provide the annotations? If so,
> which one. I am using struts-2.1.3-snapshot (which might make a
> difference) in conjunction with the conventions plugin.

Sorry, I don't understand what you mean by using a plugin to provide
the annotations?

I am using several different Result types, most of which I wrote
myself. However, in the case of JSON, I went with the json-plugin
here: http://cwiki.apache.org/S2PLUGINS/json-plugin.html

> I have an action with the following annotation and it is working fine
> for me -
>
> @Action(results={@Result(name="success",type="json")})
>

If I ommit the value = "" parameter from my @Result annotation, then I
am getting a java.lang.annotation.IncompleteAnnotationException:
org.apache.struts2.config.Result missing element value

I am using Struts 2.1.2, and not 2.1.3-SNAPSHOT. Perhaps something
changed along the way?

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


Mime
View raw message