19 lines
576 B
C++
19 lines
576 B
C++
#include <iostream>
|
|
#include "SmartHome.h"
|
|
int main() {
|
|
SmartHome* nik = new SmartHome("SH");
|
|
Device* lig = new Light("ha","ja", true);
|
|
Device* device = new Device("haja", "lada");
|
|
Device* blind = new Blinds("bli", "ka", true);
|
|
Device* garage = new GarageDoor("dor", "dore", false);
|
|
Device* water = new WateringSistem("water", "sistem", 15698,12345);
|
|
|
|
nik->addDevice(lig);
|
|
nik->addDevice(device);
|
|
nik->addDevice(blind);
|
|
nik->addDevice(garage);
|
|
nik->addDevice(water);
|
|
std::cout << nik->toString();
|
|
delete nik;
|
|
return 0;
|
|
} |