|
Venice 0.7beta | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.mov.chart.graph.AbstractGraph
public abstract class AbstractGraph
Set the default values for a graph based on a single
GraphSource
. All graphs that are based on a single
GraphSource
object will almost certainly want to use these
default values. Graphs that use multiple GraphSource
objects will still probably want to extend this class and override
any differences.
Graph
,
GraphUI
,
GraphSource
Field Summary |
---|
Fields inherited from interface org.mov.chart.graph.Graph |
---|
TOOL_TIP_BUFFER |
Constructor Summary | |
---|---|
AbstractGraph(GraphSource source)
Set the default values to the ones provided by this GraphSource . |
Method Summary | |
---|---|
double[] |
getAcceptableMajorDeltas()
Return an array of acceptable major deltas for the vertical axis. |
double[] |
getAcceptableMinorDeltas()
Return an array of acceptable minor deltas for the vertical axis. |
java.lang.Comparable |
getEndX()
Get the last X value that this graph will draw. |
double |
getHighestY(java.util.List xRange)
Return the highest Y value in the given X range. |
double |
getLowestY(java.util.List xRange)
Return the loweset Y value in the given X range. |
java.util.HashMap |
getSettings()
Return the graph's current settings. |
protected GraphSource |
getSource()
Get underlying GraphSource we are using for default
values. |
java.lang.String |
getSourceName()
Return the name of the source data that we are graphing, e.g. |
java.lang.Comparable |
getStartX()
Get the first X value that this graph will draw. |
java.lang.String |
getToolTipText(java.lang.Comparable x,
int y,
int yoffset,
double verticalScale,
double bottomLineValue)
Get the tool tip text for the given X value and y coordinate. |
GraphUI |
getUI(java.util.HashMap settings)
Returns the graph's user interface. |
java.util.Set |
getXRange()
Get all X values that this graph will draw. |
java.lang.Double |
getY(java.lang.Comparable x)
Return the Y value for the given X value. |
java.lang.String |
getYLabel(double value)
Convert the Y value to a label to be displayed in the vertical axis. |
void |
setSettings(java.util.HashMap settings)
Set the graph's user definable settings. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.mov.chart.graph.Graph |
---|
getName, isPrimary, render |
Constructor Detail |
---|
public AbstractGraph(GraphSource source)
GraphSource
.
source
- default GraphSource
to useMethod Detail |
---|
protected GraphSource getSource()
GraphSource
we are using for default
values.
GraphSource
public java.lang.String getToolTipText(java.lang.Comparable x, int y, int yoffset, double verticalScale, double bottomLineValue)
getToolTipText
in interface Graph
x
- the X valuey
- the y coordinateyoffset
- y offset from top of graphverticalScale
- vertical scale factorbottomLineValue
- the Y value of the lowest line in the graph
GraphSource
public java.lang.Comparable getStartX()
getStartX
in interface Graph
GraphSource
's Graphable
public java.lang.Comparable getEndX()
getEndX
in interface Graph
GraphSource
's Graphable
public java.util.Set getXRange()
getXRange
in interface Graph
GraphSource
's
Graphable
public java.lang.String getYLabel(double value)
getYLabel
in interface Graph
value
- y value
GraphSource
would displaypublic java.lang.String getSourceName()
CBA
.
getSourceName
in interface Graph
public java.lang.Double getY(java.lang.Comparable x)
getY
in interface Graph
x
- value
GraphSource
public double getHighestY(java.util.List xRange)
getHighestY
in interface Graph
xRange
- range of X values
GraphSource
public double getLowestY(java.util.List xRange)
getLowestY
in interface Graph
xRange
- range of X values
GraphSource
public double[] getAcceptableMajorDeltas()
getAcceptableMajorDeltas
in interface Graph
GraphSource
public double[] getAcceptableMinorDeltas()
getAcceptableMinorDeltas
in interface Graph
GraphSource
Graph.getAcceptableMajorDeltas()
public java.util.HashMap getSettings()
getSettings
in interface Graph
public void setSettings(java.util.HashMap settings)
setSettings
in interface Graph
settings
- the new settingspublic GraphUI getUI(java.util.HashMap settings)
null
which indicates that the graph does not
have a user interface. If the graph does have a user interface then
it should override this method.
getUI
in interface Graph
settings
- initial settings (ignored)
null
|
Venice 0.7beta | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |