Here is the logger initialization:
Logger l = Logger.getInstance();
Now, where you need, you can call:
l.write( Tag.DEBUG, "xxxx" );
to write a DEBUG string on Standard out.
When you put your code in production, you can set this Logger to exclude DEBUG log:
l.disableTag( Tag.DEBUG );
and change the out stream on File (for example):
l.setPrintStream(new PrintStream(new File("path/to/file.log")));