- java.lang.Object
-
- org.jfree.chart.axis.StandardTickUnitSource
-
- All Implemented Interfaces:
Serializable,TickUnitSource
public class StandardTickUnitSource extends Object implements TickUnitSource, Serializable
A source that can used by theNumberAxisclass to obtain a suitableTickUnit. Instances of this class areSerializablefrom version 1.0.7 onwards. Cloning is not supported, because instances are immutable.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description StandardTickUnitSource()Default constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)Tests this instance for equality with an arbitrary object.TickUnitgetCeilingTickUnit(double size)Returns the tick unit in the collection that is greater than or equal to the specified size.TickUnitgetCeilingTickUnit(TickUnit unit)Returns the tick unit in the collection that is greater than or equal to (in size) the specified unit.TickUnitgetLargerTickUnit(TickUnit unit)Returns a tick unit that is larger than the supplied unit.inthashCode()Returns a hash code for this instance.
-
-
-
Constructor Detail
-
StandardTickUnitSource
public StandardTickUnitSource()
Default constructor.
-
-
Method Detail
-
getLargerTickUnit
public TickUnit getLargerTickUnit(TickUnit unit)
Returns a tick unit that is larger than the supplied unit.- Specified by:
getLargerTickUnitin interfaceTickUnitSource- Parameters:
unit- the unit (nullnot permitted).- Returns:
- A tick unit that is larger than the supplied unit.
-
getCeilingTickUnit
public TickUnit getCeilingTickUnit(TickUnit unit)
Returns the tick unit in the collection that is greater than or equal to (in size) the specified unit.- Specified by:
getCeilingTickUnitin interfaceTickUnitSource- Parameters:
unit- the unit (nullnot permitted).- Returns:
- A unit from the collection.
-
getCeilingTickUnit
public TickUnit getCeilingTickUnit(double size)
Returns the tick unit in the collection that is greater than or equal to the specified size.- Specified by:
getCeilingTickUnitin interfaceTickUnitSource- Parameters:
size- the size.- Returns:
- A unit from the collection.
-
equals
public boolean equals(Object obj)
Tests this instance for equality with an arbitrary object.
-
-