Examples of bytesWritten()


Examples of org.broad.igv.tdf.BufferedByteWriter.bytesWritten()

        BufferedByteWriter buffer = new BufferedByteWriter();
        buffer.put(magicNumber);
        buffer.putInt(version);
        // Reserve space for the master index pointer and byte count.
        // The actual values will be written at the end
        indexPositionPosition = buffer.bytesWritten();
        buffer.putLong(0l);   // File position for start of index
        buffer.putInt(0);     // Size in bytes of index

        final byte[] bytes = buffer.getBytes();
        write(bytes);
View Full Code Here

Examples of org.teiid.common.buffer.FileStore.FileStoreOutputStream.bytesWritten()

     
      try {
        FileStoreOutputStream fs = this.result.getOuputStream();
      fs.close();
   
      if (fs.bytesWritten()) {
        return new BlobType(new BlobImpl(result));
      }
      return new BlobType(new SerialBlob(Arrays.copyOf(fs.getBuffer(), fs.getCount())));
    } catch (IOException e) {
      throw new TeiidProcessingException(e);
View Full Code Here

Examples of org.tmatesoft.hg.internal.WorkingDirFileWriter.bytesWritten()

        HgDataFile df = hgRepo.getRepo().getFileNode(fname);
        int fileRevIndex = df.getRevisionIndex(nid);
        // check out files based on manifest
        workingDirWriter = new WorkingDirFileWriter(hgRepo);
        workingDirWriter.processFile(df, fileRevIndex, flags);
        lastWrittenFileSize = workingDirWriter.bytesWritten();
        lastFileMode = workingDirWriter.fmode();
        lastFileModificationTime = workingDirWriter.mtime();
        return true;
      } catch (HgIOException ex) {
        failure = ex;
View Full Code Here

Examples of org.tmatesoft.hg.internal.WorkingDirFileWriter.bytesWritten()

          final WorkingDirFileWriter fw = new WorkingDirFileWriter(repo);
          fw.processFile(resolveUse);
          if (resolveUse == revB) {
            dirstateBuilder.recordMergedFromP2(file);
          } else {
            dirstateBuilder.recordMerged(file, fw.fmode(), fw.mtime(), fw.bytesWritten());
          }
        } // if resolution is to use revA, nothing to do
      } else if (resolveContent != null) {
        changedDirstate = true;
        // FIXME write content to file using transaction?
View Full Code Here

Examples of org.tmatesoft.hg.internal.WorkingDirFileWriter.bytesWritten()

        // XXX if presentState(null, fileOnlyInB), and use(InputStream) - i.e.
        // resolution is to add file with supplied content - shall I put 'Merged', MergedFromP2 or 'Added' into dirstate?
        if (revA == null && revB != null) {
          dirstateBuilder.recordMergedFromP2(file);
        } else {
          dirstateBuilder.recordMerged(file, fw.fmode(), fw.mtime(), fw.bytesWritten());
        }
      } // else no resolution was chosen, fine with that
    }

    public void use(HgFileRevision rev) {
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.