Advertisement
Guest User

Untitled

a guest
Aug 29th, 2019
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
OCaml 1.09 KB | None | 0 0
  1. trading_model.eliom:
  2. [%%shared
  3. type sellOrderCapture = {
  4.   sellOrderId : int;
  5. }
  6. [@@deriving yojson]
  7.  
  8. type buyOrderCapture = {
  9.   buyOrderId : int;
  10.   quantity : int;
  11. }
  12. [@@deriving yojson]
  13.  
  14. type t = {
  15.   sellOrder : sellOrderCapture;
  16.   buyOrders : buyOrderCapture list;
  17. }
  18. [@@deriving yojson]
  19.  
  20. trading_model.type_mli:
  21.  
  22. module MatchCapture :
  23. sig
  24.   type sellOrderCapture = { sellOrderId : int; }
  25.   val sellOrderCapture_to_yojson : sellOrderCapture -> Yojson.Safe.t
  26.   val sellOrderCapture_of_yojson :
  27.     Yojson.Safe.t -> sellOrderCapture Ppx_deriving_yojson_runtime.error_or
  28.   type buyOrderCapture = { buyOrderId : int; quantity : int; }
  29.   val buyOrderCapture_to_yojson : buyOrderCapture -> Yojson.Safe.t
  30.   val buyOrderCapture_of_yojson :
  31.     Yojson.Safe.t -> buyOrderCapture Ppx_deriving_yojson_runtime.error_or
  32.   type t = {
  33.     sellOrder : sellOrderCapture;
  34.     buyOrders : buyOrderCapture list;
  35.   }
  36.   val to_yojson : t -> Yojson.Safe.t
  37.   val of_yojson : Yojson.Safe.t -> t Ppx_deriving_yojson_runtime.error_or
  38.   val _ : Yojson.Safe.t -> t Ppx_deriving_yojson_runtime.error_or
  39. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement