docs: protected JFormattedTextField.AbstractFormatter getFormatter() {
          JFormattedTextField.AbstractFormatter formatter = null;
  
          // Try to find a text component in the spinner
          JFormattedTextField textEditorComponent;
          if (spinner.getEditor() instanceof JFormattedTextField) {
              textEditorComponent = (JFormattedTextField) spinner.getEditor();
          } else if (spinner.getEditor() instanceof JSpinner.DefaultEditor) {
              textEditorComponent = ((JSpinner.DefaultEditor) spinner.getEditor()).getTextField();
          } else {
              LOGGER.error("No formatted textfield can be found in the spinner to get the formatter: " + spinner);
              textEditorComponent = null;
          }
  
          // Read text from text component
          if (textEditorComponent != null) {
              formatter = textEditorComponent.getFormatter();
          }
  
          return formatter;
      }