Debugger
public
class
Debugger
extends JdwpAgent
| java.lang.Object | ||
| ↳ | com.android.tradefed.device.server.jdwp.JdwpAgent | |
| ↳ | com.android.tradefed.device.server.Debugger | |
This represents a pending or established connection with a JDWP debugger.
Summary
Public constructors | |
|---|---|
Debugger(ClientImpl client)
Create a new Debugger object, configured to listen for connections on a specific port. |
|
Public methods | |
|---|---|
String
|
toString()
Represent the Debugger as a string. |
Protected methods | |
|---|---|
void
|
send(JdwpPacket packet)
Send a packet to the debugger. |
Public constructors
Debugger
public Debugger (ClientImpl client)
Create a new Debugger object, configured to listen for connections on a specific port.
| Parameters | |
|---|---|
client |
ClientImpl |
Public methods
toString
public String toString ()
Represent the Debugger as a string.
| Returns | |
|---|---|
String |
|
Protected methods
send
protected void send (JdwpPacket packet)
Send a packet to the debugger.
Ideally, we can do this with a single channel write. If that doesn't happen, we have to prevent anybody else from writing to the channel until this packet completes, so we synchronize on the channel.
Another goal is to avoid unnecessary buffer copies, so we write directly out of the JdwpPacket's ByteBuffer.
We must synchronize on "mChannel" before writing to it. We want to coordinate the buffered data with mChannel creation, so this whole method is synchronized.
| Parameters | |
|---|---|
packet |
JdwpPacket |