Package ucar.unidata.idv.control
Class ProbeRowInfo
java.lang.Object
ucar.unidata.idv.control.ProbeRowInfo
Class ProbeRowInfo holds the state for each row in the probe control.
- Author:
- IDV Development Team
-
Constructor Summary
ConstructorsConstructorDescriptionctorProbeRowInfo(ProbeControl control) ctorProbeRowInfo(ProbeControl control, DataInstance dataInstance) ctorProbeRowInfo(Real level, Real alt, int mode, Unit unit, MidiProperties midiProperties) ctor used for creating a ProbeRowInfo from legacy bundles values -
Method Summary
Modifier and TypeMethodDescriptionprotected voidClear any cached samplesGet the Altitude property.Get the data instanceprotected ObjectGet the DisplayValue property.protected StringgetExtra()extra stuff for tableGet the data instancegetLevel()Get the Level property.Get the LineState property.Get the MidiProperties property.intGet the point indexGet the PointParameter property.Get the point parameter nameGet the last point sampleGet the sample we last used.protected RealGet the value as a Real.protected RealgetRealValue(Data timeSample) Get the value at the time sampleintGet the SamplingMode property.Get the station nameprotected DataGet the time sampleprotected Settime setGet the TupleType for the datagetUnit()Get the Unit property.Get the sample we last usedprotected voidinitWith(ProbeRowInfo that) Sort of a copy ctorbooleanisGrid()Are we probing on gridsbooleanisPoint()Is this for point dataprotected voidplaySound(double value) Play a sound for the particular row and valuevoidsetAltitude(Real value) Set the Altitude property.protected voidSet the data instanceprotected voidsetDisplayValue(Object value) Set the DisplayValue property.protected voidextra stuff for tablevoidSet the Level property.voidsetLineState(LineState value) Set the LineState property.voidsetMidiProperties(MidiProperties value) Set the MidiProperties property.voidsetPointParameter(String value) Set the PointParameter property.protected voidsetPointSample(FieldImpl sample, EarthLocation elt) Set the sample we last usedvoidsetSamplingMode(int value) Set the SamplingMode property.voidsetStationName(PointOb ob, DisplayControlImpl control) Set the station nameprotected voidsetTimeSample(Data rt) Set the raw value from the Data.voidSet the Unit property.protected voidsetWorkingGrid(FieldImpl grid) Set the working grid for this rowprotected voidshowSoundDialog(ProbeControl control) Show the sound dialogtoString()to string
-
Constructor Details
-
ProbeRowInfo
public ProbeRowInfo()ctor -
ProbeRowInfo
ctor- Parameters:
control- The control we're in. Just use it for getting the sampling mode
-
ProbeRowInfo
ctor used for creating a ProbeRowInfo from legacy bundles values- Parameters:
level- levelalt- altitudemode- sampling modeunit- display unitmidiProperties- sound configuartion
-
ProbeRowInfo
ctor- Parameters:
control- the controldataInstance- data instance
-
-
Method Details
-
isGrid
public boolean isGrid()Are we probing on grids- Returns:
- Is this data a grid
-
isPoint
public boolean isPoint()Is this for point data- Returns:
- true if point data
-
setExtra
extra stuff for table- Parameters:
s- extra
-
getExtra
extra stuff for table- Returns:
- extra
-
clearCachedSamples
protected void clearCachedSamples()Clear any cached samples -
setTimeSample
Set the raw value from the Data. If rt is null then set raw value to null. Else if rt is a RealTuple then use the first component else assume it is a Real- Parameters:
rt- The data- Throws:
RemoteException- On badnessVisADException- On badness
-
getTimeSample
Get the time sample- Returns:
- the time sample
-
initWith
Sort of a copy ctor- Parameters:
that- that
-
showSoundDialog
Show the sound dialog- Parameters:
control- control I'm in- Throws:
RemoteException- On badnessVisADException- On badness
-
toString
to string -
playSound
protected void playSound(double value) Play a sound for the particular row and value- Parameters:
value- value of data
-
setDisplayValue
Set the DisplayValue property.- Parameters:
value- The new value for DisplayValue
-
getDisplayValue
Get the DisplayValue property.- Returns:
- The DisplayValue
-
getGridDataInstance
Get the data instance- Returns:
- The data instance
-
getDataInstance
Get the data instance- Returns:
- The data instance
-
setDataInstance
Set the data instance- Parameters:
di- The data instance
-
getTupleType
Get the TupleType for the data- Returns:
- the type
- Throws:
RemoteException- Java RMI problemVisADException- VisAD problem
-
getRealValue
Get the value as a Real. We may be a Real, if so then return. Else we may be a RealTuple. If so return the 0th component.- Returns:
- My value as a Real
- Throws:
RemoteException- On badnessVisADException- On badness
-
getRealValue
Get the value at the time sample- Parameters:
timeSample- the time sample- Returns:
- the value
- Throws:
RemoteException- On badnessVisADException- On badness
-
getPointParameterName
Get the point parameter name- Returns:
- the name
- Throws:
RemoteException- On badnessVisADException- On badness
-
getPointIndex
Get the point index- Returns:
- the index
- Throws:
RemoteException- On badnessVisADException- On badness
-
setUnit
Set the Unit property.- Parameters:
value- The new value for Unit
-
setWorkingGrid
Set the working grid for this row- Parameters:
grid-
-
getWorkingGrid
Get the sample we last used- Returns:
- sample
-
setPointSample
protected void setPointSample(FieldImpl sample, EarthLocation elt) throws VisADException, RemoteException Set the sample we last used- Parameters:
sample- sampleelt- The point we sampled on- Throws:
RemoteException- On badnessVisADException- On badness
-
setStationName
public void setStationName(PointOb ob, DisplayControlImpl control) throws VisADException, RemoteException Set the station name- Parameters:
ob- the point observationcontrol- The display control this is part of- Throws:
RemoteException- On badnessVisADException- On badness
-
getTimeSet
time set- Returns:
- time set
- Throws:
RemoteException- On badnessVisADException- On badness
-
getPointSample
Get the last point sample- Returns:
- Point sample
-
getPointSample
Get the sample we last used. If The given earth location is not the same as the location of the last point we sampled on then null out the sample and return null.- Parameters:
elt- The point we want to sample on- Returns:
- sample
-
getUnit
Get the Unit property.- Returns:
- The Unit
-
setLevel
Set the Level property.- Parameters:
value- The new value for Level
-
getLevel
Get the Level property.- Returns:
- The Level
-
setAltitude
Set the Altitude property.- Parameters:
value- The new value for Altitude
-
getAltitude
Get the Altitude property.- Returns:
- The Altitude
-
setSamplingMode
public void setSamplingMode(int value) Set the SamplingMode property.- Parameters:
value- The new value for SamplingMode
-
getSamplingMode
public int getSamplingMode()Get the SamplingMode property.- Returns:
- The SamplingMode
-
setMidiProperties
Set the MidiProperties property.- Parameters:
value- The new value for MidiProperties
-
getMidiProperties
Get the MidiProperties property.- Returns:
- The MidiProperties
-
setLineState
Set the LineState property.- Parameters:
value- The new value for LineState
-
getLineState
Get the LineState property.- Returns:
- The LineState
-
getStationName
Get the station name- Returns:
- the name or null
-
setPointParameter
Set the PointParameter property.- Parameters:
value- The new value for PointParameter
-
getPointParameter
Get the PointParameter property.- Returns:
- The PointParameter
-