Esempio n. 1
0
 /**
  * Load the task profile statistics from the XML element to the profile
  *
  * @param taskProf the task profile
  * @param task the task XML element
  */
 private void loadTaskProfileStatistics(MRTaskProfile taskProf, Element task) {
   Element stats = (Element) task.getElementsByTagName(STATS).item(0);
   NodeList statList = stats.getElementsByTagName(STAT);
   for (int j = 0; j < statList.getLength(); ++j) {
     Element stat = (Element) statList.item(j);
     taskProf.addStatistic(
         MRStatistics.valueOf(stat.getAttribute(KEY)),
         Double.parseDouble(stat.getAttribute(VALUE)));
   }
 }