com.sonyericsson.jenkins.plugins.bfa.graphs
Class BFAGraph

java.lang.Object
  extended by hudson.util.Graph
      extended by com.sonyericsson.jenkins.plugins.bfa.graphs.BFAGraph
Direct Known Subclasses:
BarChart, PieChart, StackedBarChart, TimeSeriesChart

public abstract class BFAGraph
extends hudson.util.Graph

Graph for the BFA plugin.

Author:
Fredrik Persson <fredrik6.persson@sonymobile.com>, Christoffer Lauri <christoffer.lauri@sonymobile.com>

Field Summary
protected  GraphFilterBuilder filter
          The data filter used for this graph.
protected static String GRAPH_OTHERS
          The name of the cause/category of all non-displayed elements.
protected static String GRAPH_UNCATEGORIZED
          Name for the category for failures without category.
protected static String GRAPH_UNKNOWN
          Name for the failures without a corresponding failure cause.
protected  String graphTitle
          The title of the graph.
protected static int MAX_GRAPH_ELEMENTS
          Max number of causes or categories to show in graphs.
static int MAX_YEARS_FOR_TIME_GRAPH
          Max number of years to display in time graphs.
protected  hudson.model.AbstractProject project
          The project that this graph is plotting values for.
 
Constructor Summary
protected BFAGraph(long timestamp, int defaultW, int defaultH, hudson.model.AbstractProject project, GraphFilterBuilder filter, String graphTitle)
          Default constructor.
 
Method Summary
static List<Integer> getBuildNumbers(hudson.model.AbstractProject project)
          Gets a list of build numbers that exist for the argument project.
 
Methods inherited from class hudson.util.Graph
createGraph, doMap, doPng
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

project

protected hudson.model.AbstractProject project
The project that this graph is plotting values for. Is null for non-project graphs.


filter

protected GraphFilterBuilder filter
The data filter used for this graph.


graphTitle

protected String graphTitle
The title of the graph.


MAX_GRAPH_ELEMENTS

protected static final int MAX_GRAPH_ELEMENTS
Max number of causes or categories to show in graphs.

See Also:
Constant Field Values

GRAPH_OTHERS

protected static final String GRAPH_OTHERS
The name of the cause/category of all non-displayed elements.

See Also:
Constant Field Values

GRAPH_UNCATEGORIZED

protected static final String GRAPH_UNCATEGORIZED
Name for the category for failures without category.

See Also:
Constant Field Values

GRAPH_UNKNOWN

protected static final String GRAPH_UNKNOWN
Name for the failures without a corresponding failure cause.

See Also:
Constant Field Values

MAX_YEARS_FOR_TIME_GRAPH

public static final int MAX_YEARS_FOR_TIME_GRAPH
Max number of years to display in time graphs.

See Also:
Constant Field Values
Constructor Detail

BFAGraph

protected BFAGraph(long timestamp,
                   int defaultW,
                   int defaultH,
                   hudson.model.AbstractProject project,
                   GraphFilterBuilder filter,
                   String graphTitle)
Default constructor.

Parameters:
timestamp - timestamp for this project graph, used for HTTP caching. Set to -1 if timestamp is not needed.
defaultW - width of the graph in pixels
defaultH - height of the graph in pixels
project - the parent project of this graph, set to null for non-project graphs
filter - the filter used when fetching data for this graph
graphTitle - The title of the graph
Method Detail

getBuildNumbers

public static List<Integer> getBuildNumbers(hudson.model.AbstractProject project)
Gets a list of build numbers that exist for the argument project.

Parameters:
project - the project to list build numbers for
Returns:
list of build numbers, empty if project is null


Copyright © 2004-2014. All Rights Reserved.