File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed
liquidjava-verifier/src/main/java/liquidjava/api Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change 11package liquidjava .api ;
22
3- import java .io .File ;
3+ import java .util .Arrays ;
4+ import java .util .List ;
45
56import liquidjava .errors .ErrorEmitter ;
67import liquidjava .processor .RefinementProcessor ;
@@ -18,8 +19,8 @@ public static void main(String[] args) {
1819 // In eclipse only needed this:"../liquidjava-example/src/main/java/"
1920 // In VSCode needs:
2021 // "../liquidjava/liquidjava-umbrella/liquidjava-example/src/main/java/liquidjava/test/project";
21- String file = args .length == 0 ? allPath : args [ 0 ] ;
22- ErrorEmitter ee = launch (file );
22+ List < String > files = args .length == 0 ? Arrays . asList ( allPath ) : Arrays . asList ( args ) ;
23+ ErrorEmitter ee = launch (files . toArray ( new String [ 0 ]) );
2324 System .out .println (ee .foundError () ? (ee .getFullMessage ()) : ("Correct! Passed Verification." ));
2425 }
2526
@@ -28,10 +29,12 @@ public static ErrorEmitter launchTest(String file) {
2829 return ee ;
2930 }
3031
31- public static ErrorEmitter launch (String file ) {
32- System .out .println ("Running LiquidJava on: " + file );
32+ public static ErrorEmitter launch (String ... files ) {
33+ System .out .println ("Running LiquidJava on: " + Arrays . toString ( files ) );
3334 Launcher launcher = new Launcher ();
34- launcher .addInputResource (file );
35+ for (String file : files ) {
36+ launcher .addInputResource (file );
37+ }
3538 launcher .getEnvironment ().setNoClasspath (true );
3639
3740 // Get the current classpath from the system
You can’t perform that action at this time.
0 commit comments