lt.monarch.chart.chart2D.series
Class AbstractQuoteStrategy<ChartProjector extends Projector>

java.lang.Object
  extended by lt.monarch.chart.chart2D.series.AbstractQuoteStrategy<ChartProjector>
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
QuoteCandleStrategy, QuoteHLCStrategy, QuoteHLStrategy

public abstract class AbstractQuoteStrategy<ChartProjector extends Projector>
extends java.lang.Object
implements java.io.Serializable

Abstract quote strategy class. It defines what methods the quote strategies should implement and implements common methods for all strategies in it.

See Also:
Serialized Form

Field Summary
Modifier and Type Field and Description
protected  java.lang.Object baseValue
          Base value of the series
protected  boolean dirty
          True, if dirty, otherwise -false
protected  PlaneMapper mapper
          Plane mapper
protected  MetaDataModel metaModel
          Meta data model
protected  java.util.Map<DataColumnType,MinMaxValues> minMaxValues
          Minimum and Maximum values
protected  ArrayDataModel model
          Series data model
protected  PaintMode paintMode
          Paint mode of the series
protected  Point2D planePoint
          Template point for mapping plane
protected  Projector projector
          Point projector
protected  Style style
          Style of series
protected  GeneralPoint tempPoint
          Template point for projecting points
protected  AxisMapper xMapper
          X axis mapper
protected  AxisMapper yMapper
          Y axis mapper
protected  double zoomMultiplier
          Zoom multiplier
 
Constructor Summary
Constructor and Description
AbstractQuoteStrategy()
           
 
Method Summary
Modifier and Type Method and Description
abstract  void dispose()
          Disposes the object
 void draw(AbstractGraphics g, ChartProjector projector, PlaneMapper mapper, HotSpotMap hotMap, Style style, java.lang.Object baseValue, StockSeries series)
          Draws the series in the chart area.
protected  void finalize()
           
protected  java.util.Map<DataColumnType,MinMaxValues> getMinMaxValues()
          Gets the minMaxValues value
protected  Point2D projectPoint(Projector projector, GeneralPoint ptt, Point2D planePoint, double x, double y)
          Projects the point
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

xMapper

protected AxisMapper xMapper
X axis mapper


yMapper

protected AxisMapper yMapper
Y axis mapper


model

protected ArrayDataModel model
Series data model


metaModel

protected MetaDataModel metaModel
Meta data model


mapper

protected PlaneMapper mapper
Plane mapper


style

protected Style style
Style of series


zoomMultiplier

protected double zoomMultiplier
Zoom multiplier


tempPoint

protected GeneralPoint tempPoint
Template point for projecting points


planePoint

protected Point2D planePoint
Template point for mapping plane


baseValue

protected java.lang.Object baseValue
Base value of the series


projector

protected Projector projector
Point projector


paintMode

protected PaintMode paintMode
Paint mode of the series


dirty

protected boolean dirty
True, if dirty, otherwise -false


minMaxValues

protected java.util.Map<DataColumnType,MinMaxValues> minMaxValues
Minimum and Maximum values

Constructor Detail

AbstractQuoteStrategy

public AbstractQuoteStrategy()
Method Detail

draw

public void draw(AbstractGraphics g,
                 ChartProjector projector,
                 PlaneMapper mapper,
                 HotSpotMap hotMap,
                 Style style,
                 java.lang.Object baseValue,
                 StockSeries series)
Draws the series in the chart area.

Parameters:
g - graphics context
projector - projector instance
mapper - plane mapper
hotMap - hot spot map
style - style object
baseValue - base value
series - scatter series instance

dispose

public abstract void dispose()
Disposes the object


finalize

protected void finalize()
                 throws java.lang.Throwable
Overrides:
finalize in class java.lang.Object
Throws:
java.lang.Throwable

projectPoint

protected Point2D projectPoint(Projector projector,
                               GeneralPoint ptt,
                               Point2D planePoint,
                               double x,
                               double y)
Projects the point

Parameters:
projector - projector
ptt - template point
planePoint - template point to map plane coordinates
x - x coordinate to map
y - y coordinate to map

getMinMaxValues

protected java.util.Map<DataColumnType,MinMaxValues> getMinMaxValues()
Gets the minMaxValues value

Returns:
the minMaxValues value