Examples of FileInputStream


Examples of java.io.FileInputStream


    Properties readProps(String fileName) throws IOException
    {
        Properties props;
        FileInputStream _stream = new FileInputStream(fileName);
        props=new Properties();
        props.load(_stream);
        return props;
    }
View Full Code Here

Examples of java.io.FileInputStream

        file = new File(dir, name);
      } else {
        File parentDir = new File(dir, dirName);
        file = new File(parentDir, name);
      }
      FileInputStream fis = new FileInputStream(file);
      byte[] buf = new byte[(int) file.length()];
      for (int nb=0; nb<buf.length; ) {
        int ret = fis.read(buf, nb, buf.length-nb);
        if (ret == -1) throw new EOFException();
        nb += ret;
      }
      fis.close();

      return buf;
    } catch (FileNotFoundException exc) {
      return null;
    }
View Full Code Here

Examples of java.io.FileInputStream

      entry = this.archiveEntry() ;
      return this.container().getInputStream( entry ) ;
    }
    else
    {
      return new FileInputStream( this.getFile() ) ;
    }
  } // getInputStream()
View Full Code Here

Examples of org.pdfclown.bytes.FileInputStream

    )
  {
    try
    {
      return get(
        new FileInputStream(
          new java.io.RandomAccessFile(path,"r")
          )
        );
    }
    catch(Exception e)
View Full Code Here

Examples of pushy.io.FileInputStream

        this.client = client;
        this.popen = popen;
        this.osModule = osModule;
        this.signalModule = signalModule;
        stdoutStream =
            new FileInputStream((PushyObject)popen.__getattr__("stdout"));
        stdinStream =
            new FileOutputStream((PushyObject)popen.__getattr__("stdin"));
        if (!combineStderrStdout)
            stderrStream =
                new FileInputStream((PushyObject)popen.__getattr__("stderr"));
    }
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.