Читать книгу OCP Oracle Certified Professional Java SE 17 Developer Study Guide - Jeanne Boyarsky - Страница 77
If You Really Need to Use Two Classes with the Same Name
ОглавлениеSometimes you really do want to use Date
from two different packages. When this happens, you can pick one to use in the import
statement and use the other's fully qualified class name. Or you can drop both import
statements and always use the fully qualified class name.
public class Conflicts { java.util.Date date; java.sql.Date sqlDate; }