module Uq_multiplex:sig..end
class type multiplex_controller =object..end
multiplex_controller is a quite low-level device to abstract
 bidirectional socket connections.
class type datagram_multiplex_controller =object..end
exception Mem_not_supported
start_mem_reading and
      start_mem_writing if these methods are not supported for the kind
      of file descriptorval create_multiplex_controller_for_connected_socket : ?close_inactive_descr:bool ->
       ?preclose:(unit -> unit) ->
       ?supports_half_open_connection:bool ->
       ?timeout:float * exn ->
       Unix.file_descr ->
       Unixqueue.unix_event_system -> multiplex_controller
 Note that the file descriptor is not closed when the attached engines
 are terminated. One can call inactivate manually to do that.
 close_inactive_descr: Whether inactivate closes the descriptor.
 True by default.
 preclose: This function is called just before the descriptor is
 closed.
 supports_half_open_connection: This implementation does not know
 how to find out whether the socket supports half-open connections.
 You can simply set this boolean because of this. Defaults to false.
 You can set it to true for TCP connections and for Unix-domain
 connections with stream semantics.
 timeout: If set to (t, x), a general timeout of t is set.
 When an operation has been started, and there is no I/O activity within
 t seconds, neither by the started operation nor by another operation,
 the connection times out. In this case, the operation returns the
 exception x.
val create_multiplex_controller_for_datagram_socket : ?close_inactive_descr:bool ->
       ?preclose:(unit -> unit) ->
       ?timeout:float * exn ->
       Unix.file_descr ->
       Unixqueue.unix_event_system -> datagram_multiplex_controller
 Note that the file descriptor is not closed when the attached engines
 are terminated. One can call inactivate manually to do that.
 close_inactive_descr: Whether inactivate closes the descriptor.
 True by default.
 preclose: This function is called just before the descriptor is
 closed.
 timeout: If set to (t, x), a general timeout of t is set.
 When an operation has been started, and there is no I/O activity within
 t seconds, neither by the started operation nor by another operation,
 the connection times out. In this case, the operation returns the
 exception x.
val tls_multiplex_controller : ?resume:string ->
       ?on_handshake:(multiplex_controller -> unit) ->
       role:[ `Client | `Server ] ->
       peer_name:string option ->
       (module Netsys_crypto_types.TLS_CONFIG) ->
       multiplex_controller -> multiplex_controller
      resume: The endpoint resumes an old session whose data are passed here.
      This is only possible for client endpoints.
      on_handshake: called back when the handshake is done
val restore_tls_multiplex_controller : ?on_handshake:(multiplex_controller -> unit) ->
       exn ->
       (module Netsys_crypto_types.TLS_CONFIG) ->
       multiplex_controller -> multiplex_controllertls_multiplex_controller, but this function does not create a new
      TLS endpoint. Instead the exn value is assumed to be a stashed old
      endpoint.