BanjoAst { | |
primary_namespace: "banjo.examples.example9", | |
namespaces: { | |
"banjo.examples.example9": [ | |
Enum { | |
attributes: Attrs( | |
[] | |
), | |
name: "EchoMe", | |
ty: UInt32, | |
variants: [ | |
EnumVariant { | |
attributes: Attrs( | |
[] | |
), | |
name: "zero", | |
size: Constant( | |
"0" | |
) | |
}, | |
EnumVariant { | |
attributes: Attrs( | |
[] | |
), | |
name: "one", | |
size: Constant( | |
"1" | |
) | |
} | |
] | |
}, | |
Struct { | |
attributes: Attrs( | |
[] | |
), | |
name: "EchoMore", | |
fields: [ | |
StructField { | |
attributes: Attrs( | |
[] | |
), | |
ty: UInt32, | |
ident: Ident { | |
namespace: None, | |
name: "first" | |
}, | |
val: None | |
}, | |
StructField { | |
attributes: Attrs( | |
[] | |
), | |
ty: UInt64, | |
ident: Ident { | |
namespace: None, | |
name: "second" | |
}, | |
val: None | |
} | |
] | |
}, | |
Interface { | |
attributes: Attrs( | |
[] | |
), | |
name: "Echo", | |
methods: [ | |
Method { | |
attributes: Attrs( | |
[] | |
), | |
name: "Echo32", | |
in_params: [ | |
( | |
"uint32", | |
UInt32 | |
) | |
], | |
out_params: [ | |
( | |
"response", | |
UInt32 | |
) | |
] | |
}, | |
Method { | |
attributes: Attrs( | |
[] | |
), | |
name: "Echo64", | |
in_params: [ | |
( | |
"uint64", | |
UInt64 | |
) | |
], | |
out_params: [ | |
( | |
"response", | |
UInt64 | |
) | |
] | |
}, | |
Method { | |
attributes: Attrs( | |
[] | |
), | |
name: "EchoEnum", | |
in_params: [ | |
( | |
"req", | |
Identifier { | |
id: Ident { | |
namespace: None, | |
name: "EchoMe" | |
}, | |
reference: false | |
} | |
) | |
], | |
out_params: [ | |
( | |
"response", | |
Identifier { | |
id: Ident { | |
namespace: None, | |
name: "EchoMe" | |
}, | |
reference: false | |
} | |
) | |
] | |
}, | |
Method { | |
attributes: Attrs( | |
[] | |
), | |
name: "EchoHandle", | |
in_params: [ | |
( | |
"req", | |
Handle { | |
ty: Handle, | |
reference: false | |
} | |
) | |
], | |
out_params: [ | |
( | |
"response", | |
Handle { | |
ty: Handle, | |
reference: false | |
} | |
) | |
] | |
}, | |
Method { | |
attributes: Attrs( | |
[] | |
), | |
name: "EchoChannel", | |
in_params: [ | |
( | |
"req", | |
Handle { | |
ty: Channel, | |
reference: false | |
} | |
) | |
], | |
out_params: [ | |
( | |
"response", | |
Handle { | |
ty: Channel, | |
reference: false | |
} | |
) | |
] | |
}, | |
Method { | |
attributes: Attrs( | |
[] | |
), | |
name: "EchoStruct", | |
in_params: [ | |
( | |
"req", | |
Identifier { | |
id: Ident { | |
namespace: None, | |
name: "EchoMore" | |
}, | |
reference: false | |
} | |
) | |
], | |
out_params: [ | |
( | |
"response", | |
Identifier { | |
id: Ident { | |
namespace: None, | |
name: "EchoMore" | |
}, | |
reference: false | |
} | |
) | |
] | |
} | |
] | |
}, | |
Constant { | |
attributes: Attrs( | |
[] | |
), | |
name: "favorite_echo", | |
ty: Identifier { | |
id: Ident { | |
namespace: None, | |
name: "EchoMe" | |
}, | |
reference: false | |
}, | |
value: Constant( | |
"zero" | |
) | |
} | |
] | |
} | |
} |