Examples of LuposObjectInputStream


Examples of lupos.io.LuposObjectInputStream

      if (this.out != null) {
        this.out.close();
        this.out = null;
      }
      for (int i = 0; i <= this.numberFiles; i++) {
        final LuposObjectInputStream in = new LuposObjectInputStreamWithoutReadingHeader<E>(
            new BufferedInputStream(new FileInputStream(this.filename
                + this.numberFiles)), (Class<E>) arg0.getClass());
        try {
          while (true) {
            final E e = (E) in.readLuposObject();
            if (e == null) {
              in.close();
              break;
            }
            if (e.equals(arg0)) {
              in.close();
              return true;
            }
          }
        } catch (final EOFException e) {
          in.close();
        }
      }
    } catch (final FileNotFoundException e) {
      System.err.println(e);
      e.printStackTrace();
View Full Code Here

Examples of lupos.io.LuposObjectInputStream

      if (this.out != null) {
        this.out.close();
        this.out = null;
      }
      for (int i = 0; i <= this.numberFiles; i++) {
        final LuposObjectInputStream in = new LuposObjectInputStreamWithoutReadingHeader<E>(
            new BufferedInputStream(new FileInputStream(this.filename
                + i)), this.classOfElements);
        try {
          while (true) {
            final E e = (E) in.readLuposObject();
            if (e == null) {
              in.close();
              if (hs.size() == 0) {
                return true;
              } else {
                break;
              }
            }
            hs.remove(e);
          }
        } catch (final EOFException e) {
          in.close();
          if (hs.size() == 0) {
            return true;
          }
        }
      }
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.