summaryrefslogtreecommitdiff
path: root/src/msg.fbs
diff options
context:
space:
mode:
Diffstat (limited to 'src/msg.fbs')
-rw-r--r--src/msg.fbs48
1 files changed, 48 insertions, 0 deletions
diff --git a/src/msg.fbs b/src/msg.fbs
index 0d78395ea..7f42cd637 100644
--- a/src/msg.fbs
+++ b/src/msg.fbs
@@ -27,6 +27,13 @@ union Any {
Stat,
StatRes,
SetEnv,
+ Open,
+ OpenRes,
+ Read,
+ ReadRes,
+ Write,
+ WriteRes,
+ Close,
}
enum ErrorKind: byte {
@@ -53,6 +60,8 @@ enum ErrorKind: byte {
Other,
UnexpectedEof,
+ BadFileDescriptor,
+
// url errors
EmptyHost,
@@ -199,6 +208,7 @@ table ReadFileRes {
table WriteFile {
filename: string;
+ data: [ubyte];
perm: uint;
// perm specified by https://godoc.org/os#FileMode
}
@@ -237,4 +247,42 @@ table StatRes {
has_mode: bool; // false on windows
}
+table WriteFileSync {
+ filename: string;
+ data: [ubyte];
+ perm: uint;
+ // perm specified by https://godoc.org/os#FileMode
+}
+
+table Open {
+ filename: string;
+ perm: uint;
+}
+
+table OpenRes {
+ fd: int;
+}
+
+table Read {
+ fd: int;
+ // (ptr, len) is passed as second parameter to libdeno.send().
+}
+
+table ReadRes {
+ nread: uint;
+ eof: bool;
+}
+
+table Write {
+ fd: int;
+}
+
+table WriteRes {
+ nbyte: uint;
+}
+
+table Close {
+ fd: int;
+}
+
root_type Base;