Sketch of updated APIs (was Re: Redirection and creation)

From: Marc Hadley <Marc.Hadley_at_Sun.COM>
Date: Mon, 16 Apr 2007 11:39:02 -0400

On Apr 13, 2007, at 3:17 PM, Marc Hadley wrote:

> On Apr 13, 2007, at 1:21 PM, Jerome Louvel wrote:
>> That's an interesting path to explore. I'm still not found of the
>> Response
>> class and subclasses, but I'm interested to look at an updated API.
> Sure, I'll also try to roll in some of the feedback received so far
> and post some updated javadocs early next week.

The infrastructure seem to interfere with normal frames-
based javadoc viewing so for now you'll have to use the non-frames
pages or checkout the "sketch1" branch from Subversion.

Main changes:

- Removed some of the SPIs
- Coalesced some packages
- Refactored HttpContext, HttpRequestContext and HttpResponse.
HttpContext becomes an annotation that can be used to inject UriInfo,
HttpHeaders and PreconditionEvaluator.
- Added a few new annotations for marking properties that correspond
to HTTP metadata
- Reworked Representation and HttpResponse to use annotations to mark
their properties as I'd outlined earlier in the thread. Essentially
the representation and response classes become "pre-baked" instances
of return types but the annotation approach allows an application to
use their own classes instead if they so wish.

I have some concerns about the rework described in the final bullet -
I'll air those shortly in a separate mail.


Marc Hadley <marc.hadley at>
CTO Office, Sun Microsystems.