There's no single ProtoDef format enforced by this spec. Projects use either JSON and PDS (ProtoDef Spec) which have own pros and cons (comments, complicated syntax, lack of support).
I propose to replace both of them with HJSON, which already have libraries in many languages.
Example PDS:
@doc "A composite data structure which contains 3 fields."
def("position") => container {
field("x") => ::f64;
field("y") => ::f64;
field("z") => ::f64;
};
Example JSON:
{
"position": [
"container",
[
{ "name": "x", "type": "f64" },
{ "name": "y", "type": "f64" },
{ "name": "z", "type": "f64" }
]
]
}
Example HJSON:
{
// A composite data structure which contains 3 fields.
position: [
container
[
{ name: x, type: f64 },
{ name: y, type: f64 },
{ name: z, type: f64 },
]
]
}
There's no single ProtoDef format enforced by this spec. Projects use either JSON and PDS (ProtoDef Spec) which have own pros and cons (comments, complicated syntax, lack of support).
I propose to replace both of them with HJSON, which already have libraries in many languages.
Example PDS:
Example JSON:
{ "position": [ "container", [ { "name": "x", "type": "f64" }, { "name": "y", "type": "f64" }, { "name": "z", "type": "f64" } ] ] }Example HJSON: