001package headfirst.command.party;
002
003public class TVOnCommand implements Command {
004        TV tv;
005
006        public TVOnCommand(TV tv) {
007                this.tv= tv;
008        }
009
010        public void execute() {
011                tv.on();
012                tv.setInputChannel();
013        }
014
015        public void undo() {
016                tv.off();
017        }
018}