Memory Renderings

org.eclipse.debug.ui.memoryRenderings

3.1 - replacement for memoryRenderingTypes extension point which was considered experimental in 3.0

Allows plug-ins to contribute arbitrary renderings for memory blocks and bind memory blocks to renderings. For example, a rendering may translate raw bytes of a memory block into ASCII characters.

<!ELEMENT extension (renderingType* | renderingBindings*)>

<!ATTLIST extension

point CDATA #REQUIRED

id    CDATA #IMPLIED

name  CDATA #IMPLIED>


<!ELEMENT renderingType EMPTY>

<!ATTLIST renderingType

name  CDATA #REQUIRED

id    CDATA #REQUIRED

class CDATA #REQUIRED>

This element defines a rendering type.



<!ELEMENT renderingBindings (enablement*)>

<!ATTLIST renderingBindings

renderingIds CDATA #IMPLIED

primaryId    CDATA #IMPLIED

class        CDATA #IMPLIED

defaultIds   CDATA #IMPLIED>

Binds memory blocks with available renderings.



The following is an example for defining a new rendering type and binding.

<extension point=

"org.eclipse.debug.ui.memoryRenderings"

>

<renderingType name=

"Sample Rendering"

id=

"com.example.sampleRendering"

class=

"com.example.SampleRenderingTypeDelegate"

>

</renderingType>

<renderingBindings renderingIds=

"com.example.sampleRendering"

>

<enablement>

<instanceof value=

"com.example.SampleMemoryBlock"

/>

</enablement>

</renderingBindings>

</extension>

In the above example, a new rendering type, Sample Rendering, is defined. The class com.example.SampleRenderingTypeDelegate implements org.eclipse.debug.ui.memory.IMemoryRenderingTypeDelegate and will be used to create new renderings of this type. The rendering is bound to instances of com.exmaple.SampleMemoryBlock.

  • Value of the attribute class in a renderingType element must be a fully qualifed name of a Java class that implements org.eclipse.debug.ui.memory.IMemoryRenderingTypeDelegate.
  • Value of the attribute class in a renderingBindings element must be a fully qualifed name of a Java class that implements org.eclipse.debug.ui.memory.IMemoryRenderingBindingsProvider.
  • The debug platform provides the following rendering types:

  • Hex Rendering (rendering id: org.eclipse.debug.ui.rendering.raw_memory)
  • ASCII Rendering (rendering id: org.eclipse.debug.ui.rendering.ascii)
  • Signed Integer Rendering (rendering id: org.eclipse.debug.ui.rendering.signedint)
  • Unsigned Integer Rendering (rendering id: org.eclipse.debug.ui.rendering.unsignedint)

  • The debug platform provides a memory view to host renderings.