lt.monarch.chart.mapper
Class AbstractAxisMapperRange

java.lang.Object
  extended by lt.monarch.chart.mapper.AbstractAxisMapperRange
All Implemented Interfaces:
java.io.Serializable, AxisMapperRange, Range<java.lang.Double>
Direct Known Subclasses:
SimpleAxisMapperRange

public abstract class AbstractAxisMapperRange
extends java.lang.Object
implements AxisMapperRange, java.io.Serializable

Base implementation of the axis mapper range.

See Also:
Serialized Form

Constructor Summary
Constructor and Description
AbstractAxisMapperRange()
           
 
Method Summary
Modifier and Type Method and Description
 void addListener(AxisMapperRangeListener listener)
          Adds the specified axis mapper range listener to receive notification when range is adjusting, is shifted or changed.
protected  void fireRangeAdjusting()
          Notifies all listeners that axis mapper range adjustment mode changed.
protected  void fireRangeChanged()
          Notifies all listeners that axis mapper range changed.
protected  void fireRangeShifted()
          Notifies all listeners that axis mapper range shifted.
 boolean isAdjusting()
          Returns true if the range is being changed and has not been finalized yet.
 void removeListener(AxisMapperRangeListener listener)
          Removes the specified axis mapper range listener so that it no longer receives notifications from this mapper range.
 void setIsAdjusting(boolean adjusting)
          Sets/unsets adjustment mode.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface lt.monarch.chart.mapper.AxisMapperRange
isMoreZoomAvailable, setExtent, setMinimum, setRange
 
Methods inherited from interface lt.monarch.chart.mapper.Range
getMaximum, getMinimum
 

Constructor Detail

AbstractAxisMapperRange

public AbstractAxisMapperRange()
Method Detail

addListener

public void addListener(AxisMapperRangeListener listener)
Adds the specified axis mapper range listener to receive notification when range is adjusting, is shifted or changed. If listener is null, no exception is thrown and no action is performed.

Specified by:
addListener in interface AxisMapperRange
Parameters:
listener - the axis mapper range listener
See Also:
AxisMapperRangeListener

removeListener

public void removeListener(AxisMapperRangeListener listener)
Removes the specified axis mapper range listener so that it no longer receives notifications from this mapper range. If listener is null, no exception is thrown and no action is performed.

Specified by:
removeListener in interface AxisMapperRange
Parameters:
listener - the axis mapper range listener
See Also:
AxisMapperRangeListener

isAdjusting

public boolean isAdjusting()
Returns true if the range is being changed and has not been finalized yet.

Specified by:
isAdjusting in interface AxisMapperRange
Returns:
is range still adjusting

setIsAdjusting

public void setIsAdjusting(boolean adjusting)
Sets/unsets adjustment mode. Informs that values are not final and may change.

Specified by:
setIsAdjusting in interface AxisMapperRange
Parameters:
adjusting - true, if values are final, false otherwise

fireRangeAdjusting

protected void fireRangeAdjusting()
Notifies all listeners that axis mapper range adjustment mode changed.


fireRangeShifted

protected void fireRangeShifted()
Notifies all listeners that axis mapper range shifted.


fireRangeChanged

protected void fireRangeChanged()
Notifies all listeners that axis mapper range changed.