Hi all! I think this rule is all right. A real constant value (like PI) should be declared as static final, which could be named in an all caps fashion without violating the rule. In my opinion this rule is also a good safety net: if you declare a constant without static, you might end up with a lot of unnecessary value with each instance you have (and if you need multiple instances of the value, then they are not true constants either eg. POJOs).
Regards: Andras On Mon, Jul 11, 2022 at 9:47 PM Wei-Chiu Chuang <[email protected]> wrote: > I have seen violated that rule before and wondered if it's because final > variables are essentially constants in other languages so all caps make > sense? > > On Mon, Jul 11, 2022 at 10:35 AM Owen O'Malley <[email protected]> > wrote: > > > I keep stubbing my toe on the unfortunate Hadoop style rule that says > final > > variables can't be all caps. :( Does this frustrate anyone else? > > > > .. Owen > > >
