FailCommand負責報告錯誤
java代碼
class FailCommand implements Command{
private final String msg;
public Object execute(CommandContext ctxt){
throw new CommandException(msg);
}
FailCommand (String msg){this
}
如此等等
但是
我們最需要的
而組合
[
From:http://tw.wingwit.com/Article/program/Java/ky/201311/29271.html