org.eclipse.emf.mwe.internal.ui.debug.model
Class DebugTarget

java.lang.Object
  extended by org.eclipse.core.runtime.PlatformObject
      extended by org.eclipse.emf.mwe.internal.ui.debug.model.DebugElement
          extended by org.eclipse.emf.mwe.internal.ui.debug.model.DebugTarget
All Implemented Interfaces:
org.eclipse.core.runtime.IAdaptable, org.eclipse.debug.core.IBreakpointListener, org.eclipse.debug.core.model.IDebugElement, org.eclipse.debug.core.model.IDebugTarget, org.eclipse.debug.core.model.IDisconnect, org.eclipse.debug.core.model.IMemoryBlockRetrieval, org.eclipse.debug.core.model.ISuspendResume, org.eclipse.debug.core.model.ITerminate

public class DebugTarget
extends DebugElement
implements org.eclipse.debug.core.model.IDebugTarget

MWE Debug Target implementation
It holds the debug threads. There is only one thread in the MWE debug model.
It holds also a variable values cache.
For Info: A debug target handles the suspend, resume, terminate commands and the breakpoint handling.


Field Summary
protected  boolean suspended
           
 
Fields inherited from class org.eclipse.emf.mwe.internal.ui.debug.model.DebugElement
target
 
Method Summary
 void breakpointAdded(org.eclipse.debug.core.model.IBreakpoint breakpoint)
           
 void breakpointChanged(org.eclipse.debug.core.model.IBreakpoint breakpoint, org.eclipse.core.resources.IMarkerDelta delta)
           
 void breakpointRemoved(org.eclipse.debug.core.model.IBreakpoint breakpoint, org.eclipse.core.resources.IMarkerDelta delta)
           
 boolean canDisconnect()
           
 boolean canResume()
           
 boolean canSuspend()
           
 boolean canTerminate()
           
 void disconnect()
           
 DebugModelManager getDebugModelManager()
           
 DebugValue getDebugValue(VarValueTO varTO)
           
 org.eclipse.debug.core.ILaunch getLaunch()
           
 org.eclipse.debug.core.model.IMemoryBlock getMemoryBlock(long startAddress, long length)
           
 java.lang.String getName()
           
 org.eclipse.debug.core.model.IProcess getProcess()
           
 DebugThread getThread()
           
 org.eclipse.debug.core.model.IThread[] getThreads()
           
 boolean hasThreads()
           
 void installDeferredBreakpoints()
           
 boolean isDisconnected()
           
 boolean isSuspended()
           
 boolean isTerminated()
           
static DebugTarget newDebugTarget(org.eclipse.debug.core.ILaunch launch, org.eclipse.debug.core.model.IProcess process, Connection conn)
           
 void removeThread()
           
 void resume()
           
 void setSuspended(boolean value)
           
 void setVariablesDirty()
           
 boolean supportsBreakpoint(org.eclipse.debug.core.model.IBreakpoint breakpoint)
           
 boolean supportsStorageRetrieval()
           
 void suspend()
           
 void terminate()
           
 void updateDebugValues(java.util.List<VarValueTO> vars)
           
 
Methods inherited from class org.eclipse.emf.mwe.internal.ui.debug.model.DebugElement
getAdapter, getDebugTarget, getDebugTarget0, getModelIdentifier
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.debug.core.model.IDebugElement
getDebugTarget, getModelIdentifier
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 

Field Detail

suspended

protected boolean suspended
Method Detail

newDebugTarget

public static DebugTarget newDebugTarget(org.eclipse.debug.core.ILaunch launch,
                                         org.eclipse.debug.core.model.IProcess process,
                                         Connection conn)
                                  throws org.eclipse.core.runtime.CoreException
Throws:
org.eclipse.core.runtime.CoreException

getLaunch

public org.eclipse.debug.core.ILaunch getLaunch()
Specified by:
getLaunch in interface org.eclipse.debug.core.model.IDebugElement
Overrides:
getLaunch in class DebugElement

getProcess

public org.eclipse.debug.core.model.IProcess getProcess()
Specified by:
getProcess in interface org.eclipse.debug.core.model.IDebugTarget

