I am trying to create an EnumSet array (using Eclipse).
Version 1:
EnumSet mySet[] = new EnumSet[3];
This works, but I get a warning: "EnumSet is a raw type. References to generic type EnumSet should be parameterized".
Version 2 as suggested:
EnumSet<MyEnum> mySet[] = new EnumSet[3];
Again a warning: "Type safety: The expression of type EnumSet[] needs unchecked conversion to conform to EnumSet[]"
Version 3 as suggested:
EnumSet<MyEnum> mySet[] = new EnumSet<MyEnum>[3];
Now I get an error! "Cannot create a generic array of EnumSet"
What should I do? Will a not parameterized EnumSet have performance issues?