Class compress


  • public final class compress
    extends java.lang.Object
    A command line utility that (de)compresses files using a compression method supported by CompressorFactory.

    To use this from a command line, use a command like the following:

    java -cp strange-eons.jar compress [arguments...]
    Author:
    Chris Jennings
    • Field Summary

      Fields 
      Modifier and Type Field Description
      CompressorFactory a
      Value of --a (algorithm) command line option.
      boolean d
      Value of --d (decompress flag) command line option.
      int m
      Value of --m (compression level) command line option.
    • Constructor Summary

      Constructors 
      Constructor Description
      compress()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void main​(java.lang.String[] args)
      A simple command-line compression utility.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • m

        public int m
        Value of --m (compression level) command line option.
      • d

        public boolean d
        Value of --d (decompress flag) command line option.
    • Constructor Detail

      • compress

        public compress()
    • Method Detail

      • main

        public static void main​(java.lang.String[] args)
        A simple command-line compression utility. Usage:
         compress [--a A] [--m 0-9] [--d] infile outfile
         Where:
           --a is the compression algorithm
             (A is one of deflate, gzip, bzip2, lzma; default: bzip2)
           --m is the compression level, 0-9; default: 9
           --d decompresses infile instead of compressing it
         
        Parameters:
        args -