users@jersey.java.net

can we get a UriBuilder.addOrReplaceSegment method?

From: geoffrey hendrey <geoff_at_nextdb.net>
Date: Tue, 2 Feb 2010 22:46:09 -0800

Hi,

I posted along these lines a while back, but I continue to run into cases
where I need to make modifications to a URI, and there doesn't seem to be an
easy way to do it.
For instance, if my resource has URI .../color/red/width/10/height/5, I find
myself needing to redirect the client after an "edit" operation to
.../color/BLUE/width/10/height/2.

What I really want is
UriInfo.getAbsolutePathBuilder().addOrReplaceSegment("color/${color}","BLUE").addOrReplaceSegment("height/${height}","2");

Can you please consider this feature, or help me understand why I don't need
it?

-geoff

-- 
http://nextdb.net - RESTful Relational Database
http://www.nextdb.net/wiki/en/REST