TrueZIP Kernel 7.0-rc2

de.schlichtherle.truezip.fs
Class FsStatistics.CountingReadOnlyFile

java.lang.Object
  extended by de.schlichtherle.truezip.rof.AbstractReadOnlyFile
      extended by de.schlichtherle.truezip.rof.DecoratingReadOnlyFile
          extended by de.schlichtherle.truezip.fs.FsStatistics.CountingReadOnlyFile
All Implemented Interfaces:
ReadOnlyFile, Closeable
Enclosing class:
FsStatistics

@NotThreadSafe
private final class FsStatistics.CountingReadOnlyFile
extends DecoratingReadOnlyFile


Field Summary
 
Fields inherited from class de.schlichtherle.truezip.rof.DecoratingReadOnlyFile
delegate
 
Constructor Summary
FsStatistics.CountingReadOnlyFile(ReadOnlyFile rof)
           
 
Method Summary
 int read()
          Reads and returns the next byte or -1 if the end of the file has been reached.
 int read(byte[] b, int off, int len)
          Reads up to len bytes of data from this read only file into the given array.
 
Methods inherited from class de.schlichtherle.truezip.rof.DecoratingReadOnlyFile
close, getFilePointer, length, seek, toString
 
Methods inherited from class de.schlichtherle.truezip.rof.AbstractReadOnlyFile
read, readFully, readFully
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FsStatistics.CountingReadOnlyFile

FsStatistics.CountingReadOnlyFile(ReadOnlyFile rof)
Method Detail

read

public int read()
         throws IOException
Description copied from interface: ReadOnlyFile
Reads and returns the next byte or -1 if the end of the file has been reached.

Specified by:
read in interface ReadOnlyFile
Overrides:
read in class DecoratingReadOnlyFile
Throws:
IOException

read

public int read(byte[] b,
                int off,
                int len)
         throws IOException
Description copied from interface: ReadOnlyFile
Reads up to len bytes of data from this read only file into the given array. This method blocks until at least one byte of input is available.

Specified by:
read in interface ReadOnlyFile
Overrides:
read in class DecoratingReadOnlyFile
Parameters:
b - The buffer to fill with data.
off - The start offset of the data.
len - The maximum number of bytes to read.
Returns:
The total number of bytes read, or -1 if there is no more data because the end of the file has been reached.
Throws:
IOException - On any I/O related issue.

TrueZIP Kernel 7.0-rc2

Copyright © 2005-2011 Schlichtherle IT Services. All Rights Reserved.