Class SpreadSheetPanel

    • Field Detail

      • m_Owner

        protected MultiPagePane m_Owner
        the owning tabbed pane.
      • m_PanelSearch

        protected SearchPanel m_PanelSearch
        the search panel.
      • m_GeneratedFlows

        protected List<Flow> m_GeneratedFlows
        the generated flows (eg charts).
      • m_Filename

        protected File m_Filename
        the associated file name.
      • m_Reader

        protected SpreadSheetReader m_Reader
        the reader used for reading the file.
      • m_Writer

        protected SpreadSheetWriter m_Writer
        the writer used for writing the file.
      • m_GarbageCollectionOnClose

        protected boolean m_GarbageCollectionOnClose
        whether to apply GC during cleanup.
    • Constructor Detail

      • SpreadSheetPanel

        public SpreadSheetPanel​(MultiPagePane owner)
        Initializes the panel.
        Parameters:
        owner - the owning tabbed pane
    • Method Detail

      • initialize

        protected void initialize()
        initializes the members.
        Overrides:
        initialize in class BasePanel
      • initGUI

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

        public void setOwner​(MultiPagePane value)
        Sets the owning tabbed pane.
        Parameters:
        value - the owner
      • getOwner

        public MultiPagePane getOwner()
        Returns the owning tabbed pane.
        Returns:
        the owner, null if none set
      • getKnownParent

        public Container getKnownParent()
        Returns the component that acts as this component's parent.
        Specified by:
        getKnownParent in interface KnownParentSupporter
        Returns:
        the parent, null if not available
      • getTabTitle

        public String getTabTitle()
        Returns this panel's tab title, if any.
        Returns:
        the title, null if not available
      • getViewer

        public SpreadSheetViewerPanel getViewer()
        Returns the owning viewer.
        Returns:
        the viewer, null if none set
      • setNumDecimals

        public void setNumDecimals​(int value)
        Sets the number of decimals to display. Use -1 to display all.
        Parameters:
        value - the number of decimals
      • getNumDecimals

        public int getNumDecimals()
        Returns the currently set number of decimals. -1 if displaying all.
        Returns:
        the number of decimals
      • setCellRenderingCustomizer

        public void setCellRenderingCustomizer​(CellRenderingCustomizer value)
        Sets the cell rendering customizer.
        Parameters:
        value - the customizer
      • getCellRenderingCustomizer

        public CellRenderingCustomizer getCellRenderingCustomizer()
        Returns the cell rendering customizer.
        Returns:
        the customizer
      • setShowFormulas

        public void setShowFormulas​(boolean value)
        Sets whether to display the formulas or their calculated values.
        Parameters:
        value - true if to display the formulas rather than the calculated values
      • getShowFormulas

        public boolean getShowFormulas()
        Returns whether to display the formulas or their calculated values.
        Returns:
        true if to display the formulas rather than the calculated values
      • setReadOnly

        public void setReadOnly​(boolean value)
        Sets whether the table is read-only.
        Parameters:
        value - true if read-only
      • isReadOnly

        public boolean isReadOnly()
        Returns whether the table is read-only.
        Returns:
        true if read-only
      • setModified

        public void setModified​(boolean value)
        Sets whether the table has been modified.
        Parameters:
        value - true if modified
      • isModified

        public boolean isModified()
        Returns whether the table has been modified.
        Returns:
        true if modified
      • setShowCellTypes

        public void setShowCellTypes​(boolean value)
        Sets whether to show the cell types rather than the cell values.
        Parameters:
        value - true if to show cell types
      • getShowCellTypes

        public boolean getShowCellTypes()
        Returns whether to show the cell types rather than the cell values.
        Returns:
        true if showing the cell types
      • getTable

        public SpreadSheetTable getTable()
        Returns the underlying table.
        Returns:
        the table
      • setSheet

        public void setSheet​(SpreadSheet value)
        Sets the spreadsheet to display.
        Parameters:
        value - the sheet
      • getSheet

        public SpreadSheet getSheet()
        Returns the underlying spreadsheet.
        Returns:
        the sheet
      • toSpreadSheet

        public SpreadSheet toSpreadSheet​(TableRowRange range)
        Returns the underlying sheet.
        Parameters:
        range - the range to return
        Returns:
        the spread sheet
      • generateChart

        public void generateChart​(AbstractChartGenerator generator)
        Generates and displays a chart using the specified chart generator.
        Parameters:
        generator - the generator to use for creating the chart
      • addGeneratedFlow

        public void addGeneratedFlow​(Flow flow)
        Adds the flow to the list of flows to clean up.
        Parameters:
        flow - the flow to clean up
      • setFilename

        public void setFilename​(File value)
        Sets the associated filename.
        Parameters:
        value - the file
      • getFilename

        public File getFilename()
        Returns the associated filename.
        Returns:
        the file
      • setReader

        public void setReader​(SpreadSheetReader value)
        Sets the associated reader.
        Parameters:
        value - the reader
      • getReader

        public SpreadSheetReader getReader()
        Returns the associated reader.
        Returns:
        the reader
      • setWriter

        public void setWriter​(SpreadSheetWriter value)
        Sets the associated writer.
        Parameters:
        value - the writer
      • getWriter

        public SpreadSheetWriter getWriter()
        Returns the associated writer.
        Returns:
        the writer
      • setGarbageCollectionOnClose

        public void setGarbageCollectionOnClose​(boolean value)
        Sets whether to run garbage collection on cleanup.
        Parameters:
        value - true if to run
      • getGarbageCollectionOnClose

        public boolean getGarbageCollectionOnClose()
        Returns whether to run garbage collection on cleanup.
        Returns:
        true if to run
      • cleanUp

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