org.eclipse.cdt.debug.internal.core.model
Class CMemoryBlockExtension

java.lang.Object
  extended by org.eclipse.core.runtime.PlatformObject
      extended by org.eclipse.cdt.debug.internal.core.model.CDebugElement
          extended by org.eclipse.cdt.debug.internal.core.model.CMemoryBlockExtension
All Implemented Interfaces:
org.eclipse.cdt.debug.core.cdi.event.ICDIEventListener, ICDebugElement, ICDebugElementStatus, org.eclipse.core.runtime.IAdaptable, org.eclipse.debug.core.model.IDebugElement, org.eclipse.debug.core.model.IMemoryBlock, org.eclipse.debug.core.model.IMemoryBlockExtension

public class CMemoryBlockExtension
extends CDebugElement
implements org.eclipse.debug.core.model.IMemoryBlockExtension, org.eclipse.cdt.debug.core.cdi.event.ICDIEventListener

Represents a memory block in the CDI model.


Field Summary
 
Fields inherited from interface org.eclipse.cdt.debug.core.model.ICDebugElementStatus
ERROR, OK, WARNING
 
Constructor Summary
CMemoryBlockExtension(CDebugTarget target, java.math.BigInteger baseAddress, java.lang.String memorySpaceID)
          Constructor for CMemoryBlockExtension that supports memory spaces
CMemoryBlockExtension(CDebugTarget target, java.lang.String expression, java.math.BigInteger baseAddress)
          Constructor for CMemoryBlockExtension.
CMemoryBlockExtension(CDebugTarget target, java.lang.String expression, java.math.BigInteger baseAddress, int wordSize)
          Constructor for CMemoryBlockExtension.
 
Method Summary
 void connect(java.lang.Object object)
           
 void disconnect(java.lang.Object object)
           
 void dispose()
           
 java.lang.Object getAdapter(java.lang.Class adapter)
           
 int getAddressableSize()
           
 int getAddressSize()
           
 java.math.BigInteger getBigBaseAddress()
           
 java.math.BigInteger getBigLength()
           
 byte[] getBytes()
           
 org.eclipse.debug.core.model.MemoryByte[] getBytesFromAddress(java.math.BigInteger address, long length)
           
 org.eclipse.debug.core.model.MemoryByte[] getBytesFromOffset(java.math.BigInteger unitOffset, long addressableUnits)
           
 java.lang.Object[] getConnections()
           
 java.lang.String getExpression()
           
 long getLength()
           
 java.math.BigInteger getMemoryBlockEndAddress()
           
 org.eclipse.debug.core.model.IMemoryBlockRetrieval getMemoryBlockRetrieval()
           
 java.math.BigInteger getMemoryBlockStartAddress()
           
 java.lang.String getMemorySpaceID()
          Provides the memory space associated with this block if and only if the block was created with an address value + memory space qualifier.
 long getStartAddress()
           
 void handleDebugEvents(org.eclipse.cdt.debug.core.cdi.event.ICDIEvent[] events)
           
 void setBaseAddress(java.math.BigInteger address)
           
 void setValue(java.math.BigInteger offset, byte[] bytes)
           
 void setValue(long offset, byte[] bytes)
           
 boolean supportBaseAddressModification()
           
 boolean supportsChangeManagement()
           
 boolean supportsValueModification()
           
 
Methods inherited from class org.eclipse.cdt.debug.internal.core.model.CDebugElement
createChangeEvent, createCreateEvent, createResumeEvent, createSuspendEvent, createTerminateEvent, fireChangeEvent, fireCreationEvent, fireResumeEvent, fireSuspendEvent, fireTerminateEvent, getCDISession, getCDITarget, getCurrentStateInfo, getDebugTarget, getLaunch, getMessage, getModelIdentifier, getSeverity, getState, isOK, notSupported, requestFailed, requestFailed, targetRequestFailed, targetRequestFailed
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.debug.core.model.IDebugElement
getDebugTarget, getLaunch, getModelIdentifier
 

Constructor Detail

CMemoryBlockExtension

public CMemoryBlockExtension(CDebugTarget target,
                             java.lang.String expression,
                             java.math.BigInteger baseAddress)
Constructor for CMemoryBlockExtension.


CMemoryBlockExtension

public CMemoryBlockExtension(CDebugTarget target,
                             java.lang.String expression,
                             java.math.BigInteger baseAddress,
                             int wordSize)
Constructor for CMemoryBlockExtension.


CMemoryBlockExtension

public CMemoryBlockExtension(CDebugTarget target,
                             java.math.BigInteger baseAddress,
                             java.lang.String memorySpaceID)
Constructor for CMemoryBlockExtension that supports memory spaces

Method Detail

getExpression

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

getBigBaseAddress

public java.math.BigInteger getBigBaseAddress()
Specified by:
getBigBaseAddress in interface org.eclipse.debug.core.model.IMemoryBlockExtension

getAddressSize

public int getAddressSize()
Specified by:
getAddressSize in interface org.eclipse.debug.core.model.IMemoryBlockExtension

getAddressableSize

public int getAddressableSize()
                       throws org.eclipse.debug.core.DebugException
