forked from denoland/deno
-
Notifications
You must be signed in to change notification settings - Fork 0
/
msg.fbs
104 lines (87 loc) · 1.44 KB
/
msg.fbs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
namespace deno;
union Any {
Start,
StartRes,
CodeFetch,
CodeFetchRes,
CodeCache,
Exit,
TimerStart,
TimerReady,
TimerClear,
FetchReq,
FetchRes,
ReadFileSync,
ReadFileSyncRes,
WriteFileSync,
}
table Base {
cmdId: uint32;
error: string;
msg: Any;
}
table Start {
unused: int8;
}
table StartRes {
cwd: string;
argv: [string];
debug_flag: bool;
}
table CodeFetch {
module_specifier: string;
containing_file: string;
}
table CodeFetchRes {
// If it's a non-http module, moduleName and filename will be the same.
// For http modules, moduleName is its resolved http URL, and filename
// is the location of the locally downloaded source code.
module_name: string;
filename: string;
source_code: string;
output_code: string; // Non-empty only if cached.
}
table CodeCache {
filename: string;
source_code: string;
output_code: string;
}
table Exit {
code: int;
}
table TimerStart {
id: uint;
interval: bool;
delay: uint;
}
table TimerReady {
id: uint;
done: bool;
}
table TimerClear {
id: uint;
}
table FetchReq {
id: uint;
url: string;
// header_line: [string];
}
table FetchRes {
id: uint;
status: int;
header_line: [string];
body: [ubyte];
}
table ReadFileSync {
filename: string;
}
table ReadFileSyncRes {
data: [ubyte];
}
table WriteFileSync {
filename: string;
data: [ubyte];
perm: uint;
// perm specified by https://godoc.org/os#FileMode
}
root_type Base;