Class BFSAdvancedSearchPanel

java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
megamek.client.ui.dialogs.advancedsearch.BFSAdvancedSearchPanel
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible

public class BFSAdvancedSearchPanel extends JPanel
This panel shows advanced search filters for Battlefield Support Asset values. It filters on the asset-specific attributes that do not fit the Total Warfare or Alpha Strike searches (asset type, movement, TMM, range, skill, damage, destroy check, threshold, BSP cost, BFS BV and recognized Specials, including numeric Special thresholds and Artillery type). When any filter is active, only Battlefield Support Assets are matched.
See Also:
  • Constructor Details

    • BFSAdvancedSearchPanel

      public BFSAdvancedSearchPanel()
  • Method Details

    • matches

      public boolean matches(@Nullable MekSummary mekSummary)
      Parameters:
      mekSummary - the unit summary to test, which may be null
      Returns:
      true when no filters are active, or when the given summary is a Battlefield Support Asset that matches every active filter. When any filter is active, non-asset summaries never match.
    • isActive

      public boolean isActive()
      Returns:
      true when any of the search filters is activated so that units might be filtered out.
    • clearValues

      public void clearValues()
      Deactivates all Asset search filters so that no units will be filtered out.
    • saveValues

      public void saveValues()
      Saves the current field settings and contents to restore them when user-canceled.
    • resetValues

      public void resetValues()
      Restores the saved field settings and contents.