getThreads

public org.eclipse.debug.core.model.IThread[] getThreads()
Specified by:
getThreads in interface org.eclipse.debug.core.model.IDebugTarget

getThread

public DebugThread getThread()

removeThread

public void removeThread()

hasThreads

public boolean hasThreads()
Specified by:
hasThreads in interface org.eclipse.debug.core.model.IDebugTarget

getName

public java.lang.String getName()
Specified by:
getName in interface org.eclipse.debug.core.model.IDebugTarget

getDebugModelManager

public DebugModelManager getDebugModelManager()
Overrides:
getDebugModelManager in class DebugElement

getDebugValue

public DebugValue getDebugValue(VarValueTO varTO)

updateDebugValues

public void updateDebugValues(java.util.List<VarValueTO> vars)

canResume

public boolean canResume()
Specified by:
canResume in interface org.eclipse.debug.core.model.ISuspendResume

canSuspend

public boolean canSuspend()
Specified by:
canSuspend in interface org.eclipse.debug.core.model.ISuspendResume

isSuspended

public boolean isSuspended()
Specified by:
isSuspended in interface org.eclipse.debug.core.model.ISuspendResume

resume

public void resume()
            throws org.eclipse.debug.core.DebugException
Specified by:
resume in interface org.eclipse.debug.core.model.ISuspendResume
Throws:
org.eclipse.debug.core.DebugException

suspend

public void suspend()
             throws org.eclipse.debug.core.DebugException
Specified by:
suspend in interface org.eclipse.debug.core.model.ISuspendResume
Throws:
org.eclipse.debug.core.DebugException

setSuspended

public void setSuspended(boolean value)

setVariablesDirty

public void setVariablesDirty()

installDeferredBreakpoints

public void installDeferredBreakpoints()

supportsBreakpoint

public boolean supportsBreakpoint(org.eclipse.debug.core.model.IBreakpoint breakpoint)
Specified by:
supportsBreakpoint in interface org.eclipse.debug.core.model.IDebugTarget

breakpointAdded

public void breakpointAdded(org.eclipse.debug.core.model.IBreakpoint breakpoint)
Specified by:
breakpointAdded in interface org.eclipse.debug.core.IBreakpointListener

breakpointRemoved

public void breakpointRemoved(org.eclipse.debug.core.model.IBreakpoint breakpoint,
                              org.eclipse.core.resources.IMarkerDelta delta)
Specified by:
breakpointRemoved in interface org.eclipse.debug.core.IBreakpointListener

breakpointChanged

public void breakpointChanged(org.eclipse.debug.core.model.IBreakpoint breakpoint,
                              org.eclipse.core.resources.IMarkerDelta delta)
Specified by:
breakpointChanged in interface org.eclipse.debug.core.IBreakpointListener

canTerminate

public boolean canTerminate()
Specified by:
canTerminate in interface org.eclipse.debug.core.model.ITerminate

isTerminated

public boolean isTerminated()
Specified by:
isTerminated in interface org.eclipse.debug.core.model.ITerminate

terminate

public void terminate()
               throws org.eclipse.debug.core.DebugException
Specified by:
terminate in interface org.eclipse.debug.core.model.ITerminate
Throws:
org.eclipse.debug.core.DebugException

canDisconnect

public boolean canDisconnect()
Specified by:
canDisconnect in interface org.eclipse.debug.core.model.IDisconnect

disconnect

public void disconnect()
Specified by:
disconnect in interface org.eclipse.debug.core.model.IDisconnect

isDisconnected

public boolean isDisconnected()
Specified by:
isDisconnected in interface org.eclipse.debug.core.model.IDisconnect

supportsStorageRetrieval

public boolean supportsStorageRetrieval()
Specified by:
supportsStorageRetrieval in interface org.eclipse.debug.core.model.IMemoryBlockRetrieval

getMemoryBlock

public org.eclipse.debug.core.model.IMemoryBlock getMemoryBlock(long startAddress,
                                                                long length)
Specified by:
getMemoryBlock in interface org.eclipse.debug.core.model.IMemoryBlockRetrieval