30 lines
572 B
C++
30 lines
572 B
C++
#include "WrongAnimal.hpp"
|
|
|
|
WrongAnimal::WrongAnimal() {
|
|
std::cout << "WrongAnimal born" << std::endl;
|
|
this->type = "WrongAnimal";
|
|
}
|
|
|
|
WrongAnimal::WrongAnimal(const WrongAnimal &other) {
|
|
*this = other;
|
|
}
|
|
|
|
WrongAnimal& WrongAnimal::operator=(const WrongAnimal &other) {
|
|
if (this != &other) {
|
|
this->type = other.type;
|
|
}
|
|
return (*this);
|
|
}
|
|
|
|
WrongAnimal::~WrongAnimal() {
|
|
std::cout << "WrongAnimal die" << std::endl;
|
|
}
|
|
|
|
std::string WrongAnimal::getType() const {
|
|
return type;
|
|
}
|
|
|
|
void WrongAnimal::makeSound() const {
|
|
std::cout << "WrongAnimal Sound" << std::endl;
|
|
}
|