com.ikokoon.serenity.hudson.modeller
Class HighchartsModeller
java.lang.Object
com.ikokoon.serenity.hudson.modeller.HighchartsModeller
- All Implemented Interfaces:
- IModeller
public class HighchartsModeller
- extends java.lang.Object
- implements IModeller
This class takes the composites and generates the data arrays for the Highcharts model, and makes a big string that can be inserted into the
Highcharts object on the front end.
- Since:
- 01.01.10
- Version:
- 01.00
- Author:
- Michael Couck
|
Constructor Summary |
HighchartsModeller(java.lang.String modelName,
java.lang.Integer... buildNumbers)
Constructor takes the name of the model file, either the floating box model which is smaller or the graph model. |
|
Method Summary |
java.lang.String |
getModel()
Accesses the model in a base64 string representation. |
void |
visit(java.lang.Class<?> klass,
Composite<?,?>... composites)
Visits the composites and generates a model string for the Highcharts javaScript graph. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
HighchartsModeller
public HighchartsModeller(java.lang.String modelName,
java.lang.Integer... buildNumbers)
- Constructor takes the name of the model file, either the floating box model which is smaller or the graph model.
- Parameters:
modelName - the name of the model filebuildNumbers - the numbers that should be on the x-axis
getModel
public java.lang.String getModel()
- Accesses the model in a base64 string representation.
- Specified by:
getModel in interface IModeller
- Returns:
- the IModel serialised to a base 64 string
visit
public void visit(java.lang.Class<?> klass,
Composite<?,?>... composites)
- Visits the composites and generates a model string for the Highcharts javaScript graph.
coverageData = [49.9, 71.5, 106.4, 129.2, 144.0, 176.0, 135.6, 148.5, 216.4, 194.1, 95.6, 54.4]
complexityData - [1016, 1016, 1015.9, 1015.5, 1012.3, 1009.5, 1009.6, 1010.2, 1013.1, 1016.9, 1018.2, 1016.7]
stabilityData - [7.0, 6.9, 9.5, 14.5, 18.2, 21.5, 25.2, 26.5, 23.3, 18.3, 13.9, 9.6]
categoryData - ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12']
- Specified by:
visit in interface IModeller
- Parameters:
klass - the class of the compositecomposites - the list of composites to generate the model from
Copyright © 2010. All Rights Reserved.