|
Eclipse Platform Release 3.1 |
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Extensions to IMemoryBlock
. Allows
for bytes to be accessed in a larger address space, and for state information
to be provided for each byte.
Clients may optionally implement this interface when providing implementations of
IMemoryBlock
.
MemoryByte
Method Summary | |
---|---|
void |
connect(Object client)
Connects the given client to this memory block. |
void |
disconnect(Object client)
Disconnects the given client from this memory block. |
void |
dispose()
Dispose this memory block. |
int |
getAddressableSize()
Returns this memory block's addressable size in number of bytes. |
int |
getAddressSize()
Returns the address size of this memory block in number of bytes. |
BigInteger |
getBigBaseAddress()
Returns the base address of this memory block as a big integer. |
BigInteger |
getBigLength()
Returns the length of this memory block, or -1 if unbounded. |
MemoryByte[] |
getBytesFromAddress(BigInteger address,
long units)
Returns bytes from this memory block based on the given address and the addressable size of this memory block. |
MemoryByte[] |
getBytesFromOffset(BigInteger unitOffset,
long addressableUnits)
Returns bytes from this memory block based on the base address and addressable size of this memory block. |
Object[] |
getConnections()
Returns the possibly empty list of clients currently connected to this memory block. |
String |
getExpression()
Returns the expression used to create this memory block. |
BigInteger |
getMemoryBlockEndAddress()
Returns the hard end address of this memory block as a big integer, or null if none. |
IMemoryBlockRetrieval |
getMemoryBlockRetrieval()
Returns the origin of this memory block. |
BigInteger |
getMemoryBlockStartAddress()
Returns the hard start address of this memory block as a big integer, or null if none. |
void |
setBaseAddress(BigInteger address)
Sets the base address of this memory block to the given address. |
void |
setValue(BigInteger offset,
byte[] bytes)
Sets bytes in this memory block at the specified offset within this memory block to the spcified bytes. |
boolean |
supportBaseAddressModification()
Returns whether the base address of this memory block can be modified. |
boolean |
supportsChangeManagement()
Returns whether this memory block manages the change state of its bytes. |
Methods inherited from interface org.eclipse.debug.core.model.IMemoryBlock |
---|
getBytes, getLength, getStartAddress, setValue, supportsValueModification |
Methods inherited from interface org.eclipse.debug.core.model.IDebugElement |
---|
getDebugTarget, getLaunch, getModelIdentifier |
Methods inherited from interface org.eclipse.core.runtime.IAdaptable |
---|
getAdapter |
Method Detail |
public String getExpression()
public BigInteger getBigBaseAddress() throws DebugException
DebugException
- if unable to retreive the base addresspublic BigInteger getMemoryBlockStartAddress() throws DebugException
null
if none. A null
start address indicates that
memory may be retrieved at any address less than this memory block's base
address.
null
DebugException
- if unable to retrieve the start address of this memory block.public BigInteger getMemoryBlockEndAddress() throws DebugException
null
if none. A null
end address indicates that
memory may be retrieved from any positive offset relative to the base address
of this memory block.
null
DebugException
- if unable to retrieve the end address of this memory block.public BigInteger getBigLength() throws DebugException
null
).
DebugException
- if unable to retrieve the length of this memory block.public int getAddressSize() throws DebugException
DebugException
- if unable to retrieve the address sizepublic boolean supportBaseAddressModification() throws DebugException
DebugException
- is unable to determine if base address modification is supportedpublic boolean supportsChangeManagement()
If a memory block manages changes the memory block is responsible for
setting the CHANGED
state of its MemoryByte
's
returned from getBytesFromAddress
and
getBytesFromOffset
. The changed state of a byte should
be updated each time a thread suspends in a memory block's target.
public void setBaseAddress(BigInteger address) throws DebugException
address
- new base address
DebugException
- if unable to modify the base address, or modification
of the base address failspublic MemoryByte[] getBytesFromOffset(BigInteger unitOffset, long addressableUnits) throws DebugException
A memory block may be asked to retrieve bytes beyond it's start
or end address. If a memory block is unable to retrieve memory outside
these boundaries, implementations should return memory bytes with
the READABLE
bit turned off for each byte outside
the of the accessible range. An exception should not be thrown in this
case.
unitOffset
- zero based offset into this memory block at which to start
retrieving bytes in terms of addressable units. Client should retrieve
memory starting from "base address + offset".addressableUnits
- the number of addressable units to retrieve
units
* getAddressableSize()
.
DebugException
- if unable to retrieve the specified bytes due to
a failure communicating with the targetMemoryByte
public MemoryByte[] getBytesFromAddress(BigInteger address, long units) throws DebugException
A memory block may be asked to retrieve bytes beyond it's start
or end address. If a memory block is unable to retrieve memory outside
these boundaries, implementations should return memory bytes with
the READABLE
bit turned off for each byte outside
the of the accessible range. An exception should not be thrown in this
case.
address
- address at which to begin retrieving bytes in terms
of addressable unitsunits
- is the number of addressable units of memory to retrieve
units
* getAddressableSize()
.
DebugException
- if unable to retrieve the specified bytes due to
a failure communicating with the targetMemoryByte
public void setValue(BigInteger offset, byte[] bytes) throws DebugException
CHANGE
.
offset
- the zero based offset at which to set the new value. Modify
the memory starting from base address + offset.bytes
- replcement bytes
DebugException
- if this method fails. Reasons include:
DebugEvent
public void connect(Object client)
Memory blocks supporting change management may selectively turn off change management when no clients are connected, for reasons of efficiency. Clients that require access to change state information are required to connect to a memory block before change information is considered to be valid.
client
- the client to connectpublic void disconnect(Object client)
client
- the client to disconnectpublic Object[] getConnections()
public void dispose() throws DebugException
DebugException
- if the memory block cannot be disposed.public IMemoryBlockRetrieval getMemoryBlockRetrieval()
public int getAddressableSize() throws DebugException
DebugException
- if the addressable size cannot be obtained.
|
Eclipse Platform Release 3.1 |
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp. and others 2000, 2005. All rights reserved.