boolean (Object obj) { if (!(obj instanceof PackageEntry entry)) { return false; } return entry.myWithSubpackages == myWithSubpackages && entry.isStatic() == isStatic() && Objects.equals(entry.myPackageName, myPackageName); }