Ejemplo n.º 1
0
  public static void main(String args[])
      throws Exception, IOException, InstantiationException, IllegalAccessException {
    String fileIn = "z:/nowrad/BREF_951207_2230";

    // String fileIn = "c:/data/image/Nids/n0r_20041013_1852";
    ucar.nc2.NetcdfFile.registerIOProvider(ucar.nc2.iosp.nowrad.NOWRadiosp.class);

    ucar.nc2.NetcdfFile ncf = ucar.nc2.NetcdfFile.open(fileIn);

    // List alist = ncf.getGlobalAttributes();
    ucar.nc2.Variable v = ncf.findVariable("BaseReflectivity");
    int[] origin = {0, 0};
    int[] shape = {300, 36};
    ArrayByte data = (ArrayByte) v.read(origin, shape);

    ncf.close();
  }
Ejemplo n.º 2
0
 @Override
 public void setName(String newName) {
   this.orgName = shortName;
   super.setName(newName);
 }
Ejemplo n.º 3
0
 /**
  * Set the Variable to wrap. Used by NcML explicit mode.
  *
  * @param orgVar original Variable, must not be a Structure
  */
 public void setOriginalVariable(ucar.nc2.Variable orgVar) {
   if (orgVar instanceof Structure)
     throw new IllegalArgumentException(
         "VariableDS must not wrap a Structure; name=" + orgVar.getName());
   this.orgVar = orgVar;
 }