jtar icon indicating copy to clipboard operation
jtar copied to clipboard

Additional handling of Files in TarEntries

Open phillipjohnson opened this issue 10 years ago • 0 comments

I was using your library today and there was some functionality that I felt would make the library a bit easier to use. Thanks for your effort in creating this utility, it doesn't seem like there is much else out there except for the bloated Apache library. The commit changes below are pretty self-explanatory. Let me know what you think.

  • When iterating over the tar stream, each Entry will get a reference to its associated File.
  • Added a utility method for easily retrieving all of the TarEntries in a given archive.
  • Updated/added unit tests accordingly.

Note that some small tweaks were required for the unit tests because the bytesRead count now must also include the bytes of the file just read.

phillipjohnson avatar May 07 '14 03:05 phillipjohnson