Class NodeInfoGUI

All Implemented Interfaces:
NodeInfoGUI_Interface, ActionListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible

public class NodeInfoGUI extends JPanel implements NodeInfoGUI_Interface, ActionListener
Contains the entire configuration GUI panel. This contains the basic fields which display the node's ID and type, and allows the user to modify the node's name and rules file. This also contains the node's specific DCNodeConfigGUI.
See Also:
  • Field Details

    • name

      protected JTextField name
      Contains the user defined name of the node being represented by this GUI
    • type

      protected JTextField type
      Contains the concatenation of the major and minor types of the node being represented by this GUI
    • label

      protected com.nt.common.gui.SMGIntField label
      User-specified integer label
    • id

      protected JTextField id
      Generated identifier for the node being represented by this GUI
    • rulesFileChoice

      protected JComboBox rulesFileChoice
      Contains listing of possible rules files for the node being represented by this GUI.
    • editRulesButton

      protected JButton editRulesButton
    • defaultFont

      protected static final Font defaultFont
    • nodeInfo

      protected com.nt.udc.admin.NodeInfo nodeInfo
      NodeInfo object for the node
    • old_ni

      protected com.nt.udc.admin.NodeInfo old_ni
    • nodeFieldsDirty

      protected boolean nodeFieldsDirty
      Indicates whether the user has modified any fields in this GUI
    • newNodeIDString

      public static final String newNodeIDString
      Static string used for the id field which indicates that this value will be assigned by the AdminServer
  • Constructor Details

    • NodeInfoGUI

      public NodeInfoGUI(com.nt.udc.admin.NodeInfo ni)
  • Method Details

    • allFieldsValid

      public boolean allFieldsValid()
      Queries the configGUI to determine if the values entered by the user are valid.
      Specified by:
      allFieldsValid in interface NodeInfoGUI_Interface
    • isAnyChange

      public boolean isAnyChange()
      compare the old node info and destinations with current values in this GUI.
    • addDestPanel

      public void addDestPanel(NodeDestinationsGUI destgui)
    • addNode

      protected String addNode(String ipAddr, int port)
      Adds the NodeInfo object returned from getNodeInfo for the specified IP Address and Port to the AdminServer
      Parameters:
      ipAddr - IP Address of the NodeManager that this node should be added to
      port - Port Number that the NodeManager is running on
    • saveNodeInfo

      protected void saveNodeInfo()
      Saves the NodeInfo object returned from getNodeInfo to the AdminServer also saves the node destinations.
    • getNodeInfo

      protected com.nt.udc.admin.NodeInfo getNodeInfo()
      Returns a NodeInfo object whose fields are set in accordance with the current values in this GUI.
      Returns:
      NodeInfo object for the node
    • addGUIComponents

      protected void addGUIComponents()
    • updateRuleChoice

      public void updateRuleChoice(String newRuleDisplayName, boolean newItem)
    • actionPerformed

      public void actionPerformed(ActionEvent ae)
      Specified by:
      actionPerformed in interface ActionListener
    • getExistingConfigGUI

      public DCNodeConfigGUIIfc getExistingConfigGUI()