Torch
Loading...
Searching...
No Matches
DictionaryFactory.h
1
#pragma once
2
3
#include <factories/BaseFactory.h>
4
5
namespace
SM64 {
6
7
class
DictionaryData :
public
IParsedData
{
8
public
:
9
std::unordered_map<std::string, std::vector<uint8_t>> mDictionary;
10
11
DictionaryData(std::unordered_map<std::string, std::vector<uint8_t>> dictionary) : mDictionary(dictionary) {}
12
};
13
14
class
DictionaryBinaryExporter
:
public
BaseExporter
{
15
ExportResult Export(std::ostream& write, std::shared_ptr<IParsedData> data, std::string& entryName, YAML::Node& node, std::string* replacement)
override
;
16
};
17
18
class
DictionaryFactory
:
public
BaseFactory
{
19
public
:
20
std::optional<std::shared_ptr<IParsedData>> parse(std::vector<uint8_t>& buffer, YAML::Node& data)
override
;
21
std::unordered_map<ExportType, std::shared_ptr<BaseExporter>> GetExporters()
override
{
22
return
{ REGISTER(Binary,
DictionaryBinaryExporter
) };
23
}
24
};
25
}
BaseExporter
Definition
BaseFactory.h:88
BaseFactory
Definition
BaseFactory.h:94
IParsedData
Definition
BaseFactory.h:80
SM64::DictionaryBinaryExporter
Definition
DictionaryFactory.h:14
SM64::DictionaryFactory
Definition
DictionaryFactory.h:18
src
factories
sm64
DictionaryFactory.h
Generated by
1.14.0