This repository has been archived on 2022-11-20. You can view files and clone it, but cannot push or open issues or pull requests.
patterns/command/remoteundostatusmacro/tv.d

31 lines
473 B
D

module command.remoteundostatusmacro.tv;
import std.stdio : writeln;
class TV
{
private string location;
private int channel;
this(string location)
{
this.location = location;
}
void on()
{
writeln(location ~ " TV is on");
}
void off()
{
writeln(location ~ " TV is off");
}
void setInputChannel()
{
this.channel = 3;
writeln(location ~ " TV channel is set for DVD");
}
}