"

2013 FRC Java API

"

com.sun.squawk.debugger
Class JDWPListener.CommandSet

java.lang.Object
  extended by com.sun.squawk.debugger.JDWPListener.CommandSet
Enclosing class:
JDWPListener

public abstract static class JDWPListener.CommandSet
extends Object

The implementation of each JDWP Command Set subclasses this class.


Field Summary
protected  CommandPacket command
          The command currently being processed.
protected  PacketInputStream in
          Stream from which data of current command is read.
protected  PacketOutputStream out
          Stream to which data in reply is written.
protected  ReplyPacket reply
          The reply to the current command.
 
Constructor Summary
JDWPListener.CommandSet()
           
 
Method Summary
protected abstract  boolean dispatch()
          Dispatches to the handler for the specific command in the command set.
protected  void error(int errorCode)
          Used by subclasses to change the error code sent in the reply.
 boolean handle(JDWPListener listener, CommandPacket command)
          Handles a command packet by setting up the variables used to interpret and reply to the command and then dispatching to the specific command handler.
protected  void postDispatch()
          A hook for the handler to do any post-processing after it has handled a command and the reply was sent (if applicable).
protected  void unimplemented()
          Reports that the JDWP/SDWP command is not (currently) implemented.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

command

protected CommandPacket command
The command currently being processed.


reply

protected ReplyPacket reply
The reply to the current command.


in

protected PacketInputStream in
Stream from which data of current command is read.


out

protected PacketOutputStream out
Stream to which data in reply is written.

Constructor Detail

JDWPListener.CommandSet

public JDWPListener.CommandSet()
Method Detail

handle

public final boolean handle(JDWPListener listener,
                            CommandPacket command)
                     throws IOException
Handles a command packet by setting up the variables used to interpret and reply to the command and then dispatching to the specific command handler.

Parameters:
listener - the listener to reply through
command - the command to be handled
Returns:
boolean true if the command was recognised and a reply was sent
Throws:
IOException - if there was an IO error while sending a reply

dispatch

protected abstract boolean dispatch()
                             throws IOException,
                                    SDWPException
Dispatches to the handler for the specific command in the command set.

Returns:
true if the handler generated a reply which must now be sent
Throws:
IOException - if an IO error occurs
SDWPException - if a JDWP/SDWP protocol error occurs

error

protected final void error(int errorCode)
Used by subclasses to change the error code sent in the reply.

Parameters:
errorCode - the new error code

unimplemented

protected final void unimplemented()
Reports that the JDWP/SDWP command is not (currently) implemented.


postDispatch

protected void postDispatch()
A hook for the handler to do any post-processing after it has handled a command and the reply was sent (if applicable).


"

2013 FRC Java API

"

"
For updated information see the Java FRC site
"