2021-12-31 21:42:24 +00:00
|
|
|
import "./import";
|
2021-12-31 21:38:26 +00:00
|
|
|
|
2022-01-10 14:15:06 +00:00
|
|
|
define csharp_namespace Example;
|
2022-04-13 19:01:12 +00:00
|
|
|
define rust_crate example;
|
2022-07-21 07:09:10 +00:00
|
|
|
define dart_library_name example;
|
2022-01-05 21:16:17 +00:00
|
|
|
|
2021-12-31 21:38:26 +00:00
|
|
|
enum TestEnum {
|
|
|
|
VAL1,
|
|
|
|
VAL2,
|
|
|
|
VAL10 = 10,
|
|
|
|
VAL11,
|
|
|
|
VAL12
|
|
|
|
}
|
|
|
|
|
|
|
|
type Test {
|
|
|
|
atom: TestAtom;
|
|
|
|
array: TestAtom[];
|
|
|
|
enumValue: TestEnum;
|
2022-04-13 19:01:12 +00:00
|
|
|
map: {int, TestAtom};
|
2021-12-31 21:38:26 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
type AddValueRequest {
|
2022-04-13 19:01:12 +00:00
|
|
|
value1: float;
|
|
|
|
value2: float;
|
2021-12-31 21:38:26 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
type AddValueResponse {
|
2022-04-13 19:01:12 +00:00
|
|
|
value: float;
|
2021-12-31 21:38:26 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
service TestService {
|
2022-01-01 18:47:34 +00:00
|
|
|
@Description("Add two numbers")
|
|
|
|
@Param("request", "Parameter containing the two numbers")
|
2022-01-03 21:08:25 +00:00
|
|
|
@Returns("")
|
2021-12-31 21:38:26 +00:00
|
|
|
AddValuesSingleParam(request: AddValueRequest): AddValueResponse;
|
2022-01-01 18:47:34 +00:00
|
|
|
|
|
|
|
@Description("Add two numbers")
|
|
|
|
@Param("value1", "The first value")
|
|
|
|
@Param("value2", "The second value")
|
2022-04-13 19:01:12 +00:00
|
|
|
AddValuesMultipleParams(value1: float, value2: float): float;
|
2022-01-01 18:47:34 +00:00
|
|
|
|
|
|
|
@Description("Does literaly nothing")
|
|
|
|
@Param("param1", "Some number")
|
2022-04-13 19:01:12 +00:00
|
|
|
ReturningVoid(param1: float): void;
|
2021-12-31 21:38:26 +00:00
|
|
|
|
2022-01-01 18:47:34 +00:00
|
|
|
@Description("Just sends an Event with a String")
|
|
|
|
@Param("param1", "Parameter with some string for event")
|
2021-12-31 21:38:26 +00:00
|
|
|
notification OnEvent(param1: string);
|
2022-01-02 20:51:45 +00:00
|
|
|
|
2022-01-05 21:16:17 +00:00
|
|
|
ThrowingError(): void;
|
|
|
|
|
2022-01-02 20:51:45 +00:00
|
|
|
|
2022-04-13 19:01:12 +00:00
|
|
|
FunctionWithArrayAsParamAndReturn(values1: float[], values2: float[]): float[];
|
2024-01-18 18:08:44 +00:00
|
|
|
|
|
|
|
FunctionWithKeywords(type: float, static: float, event: float): float;
|
2021-12-31 21:38:26 +00:00
|
|
|
}
|
2022-12-17 16:11:28 +00:00
|
|
|
|
|
|
|
type Test2 {
|
|
|
|
name: string;
|
|
|
|
age: int;
|
|
|
|
}
|
|
|
|
|
2024-01-18 18:08:44 +00:00
|
|
|
type TestKeywords {
|
|
|
|
type: float;
|
|
|
|
static: float;
|
|
|
|
event: float;
|
|
|
|
}
|
|
|
|
|
2022-12-17 16:11:28 +00:00
|
|
|
service SimpleTestService {
|
|
|
|
@Description("asdasdasd")
|
|
|
|
GetTest(name: string, age: int): Test2;
|
|
|
|
notification TestNot();
|
|
|
|
}
|