You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
570 B

package command;
import view.ConsoleView;
import repository.PaperRepository;
public class ExitCommand implements Command {
private ConsoleView view;
public ExitCommand(ConsoleView view) {
this.view = view;
}
@Override
public void execute(String[] args, PaperRepository repository) {
view.showSuccess("程序已退出");
System.exit(0);
}
@Override
public String getDescription() {
return "退出程序";
}
@Override
public String getName() {
return "exit";
}
}