question: SortedSet < String > typesToImport ( ) { SortedSet < String > typesToImport = new TreeSet < String > ( ) ; for ( Map . Entry < String , Spelling > entry : imports . entrySet ( ) ) { if ( entry . getValue ( ) . importIt ) { typesToImport . add ( entry . getKey ( ) ) ; } } return typesToImport ; }
target:  Returns the set of types to import. We import every type that is neither in java.lang nor in the package containing the AutoCursor class, provided that the result refers to the type unambiguously. For example, if there is a property of type java.util.Map.Entry then we will import java.util.Map.Entry and refer to the property as Entry. We could also import just java.util.Map in this case and refer to Map.Entry, but currently we never do that.