2023-02-21 13:36:20 +00:00
|
|
|
#pragma once
|
|
|
|
#include <stdint-gcc.h>
|
|
|
|
#include "../../../CoreLib/Path.h"
|
|
|
|
#include "StorageTypes.h"
|
|
|
|
class VirtualFileSystem
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
static void initialize();
|
|
|
|
static void Mount(PFS fs, unsigned int DeviceID);
|
|
|
|
static void Unmount(unsigned int DeviceID);
|
2023-02-21 20:43:14 +00:00
|
|
|
static FILE OpenFile(const char* path);
|
|
|
|
static void RegisterPartition(PTR_PARTITION partition);
|
2023-02-21 13:36:20 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
static const unsigned int DEVICE_MAX = 26;
|
2023-02-21 20:43:14 +00:00
|
|
|
static const unsigned int PARTITION_MAX = 4 * DEVICE_MAX;
|
2023-02-21 13:36:20 +00:00
|
|
|
static PFS _filesystems[DEVICE_MAX];
|
2023-02-21 20:43:14 +00:00
|
|
|
static unsigned int num_partitions;
|
|
|
|
static PTR_PARTITION _partitions [PARTITION_MAX];
|
2023-02-21 13:36:20 +00:00
|
|
|
};
|