#pragma once
#include "Settings.h"
#include "SMBios.h"
#include "Visitor.h"
#include "IComputer.h"
#include "Hardware.h"
#include <vector>
#include <memory>
#include "dll_macro.h"
struct innerComputer;
struct innerComputerInterface;

class DLL_API Computer : public IComputer{
public:
    Computer();
    Computer(Settings &settigs);

    Computer(std::shared_ptr<innerComputer> inner);
    ~Computer() override;

    bool isNull() const;

    bool operator==(const Computer&) const;
    std::vector<Hardware> getHardware() override;

    bool isBatteryEnabled() override;
    void setBatteryEnabled(bool);

    bool isControllerEnabled() override;
    void setControllerEnabled(bool);

    bool isCpuEnabled() override;
    void setCpuEnabled(bool);

    bool isGpuEnabled() override;
    void setGpuEnabled(bool);

    bool isMemoryEnabled() override;
    void setMemoryEnabled(bool);

    bool isMotherboardEnabled() override;
    void setMotherboardEnabled(bool);

    bool isNetworkEnabled() override;
    void setNetworkEnabled(bool);

    bool isPsuEnabled() override;
    void setPsuEnabled(bool);

    bool isStorageEnabled() override;
    void setStorageEnabled(bool);

    SMBios getSMBios();

    std::string GetReport() override;

    void Accept(Visitor* visitor) override;
    void Traverse(Visitor* visitor) override;

    void Open();
    void Close();
    void Reset();
private:
    std::shared_ptr<innerComputer> inner;
};
