Which is better?
@SuppressWarnings("unchecked")
@SuppressWarnings(AnnotationConstants.UNCHECKED)
Where AnnotationConstants
is a typical constants class...
public final class AnnotationConstants {
private AnnotationConstants() { }
public static final String UNCHECKED = "unchecked";
...
}
I know that there are a lot of general arguments for and against constants classes--and that's exactly what I'm not interested in. I want to know if a constants class specifically for annotations is a good idea or a bad idea.