Package cbsw

Class RegisterIoTable


  • public class RegisterIoTable
    extends java.lang.Object

    A GUI display that tabulates data read through a RegisterIo interface

    • Constructor Summary

      Constructors 
      Constructor Description
      RegisterIoTable()
      No-argument constructor used by unmarshaller
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      void addDecodeAction​(java.awt.event.ActionListener al)
      Add a decode ActionListener
      void cache()
      Reads the register array from hardware into local cache.
      byte[] getCache()
      Returns the cache.
      javax.swing.JTable getStatusTable()
      Deprecated.
      javax.swing.JTable getTable()
      Returns the table
      java.lang.String getTitle()
      Returns the table title
      void init​(RegisterIo io)
      Called after unmarshalling to complete initialisation
      javax.swing.JPanel makePanel()
      Creates a panel containing the table
      static javax.swing.JPanel makePanel​(java.util.ArrayList<RegisterIoTable> tableList)
      Creates a panel containing all the unmarshalled tables
      void updateStatusTable()
      Deprecated.
      void updateTable()
      Update table from previously cached data
      void writeArray​(byte[] regs)
      Writes cached values to hardware
      • Methods inherited from class java.lang.Object

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

      • title

        java.lang.String title
      • baseAddress

        int baseAddress
      • csrAddress

        int csrAddress
      • csrSize

        int csrSize
      • tableDataDisplayWidth

        int tableDataDisplayWidth
      • tableColumnNames

        java.lang.String[] tableColumnNames
      • tableData

        java.lang.Object[][] tableData
      • tableSP

        javax.swing.JScrollPane tableSP
      • table

        javax.swing.JTable table
      • csrCache

        byte[] csrCache
      • decodeButton

        javax.swing.JButton decodeButton
    • Constructor Detail

      • RegisterIoTable

        public RegisterIoTable()

        No-argument constructor used by unmarshaller

    • Method Detail

      • getTitle

        public java.lang.String getTitle()

        Returns the table title

        Returns:
        The title
      • init

        public void init​(RegisterIo io)

        Called after unmarshalling to complete initialisation

        Parameters:
        io - The hardware I/O interface
      • getStatusTable

        @Deprecated
        public javax.swing.JTable getStatusTable()
        Deprecated.

        Replaced by getTable()

        Returns:
        The table
      • getTable

        public javax.swing.JTable getTable()

        Returns the table

        Returns:
        The table
      • makePanel

        public javax.swing.JPanel makePanel()

        Creates a panel containing the table

        Returns:
        The panel
      • addDecodeAction

        public void addDecodeAction​(java.awt.event.ActionListener al)

        Add a decode ActionListener

        The ActionListener is called when the decode button is pressed.

        Parameters:
        al - The ActionListener
      • writeArray

        public void writeArray​(byte[] regs)

        Writes cached values to hardware

        Parameters:
        regs - Data to write
      • cache

        public void cache()

        Reads the register array from hardware into local cache.

      • getCache

        public byte[] getCache()

        Returns the cache.

        Returns:
        The data cache
      • updateStatusTable

        @Deprecated
        public void updateStatusTable()
        Deprecated.

        Replaced by updateTable()

      • updateTable

        public void updateTable()

        Update table from previously cached data

      • makePanel

        public static javax.swing.JPanel makePanel​(java.util.ArrayList<RegisterIoTable> tableList)

        Creates a panel containing all the unmarshalled tables

        Parameters:
        tableList - The list of tables
        Returns:
        The panel