public static StructureFormatter formatterWithoutPositions() { return new StructureFormatter(Collections.<Node, Collection<SourceStructure>>emptyMap(), false); }
@Override public void fail(String fail) { a("FAIL: " + fail); }
@Override public void buildBlock(Node node) { buildNode("B", node); }
@Override public String process(Source source, Node in) throws ConversionProblem { SourceFormatter formatter = positions ? StructureFormatter.formatterWithPositions() : StructureFormatter.formatterWithoutPositions(); in.accept(new SourcePrinter(formatter)); for (ParseProblem x : source.getProblems()) { formatter.addError(x.getPosition().getStart(), x.getPosition().getEnd(), x.getMessage()); } return formatter.finish(); } };
@Override public String process(Source source, Node in) throws ConversionProblem { SourceFormatter formatter = positions ? StructureFormatter.formatterWithPositions() : StructureFormatter.formatterWithoutPositions(); in.accept(new SourcePrinter(formatter)); for (ParseProblem x : source.getProblems()) { formatter.addError(x.getPosition().getStart(), x.getPosition().getEnd(), x.getMessage()); } return formatter.finish(); } };
@Override public void fail(String fail) { a("FAIL: " + fail); }
@Override public String process(Source source, Node in) throws ConversionProblem { SourceFormatter formatter = positions ? StructureFormatter.formatterWithPositions() : StructureFormatter.formatterWithoutPositions(); in.accept(new SourcePrinter(formatter)); for (ParseProblem x : source.getProblems()) { formatter.addError(x.getPosition().getStart(), x.getPosition().getEnd(), x.getMessage()); } return formatter.finish(); } };
public static StructureFormatter formatterWithPositions() { return new StructureFormatter(Collections.<Node, Collection<SourceStructure>>emptyMap(), true); }
@Override public void buildBlock(Node node) { buildNode("B", node); }
@Override public void fail(String fail) { a("FAIL: " + fail); }
public static StructureFormatter formatterWithoutPositions() { return new StructureFormatter(Collections.<Node, Collection<SourceStructure>>emptyMap(), false); }
@Override public void buildInline(Node node) { buildNode("I", node); }
@Override public void property(String name, Object value) { if (!propertySkipList.contains(currentType + "/" + name)) a("PROPERTY: %s = %s\n", name, value); }
public static StructureFormatter formatterWithPositions() { return new StructureFormatter(Collections.<Node, Collection<SourceStructure>>emptyMap(), true); }
@Override public void buildInline(Node node) { buildNode("I", node); }
@Override public void property(String name, Object value) { if (!propertySkipList.contains(currentType + "/" + name)) a("PROPERTY: %s = %s\n", name, value); }
public static StructureFormatter formatterWithPositions() { return new StructureFormatter(Collections.<Node, Collection<SourceStructure>>emptyMap(), true); }
@Override public void buildInline(Node node) { buildNode("I", node); }
@Override public void property(String name, Object value) { if (!propertySkipList.contains(currentType + "/" + name)) a("PROPERTY: %s = %s\n", name, value); }
public static StructureFormatter formatterWithoutPositions() { return new StructureFormatter(Collections.<Node, Collection<SourceStructure>>emptyMap(), false); }