## org.jfree.data.statistics
Class SimpleHistogramBin

    java.lang.Object
      org.jfree.data.statistics.SimpleHistogramBin

All Implemented Interfaces:
  java.io.Serializable, java.lang.Cloneable, java.lang.Comparable, org.jfree.util.PublicCloneable

    public class SimpleHistogramBin

extends java.lang.Object
implements java.lang.Comparable, java.lang.Cloneable, org.jfree.util.PublicCloneable, java.io.Serializable

A bin for the `SimpleHistogramDataset`.

See Also:
  Serialized Form

Constructor Summary
`SimpleHistogramBin(double lowerBound, double upperBound)` Creates a new bin.
`SimpleHistogramBin(double lowerBound, double upperBound, boolean includeLowerBound, boolean includeUpperBound)` Creates a new bin.

Method Summary
`boolean` `accepts(double value)` Returns `true` if the specified value belongs in the bin, and `false` otherwise.
`java.lang.Object` `clone()` Returns a clone of the bin.
`int` `compareTo(java.lang.Object obj)` Compares the bin to an arbitrary object and returns the relative ordering.
`boolean` `equals(java.lang.Object obj)` Tests this bin for equality with an arbitrary object.
`int` `getItemCount()` Returns the item count.
`double` `getLowerBound()` Returns the lower bound.
`double` `getUpperBound()` Return the upper bound.
`boolean` `overlapsWith(SimpleHistogramBin bin)` Returns `true` if this bin overlaps with the specified bin, and `false` otherwise.
`void` `setItemCount(int count)` Sets the item count.

Methods inherited from class java.lang.Object
`finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### SimpleHistogramBin

    public SimpleHistogramBin(double lowerBound,
                              double upperBound)

  Creates a new bin.

  Parameters:
    `lowerBound` - the lower bound (inclusive).
    `upperBound` - the upper bound (inclusive);

### SimpleHistogramBin

    public SimpleHistogramBin(double lowerBound,
                              double upperBound,
                              boolean includeLowerBound,
                              boolean includeUpperBound)

  Creates a new bin.

  Parameters:
    `lowerBound` - the lower bound.
    `upperBound` - the upper bound.
    `includeLowerBound` - include the lower bound?
    `includeUpperBound` - include the upper bound?

Method Detail

### getLowerBound

    public double getLowerBound()

  Returns the lower bound.

  Returns:
    The lower bound.

### getUpperBound

    public double getUpperBound()

  Return the upper bound.

  Returns:
    The upper bound.

### getItemCount

    public int getItemCount()

  Returns the item count.

  Returns:
    The item count.

### setItemCount

    public void setItemCount(int count)

  Sets the item count.

  Parameters:
    `count` - the item count.

### accepts

    public boolean accepts(double value)

  Returns `true` if the specified value belongs in the bin, and `false` otherwise.

  Parameters:
    `value` - the value.
  Returns:
    A boolean.

### overlapsWith

    public boolean overlapsWith(SimpleHistogramBin bin)

  Returns `true` if this bin overlaps with the specified bin, and `false` otherwise.

  Parameters:
    `bin` - the other bin (`null` not permitted).
  Returns:
    A boolean.

### compareTo

    public int compareTo(java.lang.Object obj)

  Compares the bin to an arbitrary object and returns the relative ordering.

  Specified by:
    `compareTo` in interface `java.lang.Comparable`
  Parameters:
    `obj` - the object.
  Returns:
    An integer indicating the relative ordering of the this bin and the given object.

### equals

    public boolean equals(java.lang.Object obj)

  Tests this bin for equality with an arbitrary object.

  Overrides:
    `equals` in class `java.lang.Object`
  Parameters:
    `obj` - the object (`null` permitted).
  Returns:
    A boolean.

### clone

    public java.lang.Object clone()
                           throws java.lang.CloneNotSupportedException

  Returns a clone of the bin.

  Specified by:
    `clone` in interface `org.jfree.util.PublicCloneable`
  Overrides:
    `clone` in class `java.lang.Object`
  Returns:
    A clone.
  Throws:
    `java.lang.CloneNotSupportedException` - not thrown by this class.