public static MultiValueResult multiValueResult() { return new MultiValueResult(); } }
public MultiValueResult with(String key, Object value) { put(key, value); return this; }
public void parseNode(String text, int level) { treeEntries.add(new MultiValueResult() .with("name", text) .with("level", level)); }
public MultiValueResult processTableFragment(String fragment, String actualData) throws Exception { String resultTable = processFragment(fragment, actualData); return multiValueResult() .with("expectedTableCommented", "<!--" + fragment + "-->") .with("resultTableCommented", "<!--" + resultTable + "-->") .with("resultTable", resultTable); } }
public Object checkExpression(String expression) { return new MultiValueResult() .with("simple", toTableText(isExpressionSupportedBy(simple, expression))) .with("ognl", toTableText(isExpressionSupportedBy(ognl, expression))); }
private MultiValueResult parseSingle(String single) { String[] words = single.substring(1, single.length() - 1).split(","); return multiValueResult() .with("firstName", words[0]) .with("lastName", words[1]) .with("age", words[2]); } }
public static MultiValueResult multiValueResult() { return new MultiValueResult(); } }
public MultiValueResult processRows(String template, String expectedRows, String actualData) throws Exception { String expectedTable = wrapRows(template, expectedRows); String resultTable = processFragment(expectedTable, actualData); String resultRows = unwrapRows(template, resultTable); return multiValueResult() .with("expectedTableCommented", "<!--" + expectedTable + "-->") .with("resultTableCommented", "<!--" + resultTable + "-->") .with("resultRows", resultRows); }
public MultiValueResult with(String key, Object value) { put(key, value); return this; }