wrote:
> Regarding you second issue - my code looks slightly different and provides
> valid json representation back. Maybe this works for you as well.
> Actually I'm not creating the JSONRepresentation by myself but just
> provide pure Java Objects back. The JSON-serialization is then handled by
> restlet itself. I'm using the Jackson-extension.
> 

Thanks, but my JacksonRepresentation works fine. I just want to create some
small Json to send back some Error codes, or OAuth Tokens for example.


Jason Guild-2 wrote:
> 
> Hi Sebastian:
> 
> I am using JsonRepresentation and it works just fine.
> 
> Did you enable JSON by addding the variant in the constructor of your
> resource?
> getVariants().add(new Variant(MediaType.APPLICATION_JSON));
> 
> And maybe your annotation should be @Get("json") as well.
> 
> Hope that helps,
> Jason
> 
 
Tried adding the Annotation and overriding doInit()...nothing works. 
But at least i think i found what's causing the error:
In the ConverterUtils class the method getBestHelper(Object source, Variant
target,UniformResource resource) is called and hence the DefaultConverter is
used instead of the JsonConverter...
I think what should be called is getBestHelper(Representation
source,Class<T> target, UniformResource resource).
Don't know yet why it's called like this though.



--
View this message in context: 
http://restlet-discuss.1400322.n2.nabble.com/IncompatibleClassChangeError-with-ConcurrentMap-tp6393712p6451068.html
Sent from the Restlet Discuss mailing list archive at Nabble.com.

------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=2759647

Reply via email to