info.monitorenter.gui.chart.traces
Class Trace2DBijective
java.lang.Object
info.monitorenter.gui.chart.traces.ATrace2D
info.monitorenter.gui.chart.traces.Trace2DSimple
info.monitorenter.gui.chart.traces.Trace2DBijective
- All Implemented Interfaces:
- ITrace2D, IComparableProperty, PropertyChangeListener, Serializable, EventListener
public class Trace2DBijective
- extends Trace2DSimple
A Trace2D
who only allows a single occurance of a tracepoint with a certain x-
value xi.
From y1 = f(x1) = f(x2) follows: x1==x2 (injective)
For every y- value yi contained there exists at least one value xi (surjective)
Both qualities joined result in a bijective assignment between x and y values.
The policy for both addPoint
- methods is implemented as follows:
- Every point whose x- value is not contained yet is appended at the end of the internal list.
- If the x- value is contained before, the tracepoint with that value is removed and the new
point is added to the end of the internal list. In that case the new tracepoint is not
inserted at the location where the old point used to be!
- Version:
- $Revision: 1.7 $
- Author:
- Achim Westermann Achim.Westermann@gmx.de
- See Also:
- Serialized Form
Fields inherited from class info.monitorenter.gui.chart.traces.ATrace2D |
m_computingTraces, m_maxX, m_maxXErrorBar, m_maxY, m_maxYErrorBar, m_minX, m_minXErrorBar, m_minY, m_minYErrorBar, m_name, m_physicalUnitsX, m_physicalUnitsY, m_propertyChangeSupport, m_renderer |
Fields inherited from interface info.monitorenter.gui.chart.ITrace2D |
PROPERTY_COLOR, PROPERTY_ERRORBARPOLICY, PROPERTY_ERRORBARPOLICY_CONFIGURATION, PROPERTY_MAX_X, PROPERTY_MAX_Y, PROPERTY_MIN_X, PROPERTY_MIN_Y, PROPERTY_NAME, PROPERTY_PAINTERS, PROPERTY_PHYSICALUNITS, PROPERTY_POINT_CHANGED, PROPERTY_STROKE, PROPERTY_TRACEPOINT, PROPERTY_VISIBLE, PROPERTY_ZINDEX, Z_INDEX_MIN, ZINDEX_MAX |
Method Summary |
boolean |
addPointInternal(TracePoint2D p)
Override this template method for the custom add operation that depends on the policies of the
implementation. |
Methods inherited from class info.monitorenter.gui.chart.traces.ATrace2D |
addComputingTrace, addErrorBarPolicy, addPoint, addPoint, addPropertyChangeListener, addTracePainter, containsTracePainter, finalize, firePointAdded, firePointChanged, firePointRemoved, firePropertyChange, getChangeListeners, getColor, getComparableProperty, getErrorBarPolicies, getHasErrorBars, getInstanceCount, getLabel, getMaxX, getMaxY, getMinX, getMinY, getName, getPhysicalUnits, getPhysicalUnitsX, getPhysicalUnitsY, getPropertyChangeListeners, getRenderer, getStroke, getTracePainters, getZIndex, isVisible, maxXSearch, maxYSearch, minXSearch, minYSearch, propertyChange, removeAllPoints, removeComputingTrace, removeErrorBarPolicy, removePoint, removePropertyChangeListener, removePropertyChangeListener, removeTracePainter, setColor, setComparableProperty, setErrorBarPolicy, setName, setPhysicalUnits, setRenderer, setStroke, setTracePainter, setVisible, setZIndex, showsErrorBars, showsNegativeXErrorBars, showsNegativeYErrorBars, showsPositiveXErrorBars, showsPositiveYErrorBars, toString |
Methods inherited from interface info.monitorenter.gui.chart.ITrace2D |
addComputingTrace, addErrorBarPolicy, addPoint, addPoint, addPropertyChangeListener, addTracePainter, containsTracePainter, firePointChanged, getColor, getErrorBarPolicies, getHasErrorBars, getLabel, getMaxX, getMaxY, getMinX, getMinY, getName, getPhysicalUnits, getPhysicalUnitsX, getPhysicalUnitsY, getPropertyChangeListeners, getRenderer, getStroke, getTracePainters, getZIndex, isVisible, removeAllPoints, removeComputingTrace, removeErrorBarPolicy, removePoint, removePropertyChangeListener, removePropertyChangeListener, removeTracePainter, setColor, setErrorBarPolicy, setName, setPhysicalUnits, setRenderer, setStroke, setTracePainter, setVisible, setZIndex, showsErrorBars, showsNegativeXErrorBars, showsNegativeYErrorBars, showsPositiveXErrorBars, showsPositiveYErrorBars |
Trace2DBijective
public Trace2DBijective()
- Defcon of this stateless instance.
addPointInternal
public boolean addPointInternal(TracePoint2D p)
- Description copied from class:
ATrace2D
- Override this template method for the custom add operation that depends on the policies of the
implementation.
No property change events have to be fired by default. If this method returns true
the outer logic of the calling method ATrace2D.addPoint(TracePoint2D)
will
perform bound checks for the new point and fire property changes as described in method
ATrace2D.firePointChanged(TracePoint2D, int)
.
In special cases - when additional modifications to the internal set of points take place (e.g.
a further point gets removed) this method should return false (regardless wether the new point
was accepted or not) and perform bound checks and fire the property changes as mentioned above
"manually".
- Overrides:
addPointInternal
in class Trace2DSimple
- Parameters:
p
- the point to add.
- Returns:
- true if the given point was accepted or false if not.
- See Also:
ATrace2D.addPointInternal(info.monitorenter.gui.chart.TracePoint2D)
Copyright © 2001 - 2007 LGPL, All Rights Footloose.