Class ReportFactory.Panel<C extends ReportContainer,​M extends ReportContainerManager>

    • Field Detail

      • m_ContainerManager

        protected M extends ReportContainerManager m_ContainerManager
        the manager the tabbed pane listens to.
      • m_VisibilityManager

        protected boolean m_VisibilityManager
        whether the manager is one handling visibility.
      • m_SearchString

        protected String m_SearchString
        the string that was searched for.
      • m_RegExp

        protected boolean m_RegExp
        whether the last search was using regular expressions.
      • m_SplitPane

        protected BaseSplitPane m_SplitPane
        the split pane for table and list.
      • m_PanelTable

        protected BasePanel m_PanelTable
        the panel for the table.
      • m_ReportContainerList

        protected ReportContainerList m_ReportContainerList
        the panel with the containers.
      • m_DataContainerPanel

        protected DataContainerPanel m_DataContainerPanel
        the associated panel with the data.
    • Constructor Detail

      • Panel

        public Panel()
        Initializes the tabbed pane with not reports.
    • Method Detail

      • initialize

        protected void initialize()
        Performs further initializations.
        Overrides:
        initialize in class BasePanel
      • initGUI

        protected void initGUI()
        Initializes the widgets.
        Overrides:
        initGUI in class BasePanel
      • setDataContainerPanel

        public void setDataContainerPanel​(DataContainerPanel value)
        Sets the data container panel to use.
        Parameters:
        value - the panel to use
      • getDataContainerPanel

        public DataContainerPanel getDataContainerPanel()
        Returns the data container panel in use.
        Returns:
        the panel, can be null if none set
      • setDividerLocation

        public void setDividerLocation​(int value)
        Sets the location of the divider.
        Parameters:
        value - the position in pixel
      • setDividerLocation

        public void setDividerLocation​(double value)
        Sets the proportional location of the divider.
        Parameters:
        value - the proportional position (0-1)
      • getDividerLocation

        public int getDividerLocation()
        Returns the current location of the divider.
        Returns:
        the position in pixel
      • newContainerManager

        protected M newContainerManager()
        Creates a new container manager.
        Returns:
        the container manager
      • getContainerManager

        public M getContainerManager()
        Returns the current manager listening to.
        Returns:
        the manager, null if not yet set
      • setContainerManager

        public void setContainerManager​(M value)
        Sets the manager to listen to.
        Parameters:
        value - the manager
      • getReportContainerList

        public ReportContainerList getReportContainerList()
        Returns the container list.
        Returns:
        the panel with the list
      • setReportContainerListWidth

        public void setReportContainerListWidth​(int width)
        Sets the preferred width of the ReportContainerList panel.
        Parameters:
        width - the preferred width
      • setData

        public void setData​(List<C> data)
        Sets the data and reports.
        Parameters:
        data - the spectrum containers containing the reports
      • setReports

        public void setReports​(List<Report> data)
        Sets the reports. Note: there is not underlying data or container panel available.
        Parameters:
        data - the reports
      • getData

        public List<C> getData()
        Returns the underlying data.
        Returns:
        the spectrum containers
      • search

        public void search​(String searchString,
                           boolean regexp)
        Performs a search for the given string. Limits the display of rows to ones containing the search string.
        Parameters:
        searchString - the string to search for
        regexp - whether to perform regular expression matching or just plain string comparison
      • getSeachString

        public String getSeachString()
        Returns the current search string.
        Returns:
        the search string, null if not filtered
      • dataChanged

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

        protected ReportFactory.Model newModel​(Report report)
        Creates a new table model from the report.
        Parameters:
        report - the report to base the model on
        Returns:
        the new table model
      • getTable

        protected ReportFactory.Table getTable​(int index)
        Returns the table associated with the specified report.
        Parameters:
        index - the index of the report
        Returns:
        the table
      • getBorderTitle

        protected String getBorderTitle​(int index)
        Returns the title used in the border around the table with the report.
        Parameters:
        index - the container/report to generate the title for
        Returns:
        the title
      • selectTable

        protected void selectTable​(int index)
        Selects and displays the selected report.
        Parameters:
        index - the index of the report table to display, use <0 to remove report from display
      • showTable

        protected void showTable​(int index)
        Displays the selected report.
        Parameters:
        index - the index of the report table to display, use <0 to remove report from display
      • getCurrentTable

        public ReportFactory.Table getCurrentTable()
        Returns the currently selected table.
        Returns:
        the table, null if none selected
      • getSelectedRow

        public int getSelectedRow()
        Returns the currently selected row.
        Returns:
        the selected row, can be -1
      • setCurrentTable

        public void setCurrentTable​(int index)
        Makes the specified report the current table. Also selects this entry in the panel list.
        Parameters:
        index - the index of the report to display