X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2FDEVEL%2Focaml-http%2Fhttp_misc.mli;h=86293404035dc2e04b22042d32bf90048c269b05;hb=ca9cd0aeee0ce78a891f7f6091ca8704231a446d;hp=6e5fdfcf6425daf10beedcbc60b0269fe4184077;hpb=b5703de4f7697426ebda94fce2558add7c4f0285;p=helm.git diff --git a/helm/DEVEL/ocaml-http/http_misc.mli b/helm/DEVEL/ocaml-http/http_misc.mli index 6e5fdfcf6..862934040 100644 --- a/helm/DEVEL/ocaml-http/http_misc.mli +++ b/helm/DEVEL/ocaml-http/http_misc.mli @@ -62,4 +62,18 @@ val explode_sockaddr: Unix.sockaddr -> string * int val peername_of_out_channel: out_channel -> Unix.sockaddr (** as above but works on in_channels *) val peername_of_in_channel: in_channel -> Unix.sockaddr + (** given an out_channel build on top of a socket, return sockname related to + that socket *) +val sockname_of_out_channel: out_channel -> Unix.sockaddr + (** as above but works on in_channels *) +val sockname_of_in_channel: in_channel -> Unix.sockaddr + + (** reads from an input channel till it End_of_file and returns what has been + read; if limit is given returned buffer will contains at most first 'limit' + bytes read from input channel *) +val buf_of_inchan: ?limit: int -> in_channel -> Buffer.t + + (** like List.assoc but return all bindings of a given key instead of the + leftmost one only *) +val list_assoc_all: 'a -> ('a * 'b) list -> 'b list