com.borland.jbuilder.runtime
Interface JavaProcessListener


public interface JavaProcessListener

A JavaProcessListener receives notification from a JavaProcess under a variety of conditions.


Method Summary
 void javaProcessPaused(JavaProcess javaProcess)
          Sent when the Java process is under the control of a debugger and the process has been temporarily suspended.
 void javaProcessResumed(JavaProcess javaProcess)
          Indicates that the JavaProcess being monitored has resumed execution after being paused.
 void javaProcessSent(JavaProcess javaProcess, java.lang.String text, boolean error)
          Indicates that the JavaProcess being monitored has used System.out or System.err to produce console output.
 void javaProcessStarted(JavaProcess javaProcess)
          Indicates that a JavaProcess being monitored has successfully started.
 void javaProcessStopped(JavaProcess javaProcess, int exitCode)
          Indicates that the JavaProcess being monitored has terminated.
 

Method Detail

javaProcessStarted

public void javaProcessStarted(JavaProcess javaProcess)

Indicates that a JavaProcess being monitored has successfully started.

Parameters:
javaProcess - Identified the process.

javaProcessStopped

public void javaProcessStopped(JavaProcess javaProcess,
                               int exitCode)

Indicates that the JavaProcess being monitored has terminated. May be sent without a preceeding javaProcessStarted if an attempt to start a Java VM fails immediately.

Parameters:
javaProcess - Identified the process.
exitCode - The exit code returned by the Java VM. Typically zero on successful termination, this value will be -1 if the target VM failed to start at all.

javaProcessPaused

public void javaProcessPaused(JavaProcess javaProcess)

Sent when the Java process is under the control of a debugger and the process has been temporarily suspended. There is currently no corresponding notification when the process starts again.

Parameters:
javaProcess - Identified the process.

javaProcessSent

public void javaProcessSent(JavaProcess javaProcess,
                            java.lang.String text,
                            boolean error)

Indicates that the JavaProcess being monitored has used System.out or System.err to produce console output.

Parameters:
javaProcess - Identified the process that produced the output.
text - The actual series of characters sent, including end-of-line characters if appropriate. The process will not wait for a complete line before sending output to accomodate applications that perform typical console interaction with the user where a prompt for input may not contain end-of-line characters.
error - True if the output was sent to System.err, false if it used System.out.

javaProcessResumed

public void javaProcessResumed(JavaProcess javaProcess)

Indicates that the JavaProcess being monitored has resumed execution after being paused.

Parameters:
javaProcess - Identified the process that produced the output.