TrueZIP Kernel 7.0-rc2

de.schlichtherle.truezip.fs.archive
Class FsMultiplexedArchiveOutputShop.TempEntryOutputStream

java.lang.Object
  extended by java.io.OutputStream
      extended by de.schlichtherle.truezip.io.DecoratingOutputStream
          extended by de.schlichtherle.truezip.fs.archive.FsMultiplexedArchiveOutputShop.TempEntryOutputStream
All Implemented Interfaces:
Closeable, Flushable
Enclosing class:
FsMultiplexedArchiveOutputShop<AE extends FsArchiveEntry>

private class FsMultiplexedArchiveOutputShop.TempEntryOutputStream
extends DecoratingOutputStream

This entry output stream writes the archive entry to a temporary file. When the stream is closed, the temporary file is then copied to the output archive and finally deleted unless the output output archive is still busy.


Field Summary
private  boolean closed
           
private  InputSocket<?> input
           
private  AE local
           
private  OutputSocket<? extends AE> output
           
private  Entry peer
           
private  IOPool.Entry<?> temp
           
 
Fields inherited from class de.schlichtherle.truezip.io.DecoratingOutputStream
delegate
 
Constructor Summary
FsMultiplexedArchiveOutputShop.TempEntryOutputStream(OutputSocket<? extends AE> output, IOPool.Entry<?> temp)
           
 
Method Summary
 void close()
           
 AE getTarget()
           
private  boolean store(boolean discard)
           
 
Methods inherited from class de.schlichtherle.truezip.io.DecoratingOutputStream
flush, toString, write, write, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

temp

private final IOPool.Entry<?> temp

output

private final OutputSocket<? extends AE extends FsArchiveEntry> output

local

private final AE extends FsArchiveEntry local

peer

private final Entry peer

input

private final InputSocket<?> input

closed

private boolean closed
Constructor Detail

FsMultiplexedArchiveOutputShop.TempEntryOutputStream

FsMultiplexedArchiveOutputShop.TempEntryOutputStream(@NonNull
                                                     OutputSocket<? extends AE> output,
                                                     @NonNull
                                                     IOPool.Entry<?> temp)
                                               throws IOException
Throws:
IOException
Method Detail

getTarget

public AE getTarget()

close

public void close()
           throws IOException
Specified by:
close in interface Closeable
Overrides:
close in class DecoratingOutputStream
Throws:
IOException

store

private boolean store(boolean discard)
               throws IOException
Throws:
IOException

TrueZIP Kernel 7.0-rc2

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