largetext icon indicating copy to clipboard operation
largetext copied to clipboard

Optional config setting for protection against accidental use of `toString()` during development

Open aliteralmind opened this issue 12 years ago • 4 comments

Please consider adding some sort of optional configuration setting, to protect against accidental use of toString(), which in the case of largetext is...LARGE TEXT. Although it is unlikely that this setting should affect a production environment, given the strict contracts of the CharSequence interface, it would be helpful to have something such as this available during development.

Thanks for considering!

aliteralmind avatar Apr 26 '14 00:04 aliteralmind

OK, this is a fair demand...

Two solutions here: a JVM option, and adding a method to LargeTextFactory.Builder to disable/enable regular .toString().

fge avatar Apr 26 '14 09:04 fge

OK, this did not make it into the first released version; however it will make it in the next.

fge avatar Apr 26 '14 22:04 fge

This fix doesn't appear to be in the 0.2.0 build which was released on May 16th. Why wasn't this fix included? Are you planning a 0.3.0 release with this fix?

seanrohead avatar Dec 09 '14 18:12 seanrohead

I do plan a release, yes, but not immediately. Right now I work on other projects...

Also, it is more complicated to implement than what I first thought, which doesn't help :(

fge avatar Dec 09 '14 18:12 fge