+
+ method body: string
+ method setBody: string -> unit
+ method bodyBuf: Buffer.t
+ method setBodyBuf: Buffer.t -> unit
+ method addBody: string -> unit
+ method addBodyBuf: Buffer.t -> unit
+
+ method addHeader: name:string -> value:string -> unit
+ method addHeaders: (string * string) list -> unit
+ method replaceHeader: name:string -> value:string -> unit
+ method replaceHeaders: (string * string) list -> unit
+ method removeHeader: name:string -> unit
+ method hasHeader: name:string -> bool
+ method header: name:string -> string
+ method headers: (string * string) list
+
+ method clientSockaddr: Unix.sockaddr
+ method clientAddr: string
+ method clientPort: int
+
+ method serverSockaddr: Unix.sockaddr
+ method serverAddr: string
+ method serverPort: int
+
+ method toString: string
+ method serialize: out_channel -> unit
+
+ end
+
+ (** HTTP requests *)
+class type request = object
+
+ (** an HTTP request is a flavour of HTTP message *)
+ inherit message
+
+ (** @return request method *)
+ method meth: meth
+
+ (** @return requested URI (including query string, fragment, ...) *)
+ method uri: string
+
+ (** @return requested path *)
+ method path: string
+
+ (** lookup a given parameter
+ @param meth if given restrict the lookup area (e.g. if meth = POST than
+ only parameters received via POST are searched), if not given both GET and
+ POST parameter are searched in an unspecified order (actually the
+ implementation prefers POST parameters but this is not granted, you've
+ been warned)
+ @param name name of the parameter to lookup
+ @return value associated to parameter name
+ @raise Param_not_found if parameter name was not found *)
+ method param: ?meth:meth -> string -> string
+
+ (** like param above but return a list of values associated to given
+ parameter (a parameter could be defined indeed more than once: passed more
+ than once in a query string or passed both insider the url (the GET way)
+ and inside message body (the POST way)) *)
+ method paramAll: ?meth:meth -> string -> string list
+
+ (** @return the list of all received parameters *)
+ method params: (string * string) list
+
+ (** @return the list of all parameters received via GET *)
+ method params_GET: (string * string) list
+
+ (** @return the list of all parameter received via POST *)
+ method params_POST: (string * string) list
+
+ (** @return authorization information, if given by the client *)
+ method authorization: auth_info option
+
+ end
+
+ (** HTTP responses *)
+class type response = object
+
+ inherit message
+
+ (** @return response code *)