|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.uka.ipd.sdq.codegen.simudatavisualisation.datatypes.Histogram
public class Histogram
This class stores the information necessary to display a histogram. The histogram can be visualized using the information about the bucket width and the probability for the buckets.
| Field Summary | |
|---|---|
protected List<HistogramBucketInformation> |
bucketInformation
List of the entities, that describe the probability for each of the buckets |
protected double |
bucketWidth
Contains the width of each bucket of the histogram. |
static double |
DEFAULT_BUCKET_WIDTH
The default width for histogram classes |
static double |
MAXIMUM_NUMBER_OF_BUCKETS
The maximum number of buckets to show when initialising the diagram. |
| Constructor Summary | |
|---|---|
Histogram(String title)
Creates a new histogram without buckets and default bucket width. |
|
Histogram(String title,
double bucketWidth)
Creates a new histogram without buckets. |
|
| Method Summary | |
|---|---|
void |
addEntity(HistogramBucketInformation entity)
Adds a new bucket to the histogram. |
List<HistogramBucketInformation> |
getBucketInformation()
Returns the list of the buckets and their respective probability. |
double |
getBucketWidth()
Receives the bucket width of the histogram. |
String |
getTitle()
Receives the title or name of the histogram. |
void |
removeEntity(HistogramBucketInformation entity)
Removes a bucket from the histogram. |
void |
setBucketWidth(double bucketWidth)
Sets the bucket width of the histogram. |
void |
setTitle(String title)
Sets the title or name of the histogram. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final double DEFAULT_BUCKET_WIDTH
public static final double MAXIMUM_NUMBER_OF_BUCKETS
protected List<HistogramBucketInformation> bucketInformation
HistogramBucketInformationprotected double bucketWidth
| Constructor Detail |
|---|
public Histogram(String title)
title - Title od name of the histogram.
public Histogram(String title,
double bucketWidth)
title - Title or name of the histogram.bucketWidth - Width of a bucket of the histogram.| Method Detail |
|---|
public void addEntity(HistogramBucketInformation entity)
entity - information about the bucket.public void removeEntity(HistogramBucketInformation entity)
entity - bucket to remove.public List<HistogramBucketInformation> getBucketInformation()
public String getTitle()
public void setTitle(String title)
title - The new title.public double getBucketWidth()
public void setBucketWidth(double bucketWidth)
bucketWidth - the new bucket width.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||