This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Are you trying to get a trace of your program? This may not be an elegant or sophisticated solution, but you can try the Trace demo program that comes with the jdk.
This is what you have to do.
-Assuming you are using jdk 1.6, extract the source files in demo\jpda\examples.jar -you can either use the jar utility or a file extractor that supports the zip format to extract -compile the classes under \com\sun\tools\example\trace. You may need to have \lib\tools.jar in your classpath for the compilation -Run your program as java com.sun.tools.example.trace.Trace HelloWorld. You need to have \lib\tools.jar. You can use the -output option to Trace, to send the trace to a file.