paul@181 | 1 | #include <systypes/base.h> /* flags_t, object_flags_t, offset_t */ |
paul@181 | 2 | |
paul@232 | 3 | /* An interface providing a way of opening or manipulating filesystem objects |
paul@232 | 4 | relying on a dataspace to transfer filesystem paths specifying the objects |
paul@232 | 5 | involved. */ |
paul@181 | 6 | |
paul@181 | 7 | interface OpenerContext |
paul@181 | 8 | { |
paul@181 | 9 | /* Mount the filesystem reference given a mountpoint path written to the |
paul@181 | 10 | dataspace. */ |
paul@181 | 11 | |
paul@181 | 12 | [opcode(0)] void mount(in cap fs); |
paul@181 | 13 | |
paul@181 | 14 | /* Obtain a filesystem reference. */ |
paul@181 | 15 | |
paul@181 | 16 | [opcode(1)] void getfs(out cap fs); |
paul@181 | 17 | |
paul@181 | 18 | /* Obtain a file reference given a path written to the context's dataspace. */ |
paul@181 | 19 | |
paul@181 | 20 | [opcode(12)] void open(in flags_t flags, out offset_t size, out cap file, |
paul@181 | 21 | out object_flags_t object_flags); |
paul@232 | 22 | |
paul@232 | 23 | /* Remove a file using a path written to the context's dataspace. */ |
paul@232 | 24 | |
paul@232 | 25 | [opcode(14)] void remove(); |
paul@236 | 26 | |
paul@236 | 27 | /* Rename a file within a filesystem using paths written to the context's |
paul@236 | 28 | dataspace. */ |
paul@236 | 29 | |
paul@236 | 30 | [opcode(15)] void rename(); |
paul@266 | 31 | |
paul@266 | 32 | /* Obtain file metadata given a path written to the context's dataspace, |
paul@266 | 33 | writing the metadata to the dataspace. */ |
paul@266 | 34 | |
paul@266 | 35 | [opcode(11)] void stat(); |
paul@181 | 36 | }; |
paul@181 | 37 | |
paul@181 | 38 | /* vim: tabstop=2 expandtab shiftwidth=2 |
paul@181 | 39 | */ |