Interface ESelectionService


  • public interface ESelectionService
    This interface describes the workbench selection service
    Since:
    1.0
    Restriction:
    This interface is not intended to be implemented by clients.
    • Method Detail

      • setSelection

        void setSelection​(Object selection)
        Sets the given selection in the active context
        Parameters:
        selection - the new selection
      • setPostSelection

        void setPostSelection​(Object selection)
        Sets the given selection as the post selection for the active context
        Parameters:
        selection - the new selection
      • getSelection

        Object getSelection()
        Returns the current selection from the active context or null if the is nothing selected.
        Returns:
        the current selection or null
      • getSelection

        Object getSelection​(String partId)
        Returns the current selection from the the part with the given id. Returns null if there is no selection or the part does not exist.
        Parameters:
        partId - the id of the part to get the selection from
        Returns:
        the current selection in the part or null
      • removeSelectionListener

        void removeSelectionListener​(ISelectionListener listener)
        Removes the given ISelectionListener from the service
        Parameters:
        listener - the listener to unregister
      • addSelectionListener

        void addSelectionListener​(String partId,
                                  ISelectionListener listener)
        Adds the ISelectionListener to the service for the part with the given id.
        Parameters:
        partId - the id of the part to add the listener for
        listener - the listener to register
      • removeSelectionListener

        void removeSelectionListener​(String partId,
                                     ISelectionListener listener)
        Removes the ISelectionListener from the service for the given part id.
        Parameters:
        partId - the id of the part to remove the listener for
        listener - the listener to unregister
      • addPostSelectionListener

        void addPostSelectionListener​(ISelectionListener listener)
        Adds the ISelectionListener as a post selection listener for the service.
        Parameters:
        listener - the listener to register
      • removePostSelectionListener

        void removePostSelectionListener​(ISelectionListener listener)
        Removes the ISelectionListener as a post selection listener for the service.
        Parameters:
        listener - the listener to unregister
      • addPostSelectionListener

        void addPostSelectionListener​(String partId,
                                      ISelectionListener listener)
        Adds the ISelectionListener as a post selection listener for the part with the given id.
        Parameters:
        partId - the id of the part to add the listener for
        listener - the listener to register
      • removePostSelectionListener

        void removePostSelectionListener​(String partId,
                                         ISelectionListener listener)
        Removes the ISelectionListener as a post selection listener for the part with the given id.
        Parameters:
        partId - the id of the part to remove the listener for
        listener - the listener to unregister