Package ucar.unidata.data.radar
Class Level2Adapter
java.lang.Object
ucar.unidata.data.radar.Level2Adapter
- All Implemented Interfaces:
RadarAdapter
,RadarConstants
Adapt an Archive Level II file to a VisAD data structure.
- Version:
- $Revision: 1.111 $
- Author:
- IDV Development team
-
Field Summary
Fields inherited from interface ucar.unidata.data.radar.RadarAdapter
AZIMUTH_ANGLE_TYPE, AZIMUTH_TYPE, ELEVATION_ANGLE_TYPE, RANGE_TYPE
Fields inherited from interface ucar.unidata.data.radar.RadarConstants
AZIMUTH, AZIMUTH_ANGLE, ELEVATION_ANGLE, PROP_2DOR3D, PROP_ANGLE, PROP_ANGLES, PROP_AZIMUTH, PROP_AZIMUTHS, PROP_CAPPI_LEVEL, PROP_CAPPI_LEVELS, PROP_TIMEHEIGHT, PROP_VCS, PROP_VCS_END, PROP_VCS_START, PROP_VOLUMEORSWEEP, PROP_VWP, RADAR_MOST_RECENT, RADIAL_VELOCITY_NAME, RANGE, REFLECTIVITY, REFLECTIVITY_NAME, SPECTRUM_WIDTH, SPECTRUM_WIDTH_NAME, STATION_LOCATION, VALUE_2D, VALUE_3D, VALUE_SWEEP, VALUE_VOLUME, VELOCITY
-
Constructor Summary
ConstructorsConstructorDescriptionLevel2Adapter
(DataSourceImpl source, String filename) Construct a new Level2AdapterLevel2Adapter
(DataSourceImpl source, String filename, EarthLocation radarLocation) Construct a new Level2Adapter for the radar location given -
Method Summary
Modifier and TypeMethodDescriptionvoid
Implement the interce.void
doRemove()
Clean up whatever we need to when we are removed.double[]
Get the array of sweep tilts in this files volume scan.Get the starting time of this VolumeGet a CAPPI for the given moment at the given levelgetCut
(int moment, double elevation) Get a 2D sweep of a particular moment at the specified elevation angle.getCut
(int moment, double elevation, boolean want3D) Get a 2D sweep of a particular moment at the specified elevation angle.getData
(DataChoice choice, DataSelection ds, Hashtable requestProperties) Get the data for this DataChoicestatic String
getMomentName
(int moment) Print out the name of the moment.getName()
Return the name of the filegetRHI
(int moment, double rhiAz) Get an RHI for the given azimuthstatic NamedStationTable
Read in the nexrad stations from the idv/resources/nexradstns.xml resourcegetVolume
(int moment) Makes a field of all data from one level II file (one volume scan); which is composed of severla azimuthal sweeps at different angles (titls, elevations) above the horizontal.getVWP
(double altitudeLimit) Make a data object to display in the IDV as a VAD Wind Profile.void
Set the radar locationtoString()
String representation of this adapter.
-
Constructor Details
-
Level2Adapter
public Level2Adapter(DataSourceImpl source, String filename) throws VisADException, RemoteException, IOException Construct a new Level2Adapter- Parameters:
source
- DataSource for cachingfilename
- path of file- Throws:
VisADException
- couldn't create VisAD objectRemoteException
- couldn't create remote objectIOException
- problem opening or reading file
-
Level2Adapter
public Level2Adapter(DataSourceImpl source, String filename, EarthLocation radarLocation) throws VisADException, RemoteException, IOException Construct a new Level2Adapter for the radar location given- Parameters:
source
- DataSource for cachingfilename
- path of fileradarLocation
- location of the radar- Throws:
VisADException
- couldn't create VisAD objectRemoteException
- couldn't create remote objectIOException
- problem opening or reading file
-
-
Method Details
-
clearCachedData
public void clearCachedData()Implement the interce. For now lets not do anything- Specified by:
clearCachedData
in interfaceRadarAdapter
-
getBaseTime
Get the starting time of this Volume- Specified by:
getBaseTime
in interfaceRadarAdapter
- Returns:
- starting time
-
getAngles
public double[] getAngles()Get the array of sweep tilts in this files volume scan.- Returns:
- tilts
-
setRadarLocation
Set the radar location- Parameters:
el
- location of the radar- Throws:
VisADException
- couldn't create VisAD objectRemoteException
- couldn't create remote object
-
getData
public DataImpl getData(DataChoice choice, DataSelection ds, Hashtable requestProperties) throws VisADException, RemoteException Get the data for this DataChoice- Specified by:
getData
in interfaceRadarAdapter
- Parameters:
choice
- choice describing the datads
- sub-selection criteriarequestProperties
- extra request criteria (e.g, used to get RHI azimuth)- Returns:
- VisAD Data object corresponding to this DataChoice
- Throws:
VisADException
- couldn't create VisAD objectRemoteException
- couldn't create remote object
-
getCut
Get a 2D sweep of a particular moment at the specified elevation angle.- Parameters:
moment
- moment (REFLECTIVITY, VELOCITY, SPECTRUM_WIDTH) of dataelevation
- elevation angle- Returns:
- a FlatField representation of the cut
- Throws:
RemoteException
- couldn't create remote objectVisADException
- couldn't create VisAD object
-
getCut
public FlatField getCut(int moment, double elevation, boolean want3D) throws VisADException, RemoteException Get a 2D sweep of a particular moment at the specified elevation angle.- Parameters:
moment
- moment (REFLECTIVITY, VELOCITY, SPECTRUM_WIDTH) of dataelevation
- elevation anglewant3D
- true if you want this as a 3-D field- Returns:
- a 2- or 3-D FlatField representation of the cut
- Throws:
RemoteException
- couldn't create remote objectVisADException
- couldn't create VisAD object
-
getVWP
Make a data object to display in the IDV as a VAD Wind Profile. for one time.- Parameters:
altitudeLimit
- typically 10 to 15 km; highest wind used.- Returns:
- VWP for the given altitude limit
- Throws:
RemoteException
- couldn't create remote objectVisADException
- couldn't create VisAD object
-
getRHI
Get an RHI for the given azimuth- Parameters:
moment
- moment (REFLECTIVITY, VELOCITY, SPECTRUM_WIDTH) of datarhiAz
- azimuth for the RHI- Returns:
- RHI as a Field of FlatFields, each for a particular elevation angle
- Throws:
RemoteException
- couldn't create remote objectVisADException
- couldn't create VisAD object
-
getCAPPI
Get a CAPPI for the given moment at the given level- Parameters:
moment
- moment (REFLECTIVITY, VELOCITY, SPECTRUM_WIDTH) of datalevel
- level (Altitude)- Returns:
- CAPPI as a Field
- Throws:
RemoteException
- couldn't create remote objectVisADException
- couldn't create VisAD object
-
toString
String representation of this adapter. -
getName
Return the name of the file- Specified by:
getName
in interfaceRadarAdapter
- Returns:
- name
-
getVolume
Makes a field of all data from one level II file (one volume scan); which is composed of severla azimuthal sweeps at different angles (titls, elevations) above the horizontal. Character of data field when plotted with ColorRadarVolumeControl is colored data point values (pixels) along beam lines, forming semi-transparent nested cones, not filled surfaces.- Parameters:
moment
- moment (REFLECTIVITY, VELOCITY, SPECTRUM_WIDTH) of data- Returns:
- volume as a FieldImpl
- Throws:
RemoteException
- couldn't create remote objectVisADException
- couldn't create VisAD object
-
getStations
Read in the nexrad stations from the idv/resources/nexradstns.xml resource- Returns:
- List of of
NamedStation
-s
-
getMomentName
Print out the name of the moment.- Parameters:
moment
- radar moment (ex: REFLECTIVITY)- Returns:
- a String name of the moment (ex: "Reflectivity");
-
doRemove
public void doRemove()Clean up whatever we need to when we are removed.- Specified by:
doRemove
in interfaceRadarAdapter
-