users@jersey.java.net

Demoing Scala+Lift templates with Jersey <was> Re: [Jersey] is there a way to get hold of the resource bean from inside a MessageBodyWriter? (and Lift templates are kinda working...)

From: Paul Sandoz <Paul.Sandoz_at_Sun.COM>
Date: Mon, 18 May 2009 14:44:41 +0200

Hi James,

I am looking to demo some cutting edge stuff for the Jersey BOF @ J1,
do you think a demo of your Lift integration work is possible?

Paul.

On May 15, 2009, at 12:56 PM, James Strachan wrote:

> 2009/5/15 Paul Sandoz <Paul.Sandoz_at_sun.com>:
>> Hi James,
>>
>> I just re-read your email and the requirements are a little
>> different that i
>> originally thought, namely you want the last matching instance of the
>> resource class for a number of different scenarios.
>>
>> You can inject UriInfo and call:
>>
>> UriInfo.getMatchedResources()
>>
>> the first item in the returned list will be the last matching
>> resource class
>> instance i.e. the one that returned a response. But be carefuly in
>> some
>> cases there will be no matching resources, for example if an
>> exception
>> mapper gets invoked e.g. because a filter throws an exception and
>> the mapper
>> creates a response with a Node instance.
>
> Awesome thanks - works a treat!
>
> --
> James
> -------
> http://macstrac.blogspot.com/
>
> Open Source Integration
> http://fusesource.com/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>