Class BeanShellExpressionConfigurer


public class BeanShellExpressionConfigurer extends StringConfigurer
A Configurer for Java Expressions
  • Field Details

    • expressionPanel

      protected JPanel expressionPanel
    • detailPanel

      protected JPanel detailPanel
    • validator

      protected VASSAL.configure.BeanShellExpressionConfigurer.Validator validator
    • extraDetails

      protected JButton extraDetails
    • up

      protected Icon up
    • down

      protected Icon down
    • errorMessage

      protected StringConfigurer errorMessage
    • variables

      protected JLabel variables
    • methods

      protected JLabel methods
    • target

      protected EditablePiece target
    • option

    • selectedText

      protected String selectedText
    • displayOnly

      protected boolean displayOnly
    • builder

      protected FunctionBuilder builder
    • nameField

      protected JTextArea nameField
  • Constructor Details

  • Method Details

    • strip

      protected void strip()
    • getOption

    • setOption

      public void setOption(BeanShellExpressionConfigurer.Option option)
    • getValueString

      public String getValueString()
      Overrides:
      getValueString in class StringConfigurer
      Returns:
      a String representation of the Object value
    • setValue

      public void setValue(String s)
      Description copied from class: Configurer
      Set the Object value from a String
      Overrides:
      setValue in class StringConfigurer
    • requestFocus

      public void requestFocus()
      Description copied from class: Configurer
      Move the cursor to the first input field of this Configurer
      Overrides:
      requestFocus in class StringConfigurer
    • setHighlighted

      public void setHighlighted(boolean highlighted)
      Description copied from class: Configurer
      Set the highlighted status of this configurer. It is up to individual Configurers to override this method and implement a suitable visual highlighting scheme Note: Cannot make this abstract as it will break custom code.
      Overrides:
      setHighlighted in class StringConfigurer
      Parameters:
      highlighted - New Highlighted status
    • addFocusListener

      public void addFocusListener(FocusListener listener)
      Description copied from class: Configurer
      Add a FocusListener to the Swing Components that make up this Configurer.
      Overrides:
      addFocusListener in class StringConfigurer
      Parameters:
      listener - Focus Listener
    • removeFocusListener

      public void removeFocusListener(FocusListener listener)
      Description copied from class: Configurer
      Remove a FocusListener from the Swing Components that make up this Configurer.
      Overrides:
      removeFocusListener in class StringConfigurer
      Parameters:
      listener - Focus Listener
    • getTopLevelAncestor

      protected Component getTopLevelAncestor()
    • getControls

      public Component getControls()
      Description copied from class: Configurer
      GUI interface for setting the option in an editing window
      Overrides:
      getControls in class StringConfigurer
    • validate

      public void validate()
    • updateParentBuilder

      protected void updateParentBuilder()
      If we are the child of a FunctionBuilder, notify it we have changed.
    • doPopup

      protected void doPopup()
    • insertPropertyName

      protected void insertPropertyName(String name)
      Insert a property name into the expression
      Parameters:
      name - property name
    • insertName

      protected void insertName(String name)
    • cleanName

      protected String cleanName(String name)
    • setDetails

      protected void setDetails(String error, List<String> v, List<String> m)
    • setDetails

      protected void setDetails()
    • getSelectedText

      public String getSelectedText()
    • setSelectedText

      public void setSelectedText(String selectedText)
    • isDisplayOnly

      public boolean isDisplayOnly()
    • setDisplayOnly

      public void setDisplayOnly(boolean displayOnly)