Package com.iizigo.db

Class PluginApplicationUI


  • public class PluginApplicationUI
    extends java.lang.Object
    The Plug-in ApplicationUI instance holds the various images loaded from Image Descriptors and can be used as SWT Images directly, as well as other SWT allocated object such as colors.
    Author:
    Christopher Mindus
    • Field Summary

      Fields 
      Modifier and TypeFieldDescription
      org.eclipse.swt.graphics.ImageimageDBActionActor
      Image for database action actor.
      org.eclipse.swt.graphics.ImageimageInput
      Image for input properties.
      org.eclipse.swt.graphics.ImageimageInputVariable
      Image for input an variable.
      org.eclipse.swt.graphics.ImageimageResult
      Image for result of UPDATE, DELETE, INSERT.
      org.eclipse.swt.graphics.ImageimageResultSet
      Image for result of SELECT.
      org.eclipse.swt.graphics.ImageimageResultSetColumn
      Image for column in result set of SELECT.
      org.eclipse.swt.graphics.ImageimageTable
      Image for database table.
      org.eclipse.swt.graphics.ImageimageTransaction
      Image for database transaction.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and TypeMethodDescription
      org.eclipse.swt.graphics.ImagegetImage​(java.lang.String fileName)
      Gets an Image from a file name.
      org.eclipse.swt.graphics.ImagegetImage​(org.eclipse.jface.resource.ImageDescriptor descriptor)
      Loads the image for an Image Descriptor and caches it.
      static PluginApplicationUIgetInstance()
      Gets the instance of the ApplicationUI.
      • Methods inherited from class java.lang.Object

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

      • imageTransaction

        public final org.eclipse.swt.graphics.Image imageTransaction
        Image for database transaction.
      • imageTable

        public final org.eclipse.swt.graphics.Image imageTable
        Image for database table.
      • imageInput

        public final org.eclipse.swt.graphics.Image imageInput
        Image for input properties.
      • imageInputVariable

        public final org.eclipse.swt.graphics.Image imageInputVariable
        Image for input an variable.
      • imageResult

        public final org.eclipse.swt.graphics.Image imageResult
        Image for result of UPDATE, DELETE, INSERT.
      • imageResultSet

        public final org.eclipse.swt.graphics.Image imageResultSet
        Image for result of SELECT.
      • imageResultSetColumn

        public final org.eclipse.swt.graphics.Image imageResultSetColumn
        Image for column in result set of SELECT.
      • imageDBActionActor

        public final org.eclipse.swt.graphics.Image imageDBActionActor
        Image for database action actor.
    • Method Detail

      • getInstance

        public static PluginApplicationUI getInstance()
        Gets the instance of the ApplicationUI. The first time this is done, it must be from the SWT thread, otherwise an InternalError is thrown.
        Returns:
        The singleton.
      • getImage

        public org.eclipse.swt.graphics.Image getImage​(java.lang.String fileName)
        Gets an Image from a file name.
        Parameters:
        fileName - The file name loads a descriptor from the "icons" folder.
        Returns:
        The image, or null if not found.
      • getImage

        public org.eclipse.swt.graphics.Image getImage​(org.eclipse.jface.resource.ImageDescriptor descriptor)
        Loads the image for an Image Descriptor and caches it. It will be disposed of when the plug-in exits.
        Parameters:
        descriptor - The Image Descriptor or null if none.
        Returns:
        The image created, null for none or when Image Descriptor is null.