Package hec.gfx2d
Class PairedDataSet
java.lang.Object
java.util.Observable
hec.gfx2d.G2dData
hec.gfx2d.PairedDataSet
- All Implemented Interfaces:
G2dObject,Serializable
- Direct Known Subclasses:
PairedDataHistogramDataSet
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionboolean[]intintdouble[]double[][]Fields inherited from interface hec.gfx2d.G2dObject
RESET_DATA, UPDATE_DATA -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidbuildBounds(int xdivisor, int ydivisor) booleanprotected RefreshCookieReturns the extents of the object in world coordinatesintReturns the number of curves that this object contains.getData()Returns the name of the x axisintReturns the name of the x axisintOverride super class to allow swaping of x and y for plottingReturns the name of the y axisintReturns the name of the y axisintdouble[]getYValues(int curveNum) Returns a double[] for the curve specified by the curve number.booleandoes the PairedDataSet have any curves that are to be drawn?booleanisCurveDrawn(int lineNum) booleanisLoaded()booleanvoidload()Causes the object to load its data into memoryintReturns the number of y-coordinatesvoidsetCurveDrawn(int lineNum, boolean drawLine) voidsetData(PairedDataContainer pairedDataContainer) voidsetLoaded(boolean b) voidsetSwapXYValues(boolean b) voidsetVisible(boolean tf) intsize()size returns the number of valid data pointsvoidunload()Causes the object to unload its data from memoryMethods inherited from class hec.gfx2d.G2dData
addObserver, getDefaultMaxYValue, getDefaultMinYValue, getGmtOffset, getLineStyleName, getLookup, getName, getUnitSystem, getXValues, hasDefaultMaxYValue, hasDefaultMinYValue, setDefaultMaxYValue, setDefaultMinYValue, setGmtOffset, setName, setUnitSystem, setUseDisplayUnits, setXParameterId, setYParameterId, swapXYValues, toString, useDisplayUnitsMethods inherited from class java.util.Observable
clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChangedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface hec.gfx2d.G2dObject
getDataZoneId, getDefaultMaxYValue, getDefaultMinYValue, getGmtOffset, getLineStyleName, getLookup, getName, getUnitSystem, getXValues, hasDefaultMaxYValue, hasDefaultMinYValue, setDefaultMaxYValue, setDefaultMinYValue, swapXYValues
-
Field Details
-
labels
-
xtype
-
ytype
-
xdata
public double[] xdata -
_pairedData
-
ydata
public double[][] ydata -
curves
public int curves -
size
public int size -
curveDrawn
public boolean[] curveDrawn
-
-
Constructor Details
-
PairedDataSet
-
-
Method Details
-
setData
-
getData
-
getCurveCount
public int getCurveCount()Description copied from class:G2dDataReturns the number of curves that this object contains.- Specified by:
getCurveCountin interfaceG2dObject- Overrides:
getCurveCountin classG2dData
-
unload
public void unload()Causes the object to unload its data from memory -
getBounds
Returns the extents of the object in world coordinates -
buildBounds
protected void buildBounds(int xdivisor, int ydivisor) -
size
public int size()size returns the number of valid data points -
numYCoord
public int numYCoord()Returns the number of y-coordinates -
getXAxisName
Returns the name of the x axis- Specified by:
getXAxisNamein interfaceG2dObject
-
getYAxisName
Returns the name of the y axis- Specified by:
getYAxisNamein interfaceG2dObject
-
getXAxisType
public int getXAxisType()Returns the name of the x axis- Specified by:
getXAxisTypein interfaceG2dObject
-
getYAxisType
public int getYAxisType()Returns the name of the y axis- Specified by:
getYAxisTypein interfaceG2dObject
-
getXParameterId
public int getXParameterId()Override super class to allow swaping of x and y for plotting- Specified by:
getXParameterIdin interfaceG2dObject- Overrides:
getXParameterIdin classG2dData
-
getYParameterId
public int getYParameterId()- Specified by:
getYParameterIdin interfaceG2dObject- Overrides:
getYParameterIdin classG2dData
-
load
public void load()Causes the object to load its data into memory -
isLoaded
public boolean isLoaded()- Returns:
-
setSwapXYValues
public void setSwapXYValues(boolean b) - Specified by:
setSwapXYValuesin interfaceG2dObject- Overrides:
setSwapXYValuesin classG2dData
-
canSwapXYValues
public boolean canSwapXYValues()- Specified by:
canSwapXYValuesin interfaceG2dObject- Overrides:
canSwapXYValuesin classG2dData
-
isCurveDrawn
public boolean isCurveDrawn(int lineNum) -
setCurveDrawn
public void setCurveDrawn(int lineNum, boolean drawLine) -
setVisible
public void setVisible(boolean tf) -
isVisible
public boolean isVisible() -
getYValues
public double[] getYValues(int curveNum) Returns a double[] for the curve specified by the curve number.- Specified by:
getYValuesin interfaceG2dObject- Overrides:
getYValuesin classG2dData- Parameters:
curveNum-- Returns:
-
hasVisibleCurve
public boolean hasVisibleCurve()does the PairedDataSet have any curves that are to be drawn?- Returns:
-
setLoaded
public void setLoaded(boolean b) - Parameters:
b-
-
createRefreshCookie
- Returns:
-