Package com.compomics.mslims.util.http.forms.inputs

Examples of com.compomics.mslims.util.http.forms.inputs.SelectInput


          lInput.setValue("Mascot generic");
        } else if (lInput.getName().equals("REPORT")) {
          // set REPORT to AUTO (the first entry)
          lInput.setValue(((SelectInput) lInput).getElements()[0]);
        } else {
          SelectInput input = (SelectInput) lInput;
          String[] elements = ((SelectInput) lInput).getElements();

          if (input.getMultiple()) {
            UserParameter p = new MultiChoiceParameter<String>(
                lInput.getComment(), lInput.getName(), elements);
            para.add(p);

          } else {
            UserParameter p = new ComboParameter<String>(
                lInput.getComment(), lInput.getName(), elements);
            para.add(p);
          }
        }
      }

      // Checkbox
      if (lInput.getType() == InputInterface.CHECKBOX) {
        if (lInput.getName().equals("OVERVIEW")) {
          lInput.setValue("0");
        } else
          para.add(new BooleanParameter(lInput.getComment(), lInput
              .getName()));
      }

      // Radio
      if (lInput.getType() == InputInterface.RADIOINPUT) {
        RadioInput input = (RadioInput) lInput;
        String[] elements = input.getChoices();
        para.add(new ComboParameter<String>(lInput.getComment(), lInput
            .getName(), elements));

      }
View Full Code Here

TOP

Related Classes of com.compomics.mslims.util.http.forms.inputs.SelectInput

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.