- put the entire filesystem code into a namespace and created some subdirectories.
This commit is contained in:
parent
94c9ee4593
commit
ebb71cebf1
108 changed files with 308 additions and 225 deletions
|
|
@ -1,27 +0,0 @@
|
|||
#pragma once
|
||||
|
||||
// Storage for all the static strings the file system must hold.
|
||||
class StringPool
|
||||
{
|
||||
// do not allow externally defining this.
|
||||
friend class FileSystem;
|
||||
friend class FResourceFile;
|
||||
private:
|
||||
StringPool(size_t blocksize = 10*1024) : TopBlock(nullptr), FreeBlocks(nullptr), BlockSize(blocksize) {}
|
||||
public:
|
||||
~StringPool();
|
||||
const char* Strdup(const char*);
|
||||
|
||||
protected:
|
||||
struct Block;
|
||||
|
||||
Block *AddBlock(size_t size);
|
||||
void *iAlloc(size_t size);
|
||||
|
||||
Block *TopBlock;
|
||||
Block *FreeBlocks;
|
||||
size_t BlockSize;
|
||||
public:
|
||||
bool shared;
|
||||
};
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue