Hi

UUID has a static fromString(String) method. I'll update the JAXRS runtime to check for static fromString(String) in addition to valueOf(String)...
Adding ParameterHandlers extensions would be useful too, so that one can register 
ParameterHandler<Foo>, ParameterHandler<Bar>, etc

Cheers, Sergey

----- Original Message ----- From: "Vishal.a" <[email protected]>
To: <[email protected]>
Sent: Wednesday, January 07, 2009 5:09 PM
Subject: Re: MessageBodyReader For UUID



Thanks Ian.
Is there any other way i can make the use of UUID?



ianroberts wrote:

Vishal.a wrote:
Hello,

I have created a rest service which takes UUID as one of the parameters

@GET
@Path("/person/{id}")
public Person getPerson(@PathParam("id")UUID id);

I have also written a MessageBodyReader  for the UUID

MessageBodyReaders are only for reading the message body, they're not
used for PathParams.

PathParams can be any type with a constructor taking a String or with a
valueOf(String) method - UUID has neither, so I guess your only option
is to have a parameter of type String and do UUID.fromString in the body
of your method.

Ian

--
Ian Roberts               | Department of Computer Science
[email protected]  | University of Sheffield, UK



--
View this message in context: 
http://www.nabble.com/MessageBodyReader-For-UUID-tp21319272p21335914.html
Sent from the cxf-user mailing list archive at Nabble.com.


Reply via email to