rabbit-escape icon indicating copy to clipboard operation
rabbit-escape copied to clipboard

Enhancement: logcat for swing

Open colonelfazackerley opened this issue 9 years ago • 3 comments

I quite like Log.d() in android, but I want to use the same in swing. How about a Util.Log class for swing that behaves like android?

colonelfazackerley avatar Mar 28 '16 07:03 colonelfazackerley

What do you like about it? This is a reasonable idea but as ever I have opinions about how to do it.

andybalaam avatar Mar 28 '16 14:03 andybalaam

Can leave in the source code for debugging, but have it stripped at compile time or ignored at runtime. I also prefer typing "Log.d(" to "System.out.println(".

colonelfazackerley avatar Mar 28 '16 15:03 colonelfazackerley

How about log.d( ? I want the logger to be passed as an argument, not be global. (This makes testing easier, and prevents global state.)

andybalaam avatar Mar 30 '16 18:03 andybalaam