That will import every class in the java package. And the number of classes in the java package is 0. That is not how import works, and you cannot import contents of packages by giving the names of their surrounding packages. It was designed that way, to deal with the situation where there are two classes in different packages with the same name.Ahmad Auada wrote:. . .
import java.*;
Stephan van Hulst wrote:Have people actually lost significant time because they had to look through the packages to find the right class? I hardly think so. Instead, the long lists of single imports just annoy me.
Jason Bullers wrote:but I'll never know which specific classes it depends on without reading all your code.
Stephan van Hulst wrote:I think I have yet to encounter the scenario where I need to know all types my type depends on, without needing to know where or how they are used
Jason Bullers wrote:my IDE does a great job of importing automatically when I auto complete.
"Il y a peu de choses qui me soient impossibles..."
Stephan van Hulst wrote:Personally I've never really understood the reason star imports are discouraged so much.