jsr339-experts@jax-rs-spec.java.net

[jsr339-experts] Re: [jax-rs-spec users] Re: Client API requirements

From: Santiago Pericas-Geertsen <Santiago.PericasGeertsen_at_oracle.com>
Date: Wed, 13 Jul 2011 10:38:49 -0400

On Jul 13, 2011, at 10:17 AM, Bill Burke wrote:

>> - API must allign well with the IDE code-completion
>> : the IDE code completion should be able to provide relevant hints for the fluent API based on the context
>> : e.g. once the entity was set, the IDE would not list the entity() method in the fluent method invocation chain code
>> completion again (this is an illustrative example, not satisfiable with the current API)
>>
>
> I'd like to see this explored. Especially by Guilherme as he seems to have a lot of experience with this in his own api. Still, I do think a simple class hierarchy also has merits and I believe heading down this route will create a much more complex hierarchy.

 In my view, when we talk about complexity, we should separate app developers vs. JAX-RS framework developers. If adding a builder here or there as part of the framework makes developing applications easier, then that's something worth considering.

 If a developer types:

 invocation.method("PATCH").

 and the IDE suggests "get()" as an alternative, he/she will likely be confused. As an app developer, I don't really care if there's extra class in the framework, but I do appreciate ease of use.

-- Santiago