Hmm, I would have expected [1] (with terminating argument true) to have worked for your purposes.
Matt [1] http://commons.apache.org/proper/commons-lang/javadocs/api-3.1/org/apache/commons/lang3/reflect/FieldUtils.html#writeStaticField(java.lang.Class, java.lang.String, java.lang.Object, boolean) On Nov 22, 2013 3:49 AM, "Maurizio Cucchiara" <mcucchi...@apache.org> wrote: > Hi all, > > yesterday I was trying to write a static final field in order to mock > it and I realised that there is no way to do that using the Common > way. > > I expected to find something similar on FieldUtils class [1]. > > I know that is not a very good practice and in case of primitive field > or enabled security manager it is unlikely that works. > > But it seems a common pattern, so why do not include in Lang? > > Maurizio Cucchiara > > [1] > http://commons.apache.org/proper/commons-lang/javadocs/api-3.1/org/apache/commons/lang3/reflect/FieldUtils.html > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org > For additional commands, e-mail: dev-h...@commons.apache.org > >