Hi all,

I share the same concern as Piyush. There are now about 34 methods in the
Call class, corresponding to about 20 properties. In the past, I've
addressed the issue by grouping related methods in container classes
(ClientData, ConditionData, SecurityData and ServerData). Here is the list
of properties remaining in the Call class:
 - attributes
 - baseRef
 - client
 - condition
 - cookies
 - cookieSettings
 - input
 - method
 - output
 - protocol
 - redirectRef
 - referrerRef
 - relativePart
 - relativeRef
 - resourceRef
 - security
 - server
 - status

Currently, ClientData and ServerData contain properties that are related the
client-side or server-side component of the call, and that are unlikely to
change with the target resource of the call. If we loosen up this constraint
by adding properties that are related to the client-side or server-side
components but that can also vary depending on the target, we obtain:
 - move cookies, condition, input, method, protocol, referrerRef,
resourceRef to ClientData
 - move cookieSettings, output, redirectRef, status to ServerData

Call would keep:
 - attributes
 - baseRef
 - client
 - relativePart
 - relativeRef
 - security
 - server

Now it becomes obvious that we are reinventing the concept of Request and
Response under new names, therefore why not rename ClientData to Request and
ServerData to Response for clarification purpose?

Going back to the roots or REST/HTTP, we have:
 - an exchange of information between two components
 - via a client connector and a server connector
 - the initiator component creates a request message 
 - sends it to a server connector via its client connector
 - the other component receives the request
 - then creates a response message
 - then processes the request to update the response
 - and sends the response message back to the initiator

If we break the Call class in two pieces:
 - Restlet's "handle(Call)" would become "handle(Request, Response)".
 - Connector could have a "handle(Request) : Response" method.

If there is no major opposition, I will try to integrate this change to beta
19. Any comment?

Best regards,
Jerome  

> -----Message d'origine-----
> De : Piyush Purang [mailto:[EMAIL PROTECTED] 
> Envoyé : jeudi 5 octobre 2006 15:10
> À : discuss@restlet.tigris.org
> Objet : Re: Allow Header
> 
> My immediate concern is a Call object with an ever increasing 
> interface. As of last count (b18) it stands at 30+ methods. 
> 
> 

Reply via email to