Thanks for the help, guys. I half-way worked it out.
Now, here's the new deal. I have my abstract class, NameableObject, implementing Comparable<NameableObject>. In this class, I have a String variable named 'name', and an updated equals() method that checks to see whether both NameableObjects have the same class, name, and hashcode. Now, here's the problem...
My compareTo(NameableObject o) method should, according to the javadocs, be consistent with equals(), such that (x.compareTo(y)==0) == (x.equals(y)). Now, this doesn't work for me because if I have two different classes that extends NameableObject with the same text in it's 'name' variable, they are not 'supposed' to be equal.
For example... I have a class named Developer and a class named Publisher. Both extend NameableObject. My overridden equals() method in the NameableObject class works since it detects that the classes are different (It returns false). When I
test my compareTo(NameableObject) method, I will get a return value of 0 when both 'name' variables are the same, but that is inconsistent with equals since they are of different types.
I guess what I'm really asking is if there is a way to have my compareTo() method consistent with equals() in this case. I would love to have my compareTo() method only compare with the parameter type for each class that uses it without generics, so i can find errors at compile time, but since the compareTo method is in the superclass with a NameableObject parameter in it already, Java will not let me implement another Comparable interface. The point is to have my NameableObject's compareTo() method good to go in terms of inheritance for all who extend it, but easier said than done!