Sun Studio 12 Update 1: Debugging a Program With dbx

Java Mode Syntax

print expression, ... | ...

Print the values of the expressions expression, ... or identifier identifier, ....

print -r expression | identifier

Print the value of expression or identifier including its inherited members.

print +r expression | identifier

Don’t print inherited members when the dbx output_inherited_members environment variable is on.

print -d [-r] expression | identifier

Show dynamic type of expression or identifier instead of static type.

print +d [-r] expression | identifier

Don’t use dynamic type of expression or identifier when the dbx output_dynamic_type environment variable is on.

print -- expression | identifier

”--’ signals the end of flag arguments. This is useful if expression may start with a plus or minus (see Program Scope for scope resolution rules.

where:

class_name is the name of a Java class, using either the package path (using period (.) as a qualifier; for example, test1.extra.T1.Inner) or the full path name (preceded by a pound sign (#) and using slash (/) and dollar sign ($) as qualifiers; for example, #test1/extra/T1$Inner). Enclose class_name in quotation marks if you use the $ qualifier.

expression is the Java expression whose value you want to print.

field_name is the name of a field in the class.

identifier is a local variable or parameter, including this, the current class instance variable (object_name.field_name) or a class (static) variable (class_name.field_name).

object_name is the name of a Java object.