Interface IAddMemoryRenderingsTarget


  • public interface IAddMemoryRenderingsTarget
    Adapter for the platform's retargettable "add memory rendering" action. Clients implementing this adapter are expected to add the necessary memory blocks and renderings when the adapter is invoked.

    Typically, to add a memory rendering, client needs to do the following:

    1. Create a new memory block
    2. Add the new memory block to the Memory Block Manager. (IMemoryBlockManager)
    3. Create the new rendering from IMemoryRenderingTypeDelegate
    4. Bring the required memory view to the top. (IMemoryRenderingSite)
    5. Find the container from the memory view to host the new memory rendering. (IMemoryRenderingContainer)
    6. Initialize the new rendering with the appropriate memory block and container.
    7. Add the new rendering to the container.

    Clients may implement this interface.

    Since:
    3.2
    See Also:
    AddMemoryRenderingActionDelegate
    • Method Detail

      • canAddMemoryRenderings

        boolean canAddMemoryRenderings​(IWorkbenchPart part,
                                       ISelection selection)
        Returns whether a memory rendering can be added from the specified part, based on the the given selection, which is the active debug context in the current workbench window.
        Parameters:
        part - the part on which the action has been invoked
        selection - the active debug context in the active workbench window
        Returns:
        true if a memory rendering can be added from the specified part with the given selection, false otherwise
      • getMemoryRenderingTypes

        IMemoryRenderingType[] getMemoryRenderingTypes​(IWorkbenchPart part,
                                                       ISelection selection)
        Returns a list of rendering types that can be added from the given workbench part and active debug context, possibly empty.
        Parameters:
        part - the part on which the action has been invoked
        selection - the active debug context
        Returns:
        a list of rendering types that can be added, possibly empty