I agree. Here is the impact on the implementation.
First, equals/hashcode cannot depend on internals of their class, instead they must be implemented in terms of the public methods of the java model interface. JavaClassImplOne and JavaClassImplTwo would have different internal variables.
Second, equals cannot fail if the compared objects are not the same class, e.g. JavaClassImplOne and JavaClassImplTwo. e.g., use other.isAssignable(JavaClass.class).
Third, equals/hashcode implementations that depend only on the methods of the java model api would probably not belong in the impl package. They would probably be better located in the api package. Then JavaClassImplTwo would not have to depend on impl.JavaClass to share equals/hashcode. This would mean that some interfaces in api package would have to be abstract classes.
Others?
Thoughts?
Regards,
John