From: Rhino on 26 May 2010 00:23 Arne Vajh�j <arne(a)vajhoej.dk> wrote in news:4bfafac8$0$278$14726298 @news.sunsite.dk: > On 24-05-2010 01:07, Rhino wrote: >> Lew<noone(a)lewscanon.com> wrote in news:htclj0$7p5$1(a)news.albasani.net: >>> Rhino wrote: >>>> For instance, if I have a constant named FOO_FILE_NAME and it is used >>>> only in class FooBlahBlah, is it better to leave the constant in >>>> FooBlahBlah rather than forcing developers to have to go to another >>>> class to determine (or change) its value? Or is it better to have all >>>> constants, wherever used, all together in FooConstants? >>> >>> I usually put static finals generally, and constants particularly, as >>> private in the class where they're needed, and give them wider access >>> only when needed as needed. YAGNI. >>> >> That's the second time I've seen YAGNI in the last few days but I still >> don't know what it means. I'm guessing it's something like YMMV, Your >> Mileage May Vary? > > http://en.wikipedia.org/wiki/YAGNI > > Arne Thank you! -- Rhino |