ucar.nc2
Class StructurePseudo

java.lang.Object
  extended by ucar.nc2.Variable
      extended by ucar.nc2.Structure
          extended by ucar.nc2.StructurePseudo
All Implemented Interfaces:
java.lang.Comparable<VariableSimpleIF>, VariableIF, VariableSimpleIF

public class StructurePseudo
extends Structure

Make a collection of variables with the same outer dimension into a fake Structure. Its fake because the variables are not stored contiguously.

  so
   var1(dim, other);
   var2(dim, other);
   var3(dim, other);
 becomes
   struct {
     var1(other);
     var2(other);
     var3(other);
   } name(dim);
 

Author:
caron

Field Summary
 
Fields inherited from class ucar.nc2.Variable
defaultSizeToCache
 
Constructor Summary
StructurePseudo(NetcdfFile ncfile, Group group, java.lang.String shortName, Dimension dim)
          Make a Structure out of all Variables with the named dimension as their outermost dimension.
StructurePseudo(NetcdfFile ncfile, Group group, java.lang.String shortName, java.util.List<Variable> vars, Dimension dim)
          Make a Structure out of named Variables, each has the same named outermost dimension.
 
Method Summary
 
Methods inherited from class ucar.nc2.Structure
addMemberVariable, calcElementSize, findVariable, getElementSize, getNameAndAttributes, getStructureIterator, getStructureIterator, getVariableNames, getVariables, isCaching, isSubset, makeStructureMembers, readStructure, readStructure, readStructure, removeMemberVariable, replaceMemberVariable, select, select, setCaching, setImmutable, setMemberVariables, setParentGroup, writeCDL
 
Methods inherited from class ucar.nc2.Variable
addAttribute, compareTo, createNewCache, equals, findAttribute, findAttributeIgnoreCase, findDimensionIndex, getAttributes, getDataType, getDescription, getDimension, getDimensions, getDimensionsAll, getDimensionsString, getName, getNameAndDimensions, getNameAndDimensions, getNameAndDimensions, getNameAndDimensions, getNameEscaped, getParentGroup, getParentStructure, getRanges, getRank, getShape, getShapeAsSection, getShortName, getSize, getSizeToCache, getSPobject, getUnitsString, hasCachedData, hashCode, invalidateCache, isCoordinateVariable, isImmutable, isMemberOfStructure, isMetadata, isScalar, isUnknownLength, isUnlimited, isUnsigned, isVariableLength, lookupEnumString, read, read, read, read, read, readScalarByte, readScalarDouble, readScalarFloat, readScalarInt, readScalarLong, readScalarShort, readScalarString, remove, removeAttribute, resetDimensions, resetShape, section, section, setCachedData, setDataType, setDimension, setDimensions, setDimensions, setDimensionsAnonymous, setElementSize, setEnumTypedef, setIsScalar, setName, setParentStructure, setSizeToCache, setSPobject, slice, toString, toStringDebug
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

StructurePseudo

public StructurePseudo(NetcdfFile ncfile,
                       Group group,
                       java.lang.String shortName,
                       Dimension dim)
Make a Structure out of all Variables with the named dimension as their outermost dimension.

Parameters:
ncfile - part of this file
group - part of this group
shortName - short name of this Structure
dim - the existing dimension

StructurePseudo

public StructurePseudo(NetcdfFile ncfile,
                       Group group,
                       java.lang.String shortName,
                       java.util.List<Variable> vars,
                       Dimension dim)
Make a Structure out of named Variables, each has the same named outermost dimension.

Parameters:
ncfile - part of this file
group - part of this group
shortName - short name of this Structure
vars - limited to these variables. all must have dim as outer dimension.
dim - the existing dimension