Surfing on the source code of Java, I found the following declaration:
public abstract class Enum<E extends Enum<E>>
How should it be interpreted? I'm stuck with it...
Thank you.
You're not alone. Ken Arnold had this to say:
Or, to show the same point in brief, consider this: Enum is actually a generic class defined as Enum<T extends Enum<T>>. You figure it out. We gave up trying to explain it.
(from the blog entry Generics Considered Harmful)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With