private void init(SharedFile sf, int size) throws IOException {
   this.sf = sf;
   this.in = sf.open();
   this.start = 0;
   this.datalen = in.length(); // XXX - file can't grow
   this.bufsize = size;
   buf = new byte[size];
 }
 /** Used internally by the <code>newStream</code> method. */
 private SharedFileInputStream(SharedFile sf, long start, long len, int bufsize) {
   super(null);
   this.master = false;
   this.sf = sf;
   this.in = sf.open();
   this.start = start;
   this.bufpos = start;
   this.datalen = len;
   this.bufsize = bufsize;
   buf = new byte[bufsize];
 }