#include "house.h"

House::House(int constructionYear, bool isHistorical){
    this->constructionYear = constructionYear;
    this->isHistorical = isHistorical;
}

bool House::mustBeRestored(){
    return (this->constructionYear < 1923);
}

bool House::canBeDemolished(){
    return !this->isHistorical;
}

std::string House::toString(){
    return "House built in: " + std::to_string(this->constructionYear) + " which is " + (this->isHistorical ? "" : "not ") + "historical.";
}