public int compare(SourceFile o1,SourceFile o2){
  String n1=o1.getName();
  String n2=o2.getName();
  return n1.compareTo(n2);
}

public int compare ( SourceFile o1 , SourceFile o2 ) { String n1 = o1 . getName ( ) ; String n2 = o2 . getName ( ) ; return n1 . compareTo ( n2 ) ; }
comparator interface for sorting sourcefiles
