At 06:36 PM 6/23/2001 -0500, Molitor, Stephen wrote:
>What's the best way to keep a watch of a variable or object in JDEBug?
>After expanding one of the local variables to the level I want, it collaspes
>again when I step to the next line.  I'd either like to keep the variable
>tree expanded, or set up a watch.  (Actually, both features would be nice).

Keeping the tree expanded from step to step is a relatively difficult 
programming problem and has the potential of greatly slowing down stepping. 
The JDE fetches the top-level values of the local variables at each time 
step. The JDE defers fetch the values of fields until you expand the field. 
Doing what you ask would require that the JDE keep for each local variable 
a record of the expanded state of its fields, including the states of 
children. If you expand the fields, the JDE would have to fetch the values 
of all the expanded fields. This could be very time-consuming.

As for watching a variable, there is a watch command on the JDE menu. It 
allows you to watch for access or modification of fields of objects. I 
don't think JPDA provides a means of monitoring local variables.

- Paul



>Sorry if this is a RTFM question, but I couldn't find the answer in the
>JDEBug User's Guide.
>
>Steve Molitor
>[EMAIL PROTECTED]

Reply via email to