public class PHPThread extends PHPDebugElement implements IThread {
private PHPStackFrame[] frames; // The stackframes which belongs to this thread
- private PHPDebugTarget target; //
+ private PHPDebugTarget target; // This is doppel moppel, fTarget exists in PHPDebugElement
private String name; //
private int id; // The port number through which we communicate to DBG
+ private boolean fDebug = true;
private class State {
private boolean isSuspended = false;
*/
public IStackFrame[] getStackFrames () throws DebugException {
if (isSuspended()) {
+ if (fDebug) {
+ System.out.println ("PHPThread getStackFrames");
+ }
+
return ((PHPDebugTarget)getDebugTarget()).getStackFrames();
} else {
return new IStackFrame[0];
}
}
- public int getStackFramesSize () {
- return frames.length;
- }
+// public int getStackFramesSize () {
+// return frames.length;
+// }
public boolean hasStackFrames () {
if (frames == null) {
return target;
}
- public void setDebugTarget(PHPDebugTarget target) {
- this.target = target;
- }
+// public void setDebugTarget(PHPDebugTarget target) {
+// this.target = target;
+// }
public ILaunch getLaunch() {
return this.getDebugTarget().getLaunch();
DebugEvent ev;
state.setSuspended (false); // We will leave the suspended state
- this.frames = null; // Reset the stackframes
+ frames = null; // Reset the stackframes
ev = new DebugEvent (this, DebugEvent.RESUME, de); // Create an event resume by stepping
DebugPlugin.getDefault ().fireDebugEventSet (new DebugEvent[] { ev }); // Fire the event