src/main/java/ch/uzh/ifi/seal/ase/cscc/RecommenderHelper.java
public void printSSTsAndInvocationExpressions() {
        MutableInt invocationExpressionCount = new MutableInt(0);
        List<String> zips = IoHelper.findAllZips(contextsDir);
        int zipsTotal = getNumZips(zips);
        int zipCount = 0;
        for (String zip : zips) {
            if (++zipCount > zipsTotal) break;
            int ctxCount = 1;
            System.out.println("Processing " + zip);
            IReadingArchive ra = new ReadingArchive(new File(zip));
            while (ra.hasNext()) {
                Context ctx = ra.getNext(Context.class);
                // print SST
                ISST sst = ctx.getSST();
                System.out.println("================\nSST " + zipCount + "-" + ctxCount + ":\n================\n" + sst.toString());
                // print invocation expressions found by visitor
                System.out.println("================\nINVOCATION EXPRESSIONS " + zipCount + "-" + ctxCount + ":\n================\n");
                sst.accept(new InvocationExpressionVisitor(), invocationExpressionCount);
                ctxCount++;
            }
            ra.close();
        }
        System.out.println("Total #InvocationExpressions: " + invocationExpressionCount);
    }
/**
     * Helper method which prints out SSTs to console. Can be useful to get an idea of how the SSTs are structured.
     * It also prints the InvocationExpressions (= method calls), which is what we're interested in.
     */
Helper method which prints out SSTs to console. Can be useful to get an idea of how the SSTs are structured.
It also prints the InvocationExpressions (= method calls), which is what we're interested in.
Helper method which prints out SSTs to console . Can be useful to get an idea of how the SSTs are structured . It also prints the InvocationExpressions ( = method calls ) which is what we ' re interested in .
public void printSSTsAndInvocationExpressions() {
        MutableInt invocationExpressionCount = new MutableInt(0);
        List<String> zips = IoHelper.findAllZips(contextsDir);
        int zipsTotal = getNumZips(zips);
        int zipCount = 0;
        for (String zip : zips) {
            if (++zipCount > zipsTotal) break;
            int ctxCount = 1;
            System.out.println("Processing " + zip);
            IReadingArchive ra = new ReadingArchive(new File(zip));
            while (ra.hasNext()) {
                Context ctx = ra.getNext(Context.class);
                ISST sst = ctx.getSST();
                System.out.println("================\nSST " + zipCount + "-" + ctxCount + ":\n================\n" + sst.toString());
                System.out.println("================\nINVOCATION EXPRESSIONS " + zipCount + "-" + ctxCount + ":\n================\n");
                sst.accept(new InvocationExpressionVisitor(), invocationExpressionCount);
                ctxCount++;
            }
            ra.close();
        }
        System.out.println("Total #InvocationExpressions: " + invocationExpressionCount);
    }
public void printSSTsAndInvocationExpressions ( ) { MutableInt invocationExpressionCount = new MutableInt ( 0 ) ; List < String > zips = IoHelper . findAllZips ( contextsDir ) ; int zipsTotal = getNumZips ( zips ) ; int zipCount = 0 ; for ( String zip : zips ) { if ( ++ zipCount > zipsTotal ) break ; int ctxCount = 1 ; System . out . println ( "Processing " + zip ) ; IReadingArchive ra = new ReadingArchive ( new File ( zip ) ) ; while ( ra . hasNext ( ) ) { Context ctx = ra . getNext ( Context . class ) ; ISST sst = ctx . getSST ( ) ; System . out . println ( "================\nSST " + zipCount + "-" + ctxCount + ":\n================\n" + sst . toString ( ) ) ; System . out . println ( "================\nINVOCATION EXPRESSIONS " + zipCount + "-" + ctxCount + ":\n================\n" ) ; sst . accept ( new InvocationExpressionVisitor ( ) , invocationExpressionCount ) ; ctxCount ++ ; } ra . close ( ) ; } System . out . println ( "Total #InvocationExpressions: " + invocationExpressionCount ) ; }
Helper method which prints out SSTs to console.
Helper method which prints out SSTs to console .
// print SST
 // print invocation expressions found by visitor
