use of scenelib.annotations.el.AScene in project checker-framework by typetools.
the class AddAnnotatedFor method main.
/**
* Reads JAIF from the file indicated by the first element, or standard input if the argument
* array is empty; inserts any appropriate {@code @AnnotatedFor} annotations, based on the
* annotations defined in the input JAIF; and writes the augmented JAIF to standard output.
*/
public static void main(String[] args) throws IOException, DefException, ParseException {
AScene scene = new AScene();
String filename;
Reader r;
if (args.length > 0) {
filename = args[0];
r = new FileReader(filename);
} else {
filename = "System.in";
r = new InputStreamReader(System.in);
}
IndexFileParser.parse(new LineNumberReader(r), filename, scene);
scene.prune();
addAnnotatedFor(scene);
IndexFileWriter.write(scene, new PrintWriter(System.out, true));
}
Aggregations