Package org.olat.ims.qti.editor.beecom.objects

Examples of org.olat.ims.qti.editor.beecom.objects.OutcomesProcessing


   * @see org.olat.ims.qti.editor.beecom.IParser#parse(org.dom4j.Element)
   */
  public Object parse(Element element) {
    //assert element.getName().equalsIgnoreCase("outcomes_processing");
         
    OutcomesProcessing outcomesProcessing = new OutcomesProcessing();

    List decvars = element.selectNodes("*/decvar");
    if (decvars.size()== 0) return outcomesProcessing;

    Element decvar = (Element) decvars.get(0);
    for (Iterator iter = decvar.attributeIterator(); iter.hasNext();) {
      Attribute attr = (Attribute) iter.next();
      outcomesProcessing.setField(attr.getName(), attr.getValue());
    }
    return outcomesProcessing;
  }
View Full Code Here


      assessment.setInheritControls(false);
    }
    assessment.setAssessmentcontrols(assessmentcontrols);

    // OUTCOMES PROCESSING
    OutcomesProcessing outcomesProcessing = (OutcomesProcessing)parserManager.parse(element.element("outcomes_processing"));
    if (outcomesProcessing != null)
      assessment.setOutcomes_processing(outcomesProcessing);
   
    //SECTIONS
    List sectionsXML = element.elements("section");
View Full Code Here

    if (!surveyMode && !restrictedEdit) {
      if (assessment.getDuration() != null) main.contextPut("duration", assessment.getDuration());
    }

    // Adding outcomes processing parameters
    OutcomesProcessing outcomesProcessing = assessment.getOutcomes_processing();
    if (outcomesProcessing == null) {
      main.contextPut(OutcomesProcessing.CUTVALUE, "0.0");
    } else {
      main.contextPut(OutcomesProcessing.CUTVALUE, outcomesProcessing.getField(OutcomesProcessing.CUTVALUE));
    }   
    this.putInitialPanel(main);
  }
View Full Code Here

          if (oldInheritControls && !newInheritControls) {
            tmpControl.setSwitches(Control.CTRL_UNDEF, Control.CTRL_UNDEF, Control.CTRL_UNDEF);
            assessment.setInheritControls(false);
          }

          OutcomesProcessing outcomesProcessing = assessment.getOutcomes_processing();
          if (outcomesProcessing == null) {
            // Create outcomes processing object if it doesn't already exist.
            // Happens
            // when creating a new assessment
            outcomesProcessing = new OutcomesProcessing();
            assessment.setOutcomes_processing(outcomesProcessing);
          }
          String cutval = ureq.getParameter(OutcomesProcessing.CUTVALUE);
          try {
            Float.parseFloat(cutval);
          } catch (NumberFormatException nfe) {
            cutval = "0.0";           
            this.showWarning("error.cutval");
          }
          outcomesProcessing.setField(OutcomesProcessing.CUTVALUE, cutval);
          main.contextPut(OutcomesProcessing.CUTVALUE, cutval);

          if (ureq.getParameter("duration").equals("Yes")) {
            String durationMin = ureq.getParameter("duration_min");
            String durationSec = ureq.getParameter("duration_sec");
View Full Code Here

TOP

Related Classes of org.olat.ims.qti.editor.beecom.objects.OutcomesProcessing

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.