private boolean bufferLocalFileHeader ( ) throws IOException { buffer . reset ( ) ; JarEntry jarEntry = virtualJarInputStream . getNextJarEntry ( ) ; if ( jarEntry == null ) { return false ; } currentEntry = new ProcessedEntry ( jarEntry , totalRead ) ; processedEntries . add ( currentEntry ) ; bufferInt ( ZipEntry . LOCSIG ) ; // Local file header signature bufferShort ( 10 ) ; // Extraction version bufferShort ( 0 ) ; // Flags bufferShort ( ZipEntry . STORED ) ; // Compression type bufferInt ( jarEntry . getTime ( ) ) ; // Entry time bufferInt ( 0 ) ; // CRC bufferInt ( 0 ) ; // Compressed size bufferInt ( 0 ) ; // Uncompressed size byte [ ] nameBytes = jarEntry . getName ( ) . getBytes ( "UTF8" ) ; bufferShort ( nameBytes . length ) ; // Entry name length bufferShort ( 0 ) ; // Extra length buffer ( nameBytes ) ; return true ; }
Buffer the content of the local file header for a single entry .