package wamp

  1. Overview
  2. Docs
On This Page
  1. Wamp
Legend:
Library
Module
Module type
Parameter
Class
Class type

wamp-proto.org implementation in OCaml

%%VERSION%% — homepage

Wamp

type msgtyp =
  1. | HELLO
  2. | WELCOME
  3. | ABORT
  4. | GOODBYE
  5. | ERROR
  6. | PUBLISH
  7. | PUBLISHED
  8. | SUBSCRIBE
  9. | SUBSCRIBED
  10. | UNSUBSCRIBE
  11. | UNSUBSCRIBED
  12. | EVENT
val min_msgtyp : Ppx_deriving_runtime.int
val max_msgtyp : Ppx_deriving_runtime.int
val msgtyp_to_enum : msgtyp -> Ppx_deriving_runtime.int
type 'a dict = (string * 'a) list
type 'a hello = {
  1. realm : Uri.t;
  2. details : 'a dict;
}
val create_hello : realm:Uri.t -> details:'a dict -> unit -> 'a hello
type 'a welcome = {
  1. id : int;
  2. details : 'a dict;
}
val create_welcome : id:int -> details:'a dict -> unit -> 'a welcome
type 'a details_reason = {
  1. details : 'a dict;
  2. reason : Uri.t;
}
val create_details_reason : details:'a dict -> reason:Uri.t -> unit -> 'a details_reason
type 'a goodbye = {
  1. details : 'a dict;
  2. reason : Uri.t;
}
val create_goodbye : details:'a dict -> reason:Uri.t -> unit -> 'a goodbye
type 'a error = {
  1. reqtype : int;
  2. reqid : int;
  3. details : 'a dict;
  4. error : Uri.t;
  5. args : 'a list;
  6. kwArgs : 'a dict;
}
val create_error : reqtype:int -> reqid:int -> details:'a dict -> error:Uri.t -> ?args:'a list -> kwArgs:'a dict -> unit -> 'a error
type 'a publish = {
  1. reqid : int;
  2. options : 'a dict;
  3. topic : Uri.t;
  4. args : 'a list;
  5. kwArgs : 'a dict;
}
val create_publish : reqid:int -> options:'a dict -> topic:Uri.t -> ?args:'a list -> kwArgs:'a dict -> unit -> 'a publish
type ack = {
  1. reqid : int;
  2. id : int;
}
val create_ack : reqid:int -> id:int -> unit -> ack
type 'a subscribe = {
  1. reqid : int;
  2. options : 'a dict;
  3. topic : Uri.t;
}
val create_subscribe : reqid:int -> options:'a dict -> topic:Uri.t -> unit -> 'a subscribe
type 'a event = {
  1. subid : int;
  2. pubid : int;
  3. details : 'a dict;
  4. args : 'a list;
  5. kwArgs : 'a dict;
}
val create_event : subid:int -> pubid:int -> details:'a dict -> ?args:'a list -> kwArgs:'a dict -> unit -> 'a event
type 'a msg =
  1. | Hello of 'a hello
  2. | Welcome of 'a welcome
  3. | Abort of 'a details_reason
  4. | Goodbye of 'a details_reason
  5. | Error of 'a error
  6. | Publish of 'a publish
  7. | Published of ack
  8. | Subscribe of 'a subscribe
  9. | Subscribed of ack
  10. | Unsubscribe of ack
  11. | Unsubscribed of int
  12. | Event of 'a event
val sexp_of_msg : ('a -> Ppx_sexp_conv_lib.Sexp.t) -> 'a msg -> Ppx_sexp_conv_lib.Sexp.t
val msg_of_sexp : (Ppx_sexp_conv_lib.Sexp.t -> 'a) -> Ppx_sexp_conv_lib.Sexp.t -> 'a msg
type role =
  1. | Subscriber
  2. | Publisher
val string_of_role : role -> string