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