mirror of
https://github.com/BluTac10/Xbox-Neo.git
synced 2026-06-15 22:52:00 +00:00
fix: folderFile common linking
This commit is contained in:
28
include/lce_filesystem/FolderFile.h
Normal file
28
include/lce_filesystem/FolderFile.h
Normal file
@@ -0,0 +1,28 @@
|
||||
#pragma once
|
||||
|
||||
#include <vector>
|
||||
#include <unordered_map>
|
||||
#include <windows.h>
|
||||
|
||||
#include "../Minecraft.World/ArrayWithLength.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
class FolderFile
|
||||
{
|
||||
private:
|
||||
wstring m_folderPath;
|
||||
unordered_map<wstring, wstring> m_filePaths; // filename -> full path
|
||||
|
||||
void _buildFileIndex();
|
||||
void _buildFileIndexRecursive(const wstring& currentPath, const wstring& relativePath);
|
||||
|
||||
public:
|
||||
FolderFile(wstring folderPath);
|
||||
~FolderFile();
|
||||
|
||||
vector<wstring>* getFileList();
|
||||
bool hasFile(const wstring &filename);
|
||||
int getFileSize(const wstring &filename);
|
||||
byteArray getFile(const wstring &filename);
|
||||
};
|
||||
Reference in New Issue
Block a user