users@jersey.java.net

[Jersey] Re: Injecting MultivaluedMap<String, String> with form data in @Provider

From: George Sapountzis <gsapountzis_at_gmail.com>
Date: Sun, 18 Mar 2012 19:23:28 +0200

check:

https://github.com/gsapountzis/samson/
https://github.com/gsapountzis/samson/blob/master/samson-jersey/src/main/java/samson/jersey/FormBeanProvider.java

hth,
george

On Sun, Mar 18, 2012 at 5:11 PM, Martynas Jusevicius
<martynas_at_graphity.org> wrote:
> Hey list,
>
> I'm implementing a MessageBodyReader to read form data from POST request:
>
> @Provider
> @Consumes(MediaType.APPLICATION_FORM_URLENCODED)
> public class RDFPostReader implements MessageBodyReader<Model>
>
> However, the processing would be much easier if I already had
> MultivaluedMap<String, String> with form's keys/values at hand. Is it
> possible to inject/access the map within the Provider somehow?
>
> Thanks,
>
> Martynas
> graphity.org