Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.0.0)

E17493-01

javax.ide.debug
Class Debugger

java.lang.Object
  extended by javax.ide.Service
      extended by javax.ide.debug.Debugger

public abstract class Debugger
extends Service

The Debugger can be used to start the debuggee or to retrieve command line options so the extension can start the debuggee itself.

IDE providers must provide an implementation of getClientConnector( Context ) and getServerConnector(Context).


Constructor Summary
Debugger()
           
 
Method Summary
abstract  ClientConnector getClientConnector(Context context)
          Creates a client connector for a debugging session.
static Debugger getDebugger()
          Get the debugger implementation for this IDE.
abstract  ServerConnector getServerConnector(Context context)
          Creates a server connector for a debugging session.
 
Methods inherited from class javax.ide.Service
getService, initialize, resetAllServices
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Debugger

public Debugger()
Method Detail

getServerConnector

public abstract ServerConnector getServerConnector(Context context)
                                            throws java.lang.UnsupportedOperationException
Creates a server connector for a debugging session. The ServerConnector object returned can be used to start the debuggee or to retrieve command line options so the extension can start the debuggee itself. If the extension wants to start the the debuggee itself, it should call Connector.getOptions() to retrieve the command line options that it should use to start the debuggee. If the extension wants to start a third party container (such as Tomcat, WebLogic, Avalon based systems, properietary based systems, etc.), it can ignore options that are specific to the IDE's preferred container (for example, the extension may ignore the values corresponding to the Connector.OPTION_MAIN_CLASS key). The extension should not ignore the values corresponding to the Connector.OPTION_DEBUG_FIRST and Connector.OPTION_DEBUG_LAST keys, as these are dictated by the IDE so that the debugger will be able connect with the debuggee. If the extension wants the IDE to start the debuggee, it should call Connector.startDebuggee(Map). The returned Connector will implement ServerConnector. The extension writer should call ServerConnector.startListening() to start the debugger listening, and then the extension should either start the debuggee process or tell the IDE to do so by calling Connector.startDebuggee(Map). When the debuggee process is launched, the listening debugger will automatically accept the connection.

Parameters:
context - the current Context.
Returns:
the debugger connector
Throws:
java.lang.UnsupportedOperationException - if the IDE does not support the debugger as server.

getClientConnector

public abstract ClientConnector getClientConnector(Context context)
                                            throws java.lang.UnsupportedOperationException
Creates a client connector for a debugging session. The ClientConnector object returned can be used to start the debuggee or to retrieve command line options so the extension can start the debuggee itself. If the extension wants to start the the debuggee itself, it should call Connector.getOptions() to retrieve the command line options that it should use to start the debuggee. If the extension wants to start a third party container (such as Tomcat, WebLogic, Avalon based systems, properietary based systems, etc.), it can ignore options that are specific to the IDE's preferred container (for example, the extension may ignore the values corresponding to the Connector.OPTION_MAIN_CLASS key). The extension should not ignore the values corresponding to the Connector.OPTION_DEBUG_FIRST and Connector.OPTION_DEBUG_LAST keys, as these are dictated by the IDE so that the debugger will be able connect with the debuggee. If the extension wants the IDE to start the debuggee, it should call Connector.startDebuggee(Map). The returned Connector will implement ClientConnector. The extension writer should either start the debuggee process or tell the IDE to do so by calling Connector.startDebuggee(Map), and then the extension writer should call ClientConnector.attachDebugger() to tell the debugger to attach to the debuggee.

Parameters:
context - the current Context.
Returns:
the debugger connector
Throws:
java.lang.UnsupportedOperationException - if the IDE does not support debugger as client.

getDebugger

public static Debugger getDebugger()
Get the debugger implementation for this IDE.

Returns:
the debugger implementation.

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.0.0)

E17493-01

Copyright © 1997, 2011, Oracle. All rights reserved.