rabbit.proxy
Class CacheStream

java.lang.Object
  extended by java.io.InputStream
      extended by java.io.FileInputStream
          extended by rabbit.proxy.CacheStream
All Implemented Interfaces:
java.io.Closeable

public class CacheStream
extends java.io.FileInputStream

This class reads data from a cachefile.


Constructor Summary
CacheStream(NCache cache, NCacheEntry entry, Counter counter)
          Create a new CacheStream from the given NCacheEntry
 
Method Summary
 void close()
           
 
Methods inherited from class java.io.FileInputStream
available, finalize, getChannel, getFD, read, read, read, skip
 
Methods inherited from class java.io.InputStream
mark, markSupported, reset
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CacheStream

public CacheStream(NCache cache,
                   NCacheEntry entry,
                   Counter counter)
            throws java.io.FileNotFoundException
Create a new CacheStream from the given NCacheEntry

Parameters:
entry - the NCacheEntry to read data from.
Throws:
java.io.FileNotFoundException - if the cachefile is not found.
Method Detail

close

public void close()
           throws java.io.IOException
Specified by:
close in interface java.io.Closeable
Overrides:
close in class java.io.FileInputStream
Throws:
java.io.IOException