Article View: borland.public.jbuilder.debugger
Article #5159Help debugging, please
From: A.G.
Date: Sun, 08 Nov 1998 00:00
Date: Sun, 08 Nov 1998 00:00
53 lines
2248 bytes
2248 bytes
Hi All:
After complete frustraion with Java Workshop, I went to my college bookstore
and bought Borland JBuilder 2. :) I love it even though I have been using it
for a couple of days only!
One thing that I can't get to work is debugging. I think that I'm missing a
point somewhere. I am doing just simple programs in Java, that have no
graphical interface or anything complicated. (I'm into introductory course
so far).
Example: a simple program that prints "hello" to the screen, reads a line
from standard input, and prints it out as well. It runs OK, but I want to
use debugger on it to understand how it works.
It brings out console window and 'hangs'. I have no idea what it waits for,
cause the 'trace into' and 'step over' and 'play' buttons are greyed out,
and only 'pause' and 'stop' available. But if I press Enter, it unfreezes,
and prints "hello" to execution log, and opens debug pane with 2 threads in
it. (I'm sorry, but I am still unsure what these threads are.) That's where
it ends. :( although 'play', 'trace in', 'step over' are available, clicking
them always brings me to the same point (see below).
To the left of the debug pane in the source window there is source of
FileInputStream.java, with highlited line over
return readBytes(b, off, len);
Nothing I am doing moves me further in debugging process. I am clueless.
Please help.
Thank you in advance,
Arcady
Here's the source I am doing this on:
package Test2;
import java.io.*;
class Test2 {
private static BufferedReader br =
new BufferedReader(new InputStreamReader(System.in));
public static void main(String[] args) throws IOException {
System.out.println ("hello!!!");
String aWord = br.readLine();
System.out.println ( aWord );
}
}
Technical Details
Message-ID:
<723f5n$oud1@forums.borland.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: ff5c5,202f7469c46e2a89,start X-Google-Attributes: gidff5c5,public From: "A.G." <my_box@usa.net> Subject: Help debugging, please Date: 1998/11/08 Message-ID: <723f5n$oud1@forums.borland.com> X-Deja-AN: 409563105 Organization: Another Netscape Collabra Server User X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3155.0 Newsgroups: borland.public.jbuilder.debugger