Package org.openiaml.docs.modeldoc

Examples of org.openiaml.docs.modeldoc.Metric


    // get all the metrics in the library
    for (IPropertyInvestigator m : AllMetamodelPropertiesLibrary.getAllMetamodelProperties(new DefaultElementSelector())) {
      Object result = m.evaluate(rootPackage);
     
      // insert a new metric
      Metric metric = factory.createMetric();
      metric.setName(prefix + m.getName());
      metric.setValue(result.toString());
      root.getMetrics().add(metric);
     
    }
   
  }
View Full Code Here


    load(this.root, fileCountMap, fileSizeMap);
   
    // now save all of the metrics back
    // file count
    for (String extension : fileCountMap.keySet()) {
      Metric metric = factory.createMetric();
      // e.g. file.java.count.org.openiaml.model
      metric.setName("fileCount." + extension + "." + plugin);
      metric.setValue(fileCountMap.get(extension).toString());
      root.getMetrics().add(metric);
    }
   
    // file size
    for (String extension : fileSizeMap.keySet()) {
      Metric metric = factory.createMetric();
      // e.g. file.java.size.org.openiaml.model
      metric.setName("fileSize." + extension + "." + plugin);
      metric.setValue(fileSizeMap.get(extension).toString());
      root.getMetrics().add(metric);
    }
   
  }
View Full Code Here

     */
    public void publish(ModeldocFactory factory, ModelDocumentation root) {
      // now save all of the metrics back
      // file count
      for (String extension : totalCountMap.keySet()) {
        Metric metric = factory.createMetric();
        // e.g. file.java.count.org.openiaml.model
        metric.setName("fileCount." + extension + prefix + ".total");
        metric.setValue(totalCountMap.get(extension).toString());
        root.getMetrics().add(metric);
      }
     
      // file size
      for (String extension : totalSizeMap.keySet()) {
        Metric metric = factory.createMetric();
        // e.g. file.java.size.org.openiaml.model
        metric.setName("fileSize." + extension + prefix + ".total");
        metric.setValue(totalSizeMap.get(extension).toString());
        root.getMetrics().add(metric);
      }
    }
View Full Code Here

TOP

Related Classes of org.openiaml.docs.modeldoc.Metric

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.