Obtaining an instance of the Debug class  Turning off debugging in your application

Chapter 3: Troubleshooting

Turning on debugging in your application

To use the debug( ) method on the Debug object to turn on debugging within your application, add this call:

sybdebug.debug(true, [classes], [printstream]);

The classes parameter is a string that lists the specific classes you want to debug, separated by colons. For example:

sybdebug.debug(true,"MyClass")

and

sybdebug.debug(true,"MyClass:YourClass")

“STATIC” in the class string turns on debugging for all static methods in jConnect in addition to the designated classes. For example:

sybdebug.debug(true,"STATIC:MyClass")

You can specify “ALL” to turn on debugging for all classes. For example:

sybdebug.debug(true,"ALL"); 

The printstream parameter is optional. If you do not specify a printstream, the debug output goes to the output file you specified with DriverManager.setLogStream( ).





Copyright © 2003. Sybase Inc. All rights reserved. Turning off debugging in your application

View this book as PDF