Uploaded image for project: 'Commons Compress'
  1. Commons Compress
  2. COMPRESS-292

Add support for virtual formats

    XMLWordPrintableJSON

    Details

    • Type: New Feature
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 1.9
    • Fix Version/s: None
    • Component/s: Archivers, Compressors
    • Labels:
      None

      Description

      Hello COMPRESS team!

      Most applications know at compile-time which archive/compression format they want to use, but some don't. ArchiveStreamFactory and CompressorStreamFactory provide minimal support for runtime format processing, but more comprehensive handling would be greatly appreciated.

      I propose the addition of the ArchiveFormat and CompressionFormat interfaces, together with their factories, to implement the following:

      • Detection of archive/compression formats from contents, file name or format name
      • Conversion of archive/compressed file names, e.g. "mydir" => "mydir.tar" => "mydir.tar.gz"
      • Runtime extensibility through format auto-registration; factory method allFormats() informs which formats are available
      • Writing archive entries without knowing the archive type at compile-time
      • Automated conversion of archive entries when copying from one format to another

      A sample design is available here. If you like it, I would gladly donate it to the the project. The current license is "New BSD", which is (hopefully) compatible with yours.

      Regards,
      Arno Unkrig

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              aunkrig Arno Unkrig
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: