[Yunq] Factor out parsing most message fields to a shared method.

This commit is contained in:
Drew Galbraith 2023-11-10 12:51:23 -08:00
parent 0dacbb87dc
commit 83dbd18cb4
4 changed files with 40 additions and 51 deletions

View file

@ -26,6 +26,8 @@ class OpenFileRequest {
glcr::String path_;
glcr::Vector<uint64_t> options_;
// Parses everything except for caps.
void ParseFromBytesInternal(const glcr::ByteBuffer&, uint64_t offset);
};
class File {
public:
@ -50,4 +52,6 @@ class File {
uint64_t attrs_;
z_cap_t mem_cap_;
// Parses everything except for caps.
void ParseFromBytesInternal(const glcr::ByteBuffer&, uint64_t offset);
};