Class SWTValidationUiServiceImpl

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      org.eclipse.swt.graphics.Color getValidationBackgroundColor​(org.eclipse.emf.common.util.Diagnostic diagnostic, VElement vElement, ViewModelContext viewModelContext)
      Returns the background color for a control with the given Diagnostic, VElement and view model context, if applicable.
      org.eclipse.swt.graphics.Color getValidationBackgroundColor​(VElement vElement, ViewModelContext viewModelContext)
      Returns the background color for a control matching the highest severity of the given VElement's diagnostic.
      org.eclipse.swt.graphics.Color getValidationForegroundColor​(org.eclipse.emf.common.util.Diagnostic diagnostic, VElement vElement, ViewModelContext viewModelContext)
      Returns the foreground color for a control with the given Diagnostic, VElement and view model context, if applicable.
      org.eclipse.swt.graphics.Color getValidationForegroundColor​(VElement vElement, ViewModelContext viewModelContext)
      Returns the foreground color for a control matching the highest severity of the given VElement's diagnostic.
      org.eclipse.swt.graphics.Image getValidationIcon​(org.eclipse.emf.common.util.Diagnostic diagnostic, VElement vElement, ViewModelContext viewModelContext)
      Returns the validation icon matching the given Diagnostic, VElement and view model context, if applicable.
      org.eclipse.swt.graphics.Image getValidationIcon​(VElement vElement, ViewModelContext viewModelContext)
      Returns the validation icon matching the highest severity of the given VElement's diagnostic.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SWTValidationUiServiceImpl

        public SWTValidationUiServiceImpl()
        Default constructor.
    • Method Detail

      • getValidationIcon

        public org.eclipse.swt.graphics.Image getValidationIcon​(org.eclipse.emf.common.util.Diagnostic diagnostic,
                                                                VElement vElement,
                                                                ViewModelContext viewModelContext)
        Description copied from interface: SWTValidationUiService
        Returns the validation icon matching the given Diagnostic, VElement and view model context, if applicable.
        Specified by:
        getValidationIcon in interface SWTValidationUiService
        Parameters:
        diagnostic - the Diagnostic defining the validation visualization
        vElement - The VElement that is being rendered
        viewModelContext - The corresponding ViewModelContext
        Returns:
        the icon to be displayed, or null when no icon is to be displayed
      • getValidationIcon

        public org.eclipse.swt.graphics.Image getValidationIcon​(VElement vElement,
                                                                ViewModelContext viewModelContext)
        Description copied from interface: SWTValidationUiService
        Returns the validation icon matching the highest severity of the given VElement's diagnostic.
        Specified by:
        getValidationIcon in interface SWTValidationUiService
        Parameters:
        vElement - The VElement that is being rendered
        viewModelContext - The corresponding ViewModelContext
        Returns:
        the icon to be displayed, or null when no icon is to be displayed
      • getValidationForegroundColor

        public org.eclipse.swt.graphics.Color getValidationForegroundColor​(org.eclipse.emf.common.util.Diagnostic diagnostic,
                                                                           VElement vElement,
                                                                           ViewModelContext viewModelContext)
        Description copied from interface: SWTValidationUiService
        Returns the foreground color for a control with the given Diagnostic, VElement and view model context, if applicable.
        Specified by:
        getValidationForegroundColor in interface SWTValidationUiService
        Parameters:
        diagnostic - the Diagnostic defining the validation visualization
        vElement - The VElement that is being rendered
        viewModelContext - The corresponding ViewModelContext
        Returns:
        the color to be used as a foreground color
      • getValidationBackgroundColor

        public org.eclipse.swt.graphics.Color getValidationBackgroundColor​(org.eclipse.emf.common.util.Diagnostic diagnostic,
                                                                           VElement vElement,
                                                                           ViewModelContext viewModelContext)
        Description copied from interface: SWTValidationUiService
        Returns the background color for a control with the given Diagnostic, VElement and view model context, if applicable.
        Specified by:
        getValidationBackgroundColor in interface SWTValidationUiService
        Parameters:
        diagnostic - the Diagnostic defining the validation visualization
        vElement - The VElement that is being rendered
        viewModelContext - The corresponding ViewModelContext
        Returns:
        the color to be used as a background color