Examples of NetcdfFile


Examples of ucar.nc2.NetcdfFile

    super(name);
  }

  public void utestNestedTable() throws IOException, InvalidRangeException {
    String filename = TestAll.cdmLocalTestDataDir + "dataset/nestedTable.bufr";
    NetcdfFile ncfile = ucar.nc2.dataset.NetcdfDataset.openFile(filename, null);
    Structure outer = (Structure) ncfile.findVariable(BufrIosp.obsRecord);
    StructureData data = outer.readStructure(0);
    //NCdumpW.printStructureData( new PrintWriter(System.out), data);

    assert data.getScalarShort("Latitude") == 32767;

    ArrayStructure as = data.getArrayStructure("struct1");
    assert as != null;
    assert as.getScalarShort(0, as.findMember("Wind_speed")) == 61;

    ncfile.close();
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.