- All Known Implementing Classes:
NumberTickUnitSource
,StandardTickUnitSource
,TickUnits
public interface TickUnitSource
-
Method Summary
Modifier and TypeMethodDescriptiongetCeilingTickUnit
(double size) Returns the smallest tick unit available in the source that is greater than or equal to the specified size.getCeilingTickUnit
(TickUnit unit) Returns the tick unit in the collection that is greater than or equal to (in size) the specified unit.getLargerTickUnit
(TickUnit unit) Returns the smallest tick unit available in the source that is larger thanunit
or, if there is no larger unit, returnsunit
.
-
Method Details
-
getLargerTickUnit
Returns the smallest tick unit available in the source that is larger thanunit
or, if there is no larger unit, returnsunit
.- Parameters:
unit
- the unit (null
not permitted).- Returns:
- A tick unit that is larger than the supplied unit.
-
getCeilingTickUnit
Returns the tick unit in the collection that is greater than or equal to (in size) the specified unit.- Parameters:
unit
- the unit.- Returns:
- A unit from the collection.
-
getCeilingTickUnit
Returns the smallest tick unit available in the source that is greater than or equal to the specified size. If there is no such tick unit, the method should return the largest available tick in the source.- Parameters:
size
- the size.- Returns:
- A unit from the collection (never
null
).
-