Search in sources :

Example 1 with BriefUnitPrinter

use of soot.BriefUnitPrinter in project soot by Sable.

the class GraphComparer method makeUnitPrinter.

/**
 * Utility method that returns a {@link LabeledUnitPrinter} for printing
 * the {@link Unit}s in graph.
 *
 * @param g the graph for which to return a {@link LabeledUnitPrinter}.
 * @return A {@link LabeledUnitPrinter} for printing the {@link Unit}s in
 * <tt>g</tt> if <tt>g</tt> is a control flow graph. Returns
 * <tt>null</tt> if <tt>g</tt> is not a control flow graph.
 */
private static LabeledUnitPrinter makeUnitPrinter(DirectedGraph g) {
    Body b = getGraphsBody(g);
    if (b == null) {
        return null;
    } else {
        BriefUnitPrinter printer = new BriefUnitPrinter(b);
        printer.noIndent();
        return printer;
    }
}
Also used : BriefUnitPrinter(soot.BriefUnitPrinter) Body(soot.Body)

Aggregations

Body (soot.Body)1 BriefUnitPrinter (soot.BriefUnitPrinter)1