| java.lang.Object org.geotools.axis.AbstractGraduation org.geotools.axis.NumberGraduation
All known Subclasses: org.geotools.axis.LogarithmicNumberGraduation,
NumberGraduation | public class NumberGraduation extends AbstractGraduation (Code) | | A graduation using numbers on a linear axis.
since: 2.0 version: $Id: NumberGraduation.java 23632 2006-12-29 22:13:51Z desruisseaux $ author: Martin Desruisseaux |
Constructor Summary | |
public | NumberGraduation(Unit unit) Construct a graduation with the supplied units. |
Method Summary | |
public boolean | equals(Object object) Compares this graduation with the specified object for equality. | public Format | getFormat() Returns the format to use for formatting labels. | public double | getMaximum() Returns the maximal value for this graduation. | public double | getMinimum() | public synchronized double | getRange() Returns the graduation's range. | public synchronized TickIterator | getTickIterator(RenderingHints hints, TickIterator reuse) Returns an iterator object that iterates along the graduation ticks and provides access to
the graduation values. | NumberIterator | getTickIterator(TickIterator reuse, Locale locale) Constructs or reuses an iterator. | public int | hashCode() Returns a hash value for this graduation. | public synchronized boolean | setMaximum(double value) Set the maximum value for this graduation. | public synchronized boolean | setMinimum(double value) Set the minimum value for this graduation. | public void | setRange(double min, double max, Unit unit) Sets the graduation's minimum, maximum and units. | public synchronized void | setUnit(Unit newUnit) Changes the graduation's units. |
NumberGraduation | public NumberGraduation(Unit unit)(Code) | | Construct a graduation with the supplied units.
Parameters: unit - The axis's units, or null if unknow. |
equals | public boolean equals(Object object)(Code) | | Compares this graduation with the specified object for equality.
This method do not compare registered listeners.
|
getFormat | public Format getFormat()(Code) | | Returns the format to use for formatting labels. The format really used by
TickIterator.currentLabel may not be the same. For example, some
iterators may adjust automatically the number of fraction digits.
|
getTickIterator | public synchronized TickIterator getTickIterator(RenderingHints hints, TickIterator reuse)(Code) | | Returns an iterator object that iterates along the graduation ticks and provides access to
the graduation values. If an optional
RenderingHints is specified, tick locations are
adjusted according values for
NumberGraduation.VISUAL_AXIS_LENGTH and
NumberGraduation.VISUAL_TICK_SPACING keys.
Parameters: hints - Rendering hints, or null for the default hints. Parameters: reuse - An iterator to reuse if possible, or null to create a new one. Anon-null object may help to reduce the number of object garbage-collected whenrendering the axis. A iterator to use for iterating through the graduation. Thisiterator may or may not be the reuse object. |
hashCode | public int hashCode()(Code) | | Returns a hash value for this graduation.
|
setRange | public void setRange(double min, double max, Unit unit)(Code) | | Sets the graduation's minimum, maximum and units. This method will fire property change
events for
"minimum" ,
"maximum" and
"unit" property names.
|
setUnit | public synchronized void setUnit(Unit newUnit) throws ConversionException(Code) | | Changes the graduation's units. This method will automatically convert minimum and
maximum values from the old units to the new one.
Parameters: newUnit - The new units, or null if unknow.If null, minimum and maximum values are not converted. throws: ConversionException - if units are not convertible. |
|
|