com.atlassian.jira.web.bean
Class PercentageGraphModel

java.lang.Object
  extended by com.atlassian.jira.web.bean.PercentageGraphModel

@PublicApi
public final class PercentageGraphModel
extends Object


Constructor Summary
PercentageGraphModel()
           
 
Method Summary
 void addRow(String color, long number, String description)
           
 void addRow(String color, long number, String description, String statuses)
           
 int getPercentage(PercentageGraphRow row)
          Use to get the percentage of a particular row.
 List<PercentageGraphRow> getRows()
           
 long getTotal()
           
 boolean isTotalZero()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PercentageGraphModel

public PercentageGraphModel()
Method Detail

addRow

public void addRow(String color,
                   long number,
                   String description,
                   String statuses)

addRow

public void addRow(String color,
                   long number,
                   String description)

getRows

public List<PercentageGraphRow> getRows()

getPercentage

public int getPercentage(PercentageGraphRow row)
Use to get the percentage of a particular row.
If the percentage calculated is not a whole number it is rounded down. An exception is the last row for which the percentage is calculated as a remainder to 100 (percent).

Parameters:
row - row to get the width percentage for
Returns:
percentage for the given row

getTotal

public long getTotal()

isTotalZero

public boolean isTotalZero()


Copyright © 2002-2012 Atlassian. All Rights Reserved.