## visad.data.netcdf.in
Class DefaultView

    java.lang.Object
      visad.data.netcdf.in.View
          visad.data.netcdf.in.DefaultView

public class DefaultView
extends View

Provides support for the default view of a netCDF dataset as documented in the netCDF User's Guide.

Nested Class Summary
`(package private) class` `DefaultView.DefaultDataIterator` Iterates over the virtual VisAD data objects in a netCDF dataset.

Nested classes inherited from class visad.data.netcdf.in.View
`View.DataIterator, View.Domain`

Constructor Summary
`DefaultView(Netcdf netcdf, QuantityDB quantityDB)` Constructs from a netCDF dataset and a quantity database.
`DefaultView(Netcdf netcdf, QuantityDB quantityDB, boolean charToText)` Constructs from a netCDF dataset and a quantity database.

Method Summary
`protected View.Domain` `getDomain(Variable var)` Returns the domain of a netCDF variable.
`protected SampledSet` `getDomainSet(Dimension[] dims)` Returns the VisAD domain set corresponding to an array of netCDF dimension in netCDF order (outermost dimension first).
`protected MathType` `getDomainType(Dimension[] dims)` Returns the VisAD `MathType` corresponding to an array of netCDF dimensions.
`protected boolean` `isIgnorable(Variable var)` Indicates if a given variable should be ignored during iteration.

Methods inherited from class visad.data.netcdf.in.View

`getAttributeString, getAttributeString, getConventionsString, getCoordinateVariable, getData, getData, getDimensions, getDomainSet, getInstance, getInstance, getLongName, getNetcdf, getOuterDimensionNameSet, getRangeSet, getRealType, getRealType, getRealTypeFromLongName, getRealTypeFromName, getScalarType, getTextType, getUnitFromAttribute, getUnitString, getVariable, getVetter, getVirtualDataIterator, isCharToText, isCoordinateVariable, isLatitude, isLongitude, isLongitude, isNumeric, isNumeric, isTime, isTime, newName, setOuterDimensionNameSet`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### DefaultView

    public DefaultView(Netcdf netcdf,
                       QuantityDB quantityDB)

  Constructs from a netCDF dataset and a quantity database.

Parameters:
  `netcdf` - The netCDF dataset.
  `quantityDB` - The quantity database to use to map netCDF variables to VisAD Quantity-s.

### DefaultView

    public DefaultView(Netcdf netcdf,
                       QuantityDB quantityDB,
                       boolean charToText)

  Constructs from a netCDF dataset and a quantity database.

Parameters:
  `netcdf` - The netCDF dataset.
  `quantityDB` - The quantity database to use to map netCDF variables to VisAD Quantity-s.
  `charToText` - Specifies whether the View should map char variables to VisAD Text objects

Method Detail

### isIgnorable

    protected boolean isIgnorable(Variable var)

  Indicates if a given variable should be ignored during iteration.

  This implementation returns the value of `View.isCoordinateVariable(Variable)`.

  Specified by:
    `isIgnorable` in class `View`
  Returns:
    `true` if and only if the variable should be ignored.

### getDomain

    protected View.Domain getDomain(Variable var)
                             throws TypeException,
                                    IOException

  Returns the domain of a netCDF variable.

  Specified by:
    `getDomain` in class `View`
  Parameters:
    `var` - A netCDF variable.
  Returns:
    The domain of the given variable.
  Throws:
    `IllegalArgumentException` - if the rank of the variable is zero.
    `TypeException` - if a `RealType` needed to be created but couldn't.
    `IOException` - if a netCDF read-error occurs.

### getDomainSet

    protected SampledSet getDomainSet(Dimension[] dims)
                               throws IOException,
                                      VisADException

  Returns the VisAD domain set corresponding to an array of netCDF dimension in netCDF order (outermost dimension first).

  This implementation supports 1-dimensional coordinate variables, 1-dimensional longitude, and 2-dimensional latitude/longitude domains and assumes that each netCDF dimension is independent of all others. This implementation uses `View.getDomainSet(Dimension)`, `View.getDomainSet(Dimension)`, and `getDomainType(Dimension[])`.

  Parameters:
    `dims` - A netCDF domain. Must be in netCDF order (outer dimension first).
  Returns:
    The VisAD domain set corresponding to `dims`.
  Throws:
    `VisADException` - Couldn't create necessary VisAD object.
    `IOException` - if a netCDF read-error occurs.

### getDomainType

    protected MathType getDomainType(Dimension[] dims)
                              throws VisADException

  Returns the VisAD `MathType` corresponding to an array of netCDF dimensions. If the array has zero length, then `null` is returned.

  This implementation uses `View.getRealType(Dimension)`.

  Parameters:
    `dims` - netCDF dimensions in netCDF order (outermost dimension first).
  Returns:
    The type of the domain corresponding to `dims`. RETURN_VALUE is `null`, a `RealType`, or a `RealTupleType` if `dims.length` is 0, 1, or greater than 1, respectively.
  Throws:
    `VisADException` - Couldn't create necessary VisAD object.