[VictoriaFalls] Implement Read File.

This commit is contained in:
Drew Galbraith 2023-11-02 20:57:28 -07:00
parent abf09d8fce
commit d7050ff19f
7 changed files with 87 additions and 17 deletions

View file

@ -2,15 +2,20 @@
#include <glacier/memory/unique_ptr.h>
#include "fs/ext2/ext2_driver.h"
#include "victoriafalls/victoriafalls.yunq.server.h"
class VFSServer : public VFSServerBase {
public:
static glcr::ErrorOr<glcr::UniquePtr<VFSServer>> Create();
static glcr::ErrorOr<glcr::UniquePtr<VFSServer>> Create(Ext2Driver& driver);
glcr::ErrorCode HandleOpenFile(const OpenFileRequest&,
OpenFileResponse&) override;
private:
VFSServer(z_cap_t endpoint_cap) : VFSServerBase(endpoint_cap) {}
// FIXME: Don't store this as a reference.
Ext2Driver& driver_;
VFSServer(z_cap_t endpoint_cap, Ext2Driver& driver)
: VFSServerBase(endpoint_cap), driver_(driver) {}
};