Module Std.Channel

module Channel: Channel

type ('to_hub, 'from_hub) t 
val create : ?buffer_age_limit:[ `At_most of Core.Std.Time.Span.t | `Unlimited ] ->
addr:Async.Std.Unix.Inet_addr.t * int ->
unit -> ('a, 'b) t Async.Std.Deferred.t
create is type-unsafe, and should not be used by user code.
val close : ('a, 'b) t -> unit Async.Std.Deferred.t
val read : ('a, 'b) t -> 'b Async.Std.Deferred.t
val read_full : ('a, 'b) t -> 'b Async.Std.Reader.Read_result.t Async.Std.Deferred.t
val write : ('a, 'b) t -> 'a -> unit
type 'a pre_packed 
val pre_pack : 'a -> 'a pre_packed
val write_pre_packed : ('a, 'b) t -> 'a pre_packed -> unit
val flushed : ('a, 'b) t -> unit Async.Std.Deferred.t
val socket : ('a, 'b) t -> Async.Std.Unix.Inet_addr.t * int
val errors : ('a, 'b) t -> exn Async.Std.Stream.t
Similar to Monitor.errors, collects all writer errors. If this function has never been called, then exceptions will be raised directly