Package ucar.unidata.io

Examples of ucar.unidata.io.RandomAccessFile.readInt()


    // first try to read the header id, check the endianness
    while (true) {
      f.seek(0);
      f.order(order);
      id = f.readInt();
      idlen = f.readInt();
      if (id == TAG_ID && idlen == 0) {
        // this is a v5d file
        FileFormat = 0;
        break;
      }
View Full Code Here


    while (!end_of_header) {
      int tag, length;
      int i, time, nl, lev;

      tag = f.readInt();
      length = f.readInt();

      switch (tag) {
        case TAG_VERSION:
          V5Dassert(length == 10);
View Full Code Here

    while (!end_of_header) {
      int tag, length;
      int i, time, nl, lev;

      tag = f.readInt();
      length = f.readInt();

      switch (tag) {
        case TAG_VERSION:
          V5Dassert(length == 10);
          byte[] b = new byte[10];
View Full Code Here

              FileVersion + " file, you should upgrade Vis5D.");
          }
          break;
        case TAG_NUMTIMES:
          V5Dassert(length == 4);
          NumTimes = f.readInt();
          break;
        case TAG_NUMVARS:
          V5Dassert(length == 4);
          NumVars = f.readInt();
          break;
View Full Code Here

            raf.skipBytes(-8);
          }
        }

        try {
          numCompBytes = raf.readInt();
          if (numCompBytes == -1) {
            System.out.println("\n--done: numCompBytes=-1 ");
            break;
          }
        } catch (EOFException ee) {
View Full Code Here

          V5Dassert(length == 4);
          NumTimes = f.readInt();
          break;
        case TAG_NUMVARS:
          V5Dassert(length == 4);
          NumVars = f.readInt();
          break;
        case TAG_VARNAME:
          // 1 int + 10 char
          V5Dassert(length == 14);
          vr = f.readInt();
View Full Code Here

          NumVars = f.readInt();
          break;
        case TAG_VARNAME:
          // 1 int + 10 char
          V5Dassert(length == 14);
          vr = f.readInt();
          for (int q=0; q<10; q++) VarName[vr][q] = (char) f.readByte();
          break;
        case TAG_NR:
          // Number of rows for all variables
          V5Dassert(length == 4);
View Full Code Here

          for (int q=0; q<10; q++) VarName[vr][q] = (char) f.readByte();
          break;
        case TAG_NR:
          // Number of rows for all variables
          V5Dassert(length == 4);
          Nr = f.readInt();
          break;
        case TAG_NC:
          // Number of columns for all variables
          V5Dassert(length == 4);
          Nc = f.readInt();
View Full Code Here

          Nr = f.readInt();
          break;
        case TAG_NC:
          // Number of columns for all variables
          V5Dassert(length == 4);
          Nc = f.readInt();
          break;
        case TAG_NL:
          // Number of levels for all variables
          V5Dassert(length == 4);
          nl = f.readInt();
View Full Code Here

          Nc = f.readInt();
          break;
        case TAG_NL:
          // Number of levels for all variables
          V5Dassert(length == 4);
          nl = f.readInt();
          for (i=0; i<NumVars; i++) {
            Nl[i] = nl;
          }
          break;
        case TAG_NL_VAR:
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.