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.
18 lines
510 B
18 lines
510 B
import java.util.List;
|
|
import java.util.logging.Logger;
|
|
|
|
public class ExitCommand11 implements Command11 {
|
|
private static final Logger logger = Logger.getLogger(ExitCommand11.class.getName());
|
|
|
|
@Override
|
|
public String getName() {
|
|
return "exit";
|
|
}
|
|
|
|
@Override
|
|
public void execute(String[] args, List<Article11> articles) {
|
|
logger.info("用户执行 exit 命令,程序即将退出");
|
|
System.out.println("程序已安全退出!");
|
|
System.exit(0);
|
|
}
|
|
}
|