ucar.nc2.ft.point.remote
Class RemoteStationCollection

java.lang.Object
  extended by ucar.nc2.ft.point.OneNestedPointCollectionImpl
      extended by ucar.nc2.ft.point.StationTimeSeriesCollectionImpl
          extended by ucar.nc2.ft.point.remote.RemoteStationCollection
All Implemented Interfaces:
FeatureCollection, NestedPointFeatureCollection, StationCollection, StationTimeSeriesFeatureCollection

public class RemoteStationCollection
extends StationTimeSeriesCollectionImpl

Connect to remote Station Collection using cdmremote

Author:
caron

Field Summary
protected  LatLonRect boundingBoxSubset
           
protected  DateRange dateRangeSubset
           
 
Fields inherited from class ucar.nc2.ft.point.StationTimeSeriesCollectionImpl
localIterator, stationHelper
 
Fields inherited from class ucar.nc2.ft.point.OneNestedPointCollectionImpl
npts
 
Constructor Summary
  RemoteStationCollection(String uri)
          Constructor.
protected RemoteStationCollection(String uri, StationHelper sh)
          Constructor for a subset.
 
Method Summary
 PointFeatureCollection flatten(LatLonRect boundingBox, DateRange dateRange)
          Flatten into a PointFeatureCollection, discarding connectedness information.
 Station getStation(PointFeature feature)
          Get the station that belongs to this feature
protected  void initStationHelper()
          initialize the stationHelper.
 StationTimeSeriesFeatureCollection subset(LatLonRect boundingBox)
          Get a subsetted StationCollection from a LatLonRect
 StationTimeSeriesFeatureCollection subset(List<Station> stations)
          Get a subsetted StationCollection based on a list of Stations.
 
Methods inherited from class ucar.nc2.ft.point.StationTimeSeriesCollectionImpl
finish, flatten, getBoundingBox, getNestedPointFeatureCollectionIterator, getPointFeatureCollectionIterator, getStation, getStationFeature, getStations, getStations, getStations, hasNext, next, resetIteration
 
Methods inherited from class ucar.nc2.ft.point.OneNestedPointCollectionImpl
getCollectionFeatureType, getName, isMultipleNested, setSize, size
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface ucar.nc2.ft.NestedPointFeatureCollection
isMultipleNested, size
 
Methods inherited from interface ucar.nc2.ft.FeatureCollection
getCollectionFeatureType, getName
 

Field Detail

boundingBoxSubset

protected LatLonRect boundingBoxSubset

dateRangeSubset

protected DateRange dateRangeSubset
Constructor Detail

RemoteStationCollection

public RemoteStationCollection(String uri)
Constructor. defererred station list.

Parameters:
uri - cdmremote endpoint

RemoteStationCollection

protected RemoteStationCollection(String uri,
                                  StationHelper sh)
Constructor for a subset. defererred station list.

Parameters:
uri - cdmremote endpoint
sh - station Helper subset or null.
Method Detail

initStationHelper

protected void initStationHelper()
initialize the stationHelper.

Specified by:
initStationHelper in class StationTimeSeriesCollectionImpl

getStation

public Station getStation(PointFeature feature)
                   throws IOException
Description copied from interface: StationTimeSeriesFeatureCollection
Get the station that belongs to this feature

Specified by:
getStation in interface StationTimeSeriesFeatureCollection
Overrides:
getStation in class StationTimeSeriesCollectionImpl
Parameters:
feature - PointFeature obtained from a StationTimeSeriesFeature in this collection
Returns:
the Station is belongs to
Throws:
IOException - on i/o error

subset

public StationTimeSeriesFeatureCollection subset(List<Station> stations)
                                          throws IOException
Description copied from interface: StationTimeSeriesFeatureCollection
Get a subsetted StationCollection based on a list of Stations.

Specified by:
subset in interface StationTimeSeriesFeatureCollection
Overrides:
subset in class StationTimeSeriesCollectionImpl
Parameters:
stations - only contain these stations
Returns:
subsetted collection
Throws:
IOException - on i/o error

subset

public StationTimeSeriesFeatureCollection subset(LatLonRect boundingBox)
                                          throws IOException
Description copied from interface: StationTimeSeriesFeatureCollection
Get a subsetted StationCollection from a LatLonRect

Specified by:
subset in interface NestedPointFeatureCollection
Specified by:
subset in interface StationTimeSeriesFeatureCollection
Overrides:
subset in class StationTimeSeriesCollectionImpl
Parameters:
boundingBox - spatial subset. may be null
Returns:
subsetted collection
Throws:
IOException - on i/o error

flatten

public PointFeatureCollection flatten(LatLonRect boundingBox,
                                      DateRange dateRange)
                               throws IOException
Description copied from interface: NestedPointFeatureCollection
Flatten into a PointFeatureCollection, discarding connectedness information. Optionally subset.

Specified by:
flatten in interface NestedPointFeatureCollection
Overrides:
flatten in class StationTimeSeriesCollectionImpl
Parameters:
boundingBox - only points in this lat/lon bounding box. may be null.
dateRange - only points in this date range. may be null.
Returns:
a PointFeatureCollection, may be null if its empty.
Throws:
IOException - on read error


Copyright © 1999-2011 UCAR/Unidata. All Rights Reserved.