@@ -98,7 +98,7 @@ type ty =
9898 | Map of ty * ty
9999 | Ref of string
100100 | Record of string
101- with rpc
101+ [ @@ deriving rpc ]
102102
103103type api_value =
104104 VString of string
@@ -111,7 +111,7 @@ type api_value =
111111 | VSet of api_value list
112112 | VRef of string
113113 | VCustom of string * api_value
114- with rpc
114+ [ @@ deriving rpc ]
115115
116116(* * Each database field has a qualifier associated with it:
117117 * "Static" means the initial value is specified as a parameter in the object constructor.
@@ -122,14 +122,14 @@ type qualifier =
122122 | RW (* * Implicitly static: set in constructor and updatable through API *)
123123 | StaticRO (* * Specified in constructor; no autogenerated setter in XenAPI. *)
124124 | DynamicRO (* * Initial value is a default; no autogenerated setter in XenAPI. *)
125- with rpc
125+ [ @@ deriving rpc ]
126126
127127(* * Release keeps track of which versions of opensource/internal products fields and messages are included in *)
128128type release = {
129129 opensource : string list ;
130130 internal : string list ;
131131 internal_deprecated_since : string option ; (* first release we said it was deprecated *)
132- } with rpc
132+ } [ @@ deriving rpc ]
133133
134134type lifecycle_change =
135135 | Prototyped
@@ -140,7 +140,7 @@ type lifecycle_change =
140140 | Removed
141141
142142and lifecycle_transition = lifecycle_change * string * string
143- with rpc
143+ [ @@ deriving rpc]
144144
145145(* * Messages are tagged with one of these indicating whether the message was
146146 specified explicitly in the datamodel, or is one of the automatically
@@ -219,7 +219,7 @@ and error = {
219219and mess = {
220220 mess_name : string ;
221221 mess_doc : string ;
222- } with rpc
222+ } [ @@ deriving rpc]
223223
224224let default_message = {
225225 msg_name = " " ;
@@ -258,12 +258,12 @@ let default_message = {
258258type content =
259259 | Field of field (* * An individual field *)
260260 | Namespace of string * content list (* * A nice namespace for a group of fields *)
261- with rpc
261+ [ @@ deriving rpc ]
262262
263263(* Note: there used be more than 2 persist_options -- that's why it isn't a bool.
264264 I figured even though there's only 2 now I may as well leave it as an enumeration type.. *)
265265
266- type persist_option = PersistNothing | PersistEverything with rpc
266+ type persist_option = PersistNothing | PersistEverything [ @@ deriving rpc ]
267267(* PersistEverything - all creates/writes persisted;
268268 PersistNothing - no creates/writes to this table persisted *)
269269
@@ -285,7 +285,7 @@ type obj = {
285285 obj_release : release ;
286286 in_database : bool ; (* If the object is in the database *)
287287 obj_doc_tags : doc_tag list ;
288- } with rpc
288+ } [ @@ deriving rpc ]
289289
290290(* val rpc_of_obj : obj -> Rpc.t *)
291291(* let s = Jsonrpc.to_string (rpc_of_obj o) *)
0 commit comments