Class DataContainerPanel<T extends DataContainer,​M extends AbstractContainerManager>

    • Field Detail

      • m_Title

        protected String m_Title
        the titel of the panel.
      • m_PlotPanel

        protected PlotPanel m_PlotPanel
        the content panel for drawing.
      • m_PlotWrapperPanel

        protected BasePanel m_PlotWrapperPanel
        the wrapper panel for the plot panel.
      • m_StatusMessageHandler

        protected StatusMessageHandler m_StatusMessageHandler
        a status message handler for displaying status messages.
    • Constructor Detail

      • DataContainerPanel

        public DataContainerPanel()
        Initializes the panel without title.
      • DataContainerPanel

        public DataContainerPanel​(String title)
        Initializes the panel with the given title.
        Parameters:
        title - the title for the panel, use "null" for none
    • Method Detail

      • finishInit

        protected void finishInit()
        Finishes up the initialization.
        Overrides:
        finishInit in class BasePanel
      • getDefaultDatabaseConnection

        protected abstract AbstractDatabaseConnection getDefaultDatabaseConnection()
        Returns the default database connection.
        Returns:
        the default database connection
      • getProperties

        public Properties getProperties()
        Returns the properties for this panel.
        Returns:
        the properties file for this panel
      • newContainerManager

        protected abstract M newContainerManager()
        Returns the container manager to use.
        Returns:
        the container manager
      • initGUI

        protected void initGUI()
        Initializes the GUI.
        Overrides:
        initGUI in class BasePanel
      • getContainerPaintlet

        public abstract Paintlet getContainerPaintlet()
        Returns the paintlet used for painting the containers.
        Returns:
        the paintlet
      • setTitle

        public void setTitle​(String value)
        Sets the title for the border.
        Parameters:
        value - the title, use null for no title
      • getTitle

        public String getTitle()
        Returns the title of border.
        Returns:
        the title, can be null
      • getPlot

        public PlotPanel getPlot()
        Returns the content panel, which is used for drawing.
        Specified by:
        getPlot in class PaintablePanel
        Returns:
        the content panel
      • setForegroundColor

        public void setForegroundColor​(Color value)
        Sets the foreground color to use.
        Parameters:
        value - the color to use
      • getForegroundColor

        public Color getForegroundColor()
        Returns the current foreground color in use.
        Returns:
        the color in use
      • setBackgroundColor

        public void setBackgroundColor​(Color value)
        Sets the background color to use.
        Parameters:
        value - the color to use
      • getBackgroundColor

        public Color getBackgroundColor()
        Returns the current background color in use.
        Returns:
        the color in use
      • reset

        protected void reset()
        Resets components, etc. Default implementation does nothing.
      • dataChanged

        public void dataChanged​(DataChangeEvent e)
        Gets called if the data of the container panel has changed.
        Specified by:
        dataChanged in interface DataChangeListener
        Parameters:
        e - the event that the container panel sent
      • setStatusMessageHandler

        public void setStatusMessageHandler​(StatusMessageHandler value)
        Sets the handler for status messages.
        Parameters:
        value - the handler to use, can be null
      • getStatusMessageHandler

        public StatusMessageHandler getStatusMessageHandler()
        Returns the currently set handler for status messages.
        Returns:
        the current handler, can be null
      • showStatus

        public void showStatus​(String msg)
        Displays a message. If a status message handler is set, then this handler's showStatus method is called, otherwise the message is printed to stdout.
        Specified by:
        showStatus in interface StatusMessageHandler
        Parameters:
        msg - the message to display
      • hasSendToItem

        public boolean hasSendToItem​(Class[] cls)
        Checks whether something to send is available.
        Specified by:
        hasSendToItem in interface SendToActionSupporter
        Parameters:
        cls - the classes to retrieve an item for
        Returns:
        true if an object is available for sending
      • getSendToItem

        public Object getSendToItem​(Class[] cls)
        Returns the object to send.
        Specified by:
        getSendToItem in interface SendToActionSupporter
        Parameters:
        cls - the classes to retrieve an item for
        Returns:
        the item to send, null if nothing available at the moment
      • cleanUp

        public void cleanUp()
        Cleans up data structures, frees up memory.
        Specified by:
        cleanUp in interface CleanUpHandler