[Megane] Add tiny library to translate utf8 characters to kvg code

This commit is contained in:
TennesseeTrash 2025-06-14 13:19:47 +02:00
parent 4943f35d91
commit 3b5eb6f1a4
8 changed files with 145 additions and 0 deletions

View file

@ -0,0 +1,29 @@
#ifndef MEGANE_MEGANE_HPP
#define MEGANE_MEGANE_HPP
#include <gtl/phmap.hpp>
#include <stdexcept>
#include <string>
namespace Megane
{
class Error : public std::runtime_error
{
using std::runtime_error::runtime_error;
};
class Megane
{
public:
Megane(const std::string& indexPath);
~Megane();
std::string GetCode(const std::string& character) const;
private:
gtl::flat_hash_map<std::string, std::string> mStorage;
};
}
#endif // MEGANE_MEGANE_HPP