Ocaml_protoc_compiler_lib.Pb_parsing_utilSourceParse tree utilities
This module defines convenient function to create and manipulate the parse tree.
val field :
?options:Pb_option.set ->
label:Pt.message_field_label ->
number:int ->
type_:string ->
string ->
Pt.message_fieldval map_field :
?options:Pb_option.set ->
number:int ->
key_type:string ->
value_type:string ->
string ->
Pt.map_fieldval oneof_field :
?options:Pb_option.set ->
number:int ->
type_:string ->
string ->
Pt.oneof_body_contentval rpc :
?options:Pb_option.set ->
req_stream:bool ->
req:string ->
res_stream:bool ->
res:string ->
string ->
Pt.rpcval proto :
?syntax:string ->
?file_option:Pb_option.t ->
?package:string ->
?import:Pt.import ->
?message:Pt.message ->
?service:Pt.service ->
?enum:Pt.enum ->
?proto:Pt.proto ->
?extend:Pt.extend ->
unit ->
Pt.protoproto ~message ~proto () will add message to proto and return a the updated proto value.