/** {@inheritDoc} */ @Override protected int run(List<String> nonFlagArgs) throws Exception { if (mDo.equals("dump")) { dumpLayout(); } else if (mDo.equals("set")) { Preconditions.checkArgument(!mLayout.isEmpty(), "Specify the layout with --layout=path/to/layout.json"); setLayout(mFiji); } else if (mDo.equals("history")) { history(); } else { System.err.println("Unknown layout action: " + mDo); System.err.println("Specify the action to perform with --do=(dump|set|history)"); return FAILURE; } return SUCCESS; }