Specified by:
getAddressableSize in interface org.eclipse.debug.core.model.IMemoryBlockExtension
Throws:
org.eclipse.debug.core.DebugException

supportBaseAddressModification

public boolean supportBaseAddressModification()
Specified by:
supportBaseAddressModification in interface org.eclipse.debug.core.model.IMemoryBlockExtension

setBaseAddress

public void setBaseAddress(java.math.BigInteger address)
                    throws org.eclipse.debug.core.DebugException
Specified by:
setBaseAddress in interface org.eclipse.debug.core.model.IMemoryBlockExtension
Throws:
org.eclipse.debug.core.DebugException

getBytesFromOffset

public org.eclipse.debug.core.model.MemoryByte[] getBytesFromOffset(java.math.BigInteger unitOffset,
                                                                    long addressableUnits)
                                                             throws org.eclipse.debug.core.DebugException
Specified by:
getBytesFromOffset in interface org.eclipse.debug.core.model.IMemoryBlockExtension
Throws:
org.eclipse.debug.core.DebugException

getBytesFromAddress

public org.eclipse.debug.core.model.MemoryByte[] getBytesFromAddress(java.math.BigInteger address,
                                                                     long length)
                                                              throws org.eclipse.debug.core.DebugException
Specified by:
getBytesFromAddress in interface org.eclipse.debug.core.model.IMemoryBlockExtension
Throws:
org.eclipse.debug.core.DebugException

getMemoryBlockRetrieval

public org.eclipse.debug.core.model.IMemoryBlockRetrieval getMemoryBlockRetrieval()
Specified by:
getMemoryBlockRetrieval in interface org.eclipse.debug.core.model.IMemoryBlockExtension

handleDebugEvents

public void handleDebugEvents(org.eclipse.cdt.debug.core.cdi.event.ICDIEvent[] events)
Specified by:
handleDebugEvents in interface org.eclipse.cdt.debug.core.cdi.event.ICDIEventListener

getStartAddress

public long getStartAddress()
Specified by:
getStartAddress in interface org.eclipse.debug.core.model.IMemoryBlock

getLength

public long getLength()
Specified by:
getLength in interface org.eclipse.debug.core.model.IMemoryBlock

getBytes

public byte[] getBytes()
                throws org.eclipse.debug.core.DebugException
Specified by:
getBytes in interface org.eclipse.debug.core.model.IMemoryBlock
Throws:
org.eclipse.debug.core.DebugException

supportsValueModification

public boolean supportsValueModification()
Specified by:
supportsValueModification in interface org.eclipse.debug.core.model.IMemoryBlock

setValue

public void setValue(long offset,
                     byte[] bytes)
              throws org.eclipse.debug.core.DebugException
Specified by:
setValue in interface org.eclipse.debug.core.model.IMemoryBlock
Throws:
org.eclipse.debug.core.DebugException

setValue

public void setValue(java.math.BigInteger offset,
                     byte[] bytes)
              throws org.eclipse.debug.core.DebugException
Specified by:
setValue in interface org.eclipse.debug.core.model.IMemoryBlockExtension
Throws:
org.eclipse.debug.core.DebugException

supportsChangeManagement

public boolean supportsChangeManagement()
Specified by:
supportsChangeManagement in interface org.eclipse.debug.core.model.IMemoryBlockExtension

connect

public void connect(java.lang.Object object)
Specified by:
connect in interface org.eclipse.debug.core.model.IMemoryBlockExtension

disconnect

public void disconnect(java.lang.Object object)
Specified by:
disconnect in interface org.eclipse.debug.core.model.IMemoryBlockExtension

getConnections

public java.lang.Object[] getConnections()
Specified by:
getConnections in interface org.eclipse.debug.core.model.IMemoryBlockExtension

dispose

public void dispose()
Specified by:
dispose in interface org.eclipse.debug.core.model.IMemoryBlockExtension

getAdapter

public java.lang.Object getAdapter(java.lang.Class adapter)
Specified by:
getAdapter in interface org.eclipse.core.runtime.IAdaptable
Overrides:
getAdapter in class CDebugElement

getMemoryBlockStartAddress

public java.math.BigInteger getMemoryBlockStartAddress()
                                                throws org.eclipse.debug.core.DebugException
Specified by:
getMemoryBlockStartAddress in interface org.eclipse.debug.core.model.IMemoryBlockExtension
Throws:
org.eclipse.debug.core.DebugException

getMemoryBlockEndAddress

public java.math.BigInteger getMemoryBlockEndAddress()
                                              throws org.eclipse.debug.core.DebugException
Specified by:
getMemoryBlockEndAddress in interface org.eclipse.debug.core.model.IMemoryBlockExtension
Throws:
org.eclipse.debug.core.DebugException

getBigLength

public java.math.BigInteger getBigLength()
                                  throws org.eclipse.debug.core.DebugException
Specified by:
getBigLength in interface org.eclipse.debug.core.model.IMemoryBlockExtension
Throws:
org.eclipse.debug.core.DebugException

getMemorySpaceID

public java.lang.String getMemorySpaceID()
Provides the memory space associated with this block if and only if the block was created with an address value + memory space qualifier. If the block was created from an expression, this method should return null-- even if the target CDI backend supports memory spaces.

Returns:
a memory space ID or null expression