Package org.jfree.data.statistics
Class HistogramBin
- java.lang.Object
-
- org.jfree.data.statistics.HistogramBin
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Cloneable
public class HistogramBin extends java.lang.Object implements java.lang.Cloneable, java.io.SerializableA bin for theHistogramDatasetclass.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private intcountThe number of items in the bin.private doubleendBoundaryThe end boundary.private static longserialVersionUIDFor serialization.private doublestartBoundaryThe start boundary.
-
Constructor Summary
Constructors Constructor Description HistogramBin(double startBoundary, double endBoundary)Creates a new bin.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Objectclone()Returns a clone of the bin.booleanequals(java.lang.Object obj)Tests this object for equality with an arbitrary object.doublegetBinWidth()Returns the bin width.intgetCount()Returns the number of items in the bin.doublegetEndBoundary()Returns the end boundary.doublegetStartBoundary()Returns the start boundary.voidincrementCount()Increments the item count.
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
For serialization.- See Also:
- Constant Field Values
-
count
private int count
The number of items in the bin.
-
startBoundary
private double startBoundary
The start boundary.
-
endBoundary
private double endBoundary
The end boundary.
-
-
Method Detail
-
getCount
public int getCount()
Returns the number of items in the bin.- Returns:
- The item count.
-
incrementCount
public void incrementCount()
Increments the item count.
-
getStartBoundary
public double getStartBoundary()
Returns the start boundary.- Returns:
- The start boundary.
-
getEndBoundary
public double getEndBoundary()
Returns the end boundary.- Returns:
- The end boundary.
-
getBinWidth
public double getBinWidth()
Returns the bin width.- Returns:
- The bin width.
-
equals
public boolean equals(java.lang.Object obj)
Tests this object for equality with an arbitrary object.- Overrides:
equalsin classjava.lang.Object- Parameters:
obj- the object to test against.- Returns:
- A boolean.
-
clone
public java.lang.Object clone() throws java.lang.CloneNotSupportedExceptionReturns a clone of the bin.- Overrides:
clonein classjava.lang.Object- Returns:
- A clone.
- Throws:
java.lang.CloneNotSupportedException- not thrown by this class.
-
-