java.lang.Object
com.vuze.plugins.mlab.tools.ndt.swingemu.Component
com.vuze.plugins.mlab.tools.ndt.swingemu.JComboBox

public class JComboBoxextends Component
Emulation of javax.swing.JComboBox for the NDT (Network Diagnostic Tool) plugin.

This class provides a minimal stub implementation of a dropdown combo box component to allow the NDT tool to run in headless environments. The combo box maintains selection index but provides no actual dropdown functionality.

All operations except index tracking are no-ops, maintaining API compatibility without requiring an actual graphical display system.

  • Field Details

    • index

      private int index
      Index of the selected item.
  • Constructor Details

    • JComboBox

      public JComboBox()
      Constructor. The selection index defaults to the stub's unset state and the dropdown methods are no-ops, so a bare instance is usable immediately.
  • Method Details

    • setSelectedIndex

      public void setSelectedIndex(int i)
      Selected index.
      Parameters:
      i - the zero-based item index to record as the current selection
    • getSelectedIndex

      public int getSelectedIndex()
      Return the selected index.
      Returns:
      the index last passed to setSelectedIndex(int), or 0 if none was
    • addItem

      public void addItem(String str)
      Add an item (no-op).
      Parameters:
      str - the item to add, ignored because items cannot be added here