On 25 January 2013 14:51, Oleg Kalnichevski <[email protected]> wrote: > On Fri, 2013-01-25 at 14:12 +0000, sebb wrote: > > ... > >> > - String tokenstr = new String(base64codec.encode(token)); >> > + String tokenstr = new String(Base64.encodeBase64(token, >> > false)); >> >> This change means that the Base64 class will be recreated for each >> call (it is created internally) >> >> Would it not be better to change the final instance variable instead? >> > > I did not realize that static method created a new instance of the class > internally. This is certainly not optimal. Good catch! Thank you! I'll > get it fixed.
OK, no problem. I guess we ought to document that behaviour in Codec; I'll raise a JIRA > Oleg > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
