#include "idl_gen_ts.h"
#include <algorithm>
#include <cassert>
#include <cmath>
#include <iostream>
#include <unordered_map>
#include <unordered_set>
#include "flatbuffers/code_generators.h"
#include "flatbuffers/flatbuffers.h"
#include "flatbuffers/flatc.h"
#include "flatbuffers/idl.h"
#include "flatbuffers/util.h"
#include "idl_namer.h"
namespace flatbuffers {
namespace {
struct ImportDefinition { … };
struct NsDefinition { … };
Namer::Config TypeScriptDefaultConfig() { … }
std::set<std::string> TypescriptKeywords() { … }
enum AnnotationType { … };
template<typename T> struct SupportsObjectAPI : std::false_type { … };
template<> struct SupportsObjectAPI<StructDef> : std::true_type { … };
}
namespace ts {
class TsGenerator : public BaseGenerator { … };
}
static bool GenerateTS(const Parser &parser, const std::string &path,
const std::string &file_name) { … }
static std::string TSMakeRule(const Parser &parser, const std::string &path,
const std::string &file_name) { … }
namespace {
class TsCodeGenerator : public CodeGenerator { … };
}
std::unique_ptr<CodeGenerator> NewTsCodeGenerator() { … }
}