如何判断 Java 导入语句何时使用通配符匹配?
How can you tell when a Java import statement uses wildcard matching?
我问了一个previous question which is apparently a duplicate of this question。我一直认为星号是在导入语句中表示通配符匹配的唯一方式。
导致任一导入语句的原因
import android.util.Log;
或
import android.os.Environment;
被解释为可以匹配多个包的模式?还是有其他我不明白的通配符匹配定义?
请帮忙!
I always thought that asterisks were the only way to denote wildcard matching in import statements.
他们是。
What causes either of the import statements import android.util.Log;
or
import android.os.Environment;
to be interpreted as patterns that could match multiple packages?
没有。他们不是。
Or is there some other definition of wildcard matching that I don't understand?
本身不是。
但是看看你的另一个问题,似乎真正的问题是编译 InetAddress.java
时使用的类路径。
我问了一个previous question which is apparently a duplicate of this question。我一直认为星号是在导入语句中表示通配符匹配的唯一方式。
导致任一导入语句的原因
import android.util.Log;
或
import android.os.Environment;
被解释为可以匹配多个包的模式?还是有其他我不明白的通配符匹配定义?
请帮忙!
I always thought that asterisks were the only way to denote wildcard matching in import statements.
他们是。
What causes either of the import statements
import android.util.Log;
orimport android.os.Environment;
to be interpreted as patterns that could match multiple packages?
没有。他们不是。
Or is there some other definition of wildcard matching that I don't understand?
本身不是。
但是看看你的另一个问题,似乎真正的问题是编译 InetAddress.java
时使用的类路径。