svd2cpp/Src/ClassBuilder.hpp

30 lines
666 B
C++
Raw Normal View History

2019-11-22 11:57:17 +00:00
#ifndef CLASS_PRINTER
#define CLASS_PRINTER
#include <cxxopts.hpp>
#include <DeviceInfo.hpp>
#include <Peripheral.hpp>
#include <vector>
#include <IBuilder.hpp>
#include <memory>
#include <sstream>
struct ClassBuilder
{
ClassBuilder(const cxxopts::ParseResult& results_,
const DeviceInfo& deviceInfo_,
const std::vector<Peripheral>& peripherals_);
2019-11-22 11:57:17 +00:00
void setupBuilders();
void build();
private:
const cxxopts::ParseResult& results;
const DeviceInfo& deviceInfo;
const std::vector<Peripheral>& peripherals;
std::vector<std::unique_ptr<IBuilder>> builders;
std::stringstream outputStream;
};
#endif