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
|
|
|
|
{
|
2019-11-22 14:22:52 +00:00
|
|
|
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();
|
2019-12-02 09:47:01 +00:00
|
|
|
const std::stringstream& getStream() const;
|
2019-11-22 11:57:17 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
const cxxopts::ParseResult& results;
|
|
|
|
const DeviceInfo& deviceInfo;
|
|
|
|
const std::vector<Peripheral>& peripherals;
|
|
|
|
std::vector<std::unique_ptr<IBuilder>> builders;
|
|
|
|
std::stringstream outputStream;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|