ucar.nc2.ft
Interface NestedPointFeatureCollection

All Superinterfaces:
FeatureCollection
All Known Subinterfaces:
ProfileFeatureCollection, SectionFeature, SectionFeatureCollection, StationProfileFeature, StationProfileFeatureCollection, StationTimeSeriesFeatureCollection, TrajectoryFeatureCollection

public interface NestedPointFeatureCollection
extends FeatureCollection

A collection of PointFeatures nested inside one or more PointFeatureCollection.

Since:
Mar 20, 2008
Author:
caron

Method Summary
 PointFeatureCollection flatten(LatLonRect boundingBox, DateRange dateRange)
          Flatten into a PointFeatureCollection, discarding connectedness information.
 NestedPointFeatureCollectionIterator getNestedPointFeatureCollectionIterator(int bufferSize)
          Iterate through the collection, composed of NestedPointFeatureCollection.
 PointFeatureCollectionIterator getPointFeatureCollectionIterator(int bufferSize)
          Iterate through the collection, composed of PointFeatureCollection.
 boolean isMultipleNested()
          If true, use getNestedPointFeatureCollectionIterator, otherwise use getPointFeatureCollectionIterator.
 int size()
          The number of elements in the collection.
 NestedPointFeatureCollection subset(LatLonRect boundingBox)
          Get a subsetted NestedPointFeatureCollection based on a LatLonRect
 
Methods inherited from interface ucar.nc2.ft.FeatureCollection
getCollectionFeatureType, getName
 

Method Detail

size

int size()
The number of elements in the collection. May not be known until after iterating through the collection.

Returns:
number of elements in the collection, or -1 if not known.

isMultipleNested

boolean isMultipleNested()
If true, use getNestedPointFeatureCollectionIterator, otherwise use getPointFeatureCollectionIterator.

Returns:
if multiple nested

getPointFeatureCollectionIterator

PointFeatureCollectionIterator getPointFeatureCollectionIterator(int bufferSize)
                                                                 throws java.io.IOException
Iterate through the collection, composed of PointFeatureCollection. Use this only if isMultipleNested() = false.

Parameters:
bufferSize - how many bytes can be used to buffer data, use -1 to use default.
Returns:
an iterator through PointFeatureCollection objects.
Throws:
java.io.IOException - on read error

getNestedPointFeatureCollectionIterator

NestedPointFeatureCollectionIterator getNestedPointFeatureCollectionIterator(int bufferSize)
                                                                             throws java.io.IOException
Iterate through the collection, composed of NestedPointFeatureCollection. Use this only if isMultipleNested() = true.

Parameters:
bufferSize - how many bytes can be used to buffer data, use -1 to use default.
Returns:
an iterator through NestedPointFeatureCollection objects.
Throws:
java.io.IOException - on read error

subset

NestedPointFeatureCollection subset(LatLonRect boundingBox)
                                    throws java.io.IOException
Get a subsetted NestedPointFeatureCollection based on a LatLonRect

Parameters:
boundingBox - spatial subset
Returns:
subsetted collection
Throws:
java.io.IOException - on i/o error

flatten

PointFeatureCollection flatten(LatLonRect boundingBox,
                               DateRange dateRange)
                               throws java.io.IOException
Flatten into a PointFeatureCollection, discarding connectedness information. Optionally subset.

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:
java.io.IOException - on read error