/** Returns a string representation for the rule */ @Override public String toString() { String str = id + ": "; for (RuleCase theCase : cases) { if (!theCase.equals(cases.get(0))) { str += "\telse "; } str += theCase.toString() + "\n"; } if (!cases.isEmpty()) { str = str.substring(0, str.length() - 1); } return str; }