private void addFinishToStart() {
	follow.get(grammar.getProductions().get(0).getName()).add(FinishTerminal.getInstance());
    }
private void addFinishToStart ( ) { follow . get ( grammar . getProductions ( ) . get ( 0 ) . getName ( ) ) . add ( FinishTerminal . getInstance ( ) ) ; }
This method ass the finish construction to the start symbol. If a start
symbol is defined by StartProduction this construction is used. If the there
is no such production, the fist production is used.

This is rule 1 from Dragon book:

1) Platzieren Sie $ in FOLLOW(S), wobei S das Startsymbol und $ die rechte
Endmarkierung fuer die Eingabe sind.