Which is better?
1. `@SuppressWarnings("unchecked")`
2. `@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.
以上就是Should I make a constants class for my annotations?的详细内容,更多请关注web前端其它相关文章!