Package org.apache.commons.compress.harmony.pack200

# Class PackingOptions

java.lang.Object
org.apache.commons.compress.harmony.pack200.PackingOptions

public class PackingOptions extends Object
Utility class to manage the various options available for pack200.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final String`
  `ERROR`
  `static final String`
  `KEEP`
  `static final String`
  `PASS`
  `static final long`
  `SEGMENT_LIMIT`
  `static final String`
  `STRIP`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `PackingOptions()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `addClassAttributeAction(String attributeName, String action)`
  `void`
  `addCodeAttributeAction(String attributeName, String action)`
  `void`
  `addFieldAttributeAction(String attributeName, String action)`
  `void`
  `addMethodAttributeAction(String attributeName, String action)`
  `void`
  `addPassFile(String passFileName)`
  Tell the compressor to pass the file with the given name, or if the name is a directory name all files under that directory will be passed.
  `String`
  `getDeflateHint()`
  `int`
  `getEffort()`
  `String`
  `getLogFile()`
  `String`
  `getModificationTime()`
  `long`
  `getSegmentLimit()`
  `String`
  `getUnknownAttributeAction()`
  `org.objectweb.asm.Attribute[]`
  `getUnknownAttributePrototypes()`
  `String`
  `getUnknownClassAttributeAction(String type)`
  `String`
  `getUnknownCodeAttributeAction(String type)`
  `String`
  `getUnknownFieldAttributeAction(String type)`
  `String`
  `getUnknownMethodAttributeAction(String type)`
  `boolean`
  `isGzip()`
  `boolean`
  `isKeepDeflateHint()`
  `boolean`
  `isKeepFileOrder()`
  `boolean`
  `isPassFile(String passFileName)`
  `boolean`
  `isStripDebug()`
  `boolean`
  `isVerbose()`
  `void`
  `removePassFile(String passFileName)`
  `void`
  `setDeflateHint(String deflateHint)`
  `void`
  `setEffort(int effort)`
  Sets the compression effort level (0-9, equivalent to -E command line option)
  `void`
  `setGzip(boolean gzip)`
  `void`
  `setKeepFileOrder(boolean keepFileOrder)`
  `void`
  `setLogFile(String logFile)`
  `void`
  `setModificationTime(String modificationTime)`
  `void`
  `setQuiet(boolean quiet)`
  `void`
  `setSegmentLimit(long segmentLimit)`
  Sets the segment limit (equivalent to -S command line option)
  `void`
  `setStripDebug(boolean stripDebug)`
  Sets strip debug attributes.
  `void`
  `setUnknownAttributeAction(String unknownAttributeAction)`
  Sets the compressor behavior when an unknown attribute is encountered.
  `void`
  `setVerbose(boolean verbose)`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### SEGMENT_LIMIT

    public static final long SEGMENT_LIMIT
    See Also:
      - Constant Field Values

  - ### STRIP

    public static final String STRIP
    See Also:
      - Constant Field Values

  - ### ERROR

    public static final String ERROR
    See Also:
      - Constant Field Values

  - ### PASS

    public static final String PASS
    See Also:
      - Constant Field Values

  - ### KEEP

    public static final String KEEP
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### PackingOptions

    public PackingOptions()

- ## Method Details

  - ### addClassAttributeAction

    public void addClassAttributeAction(String attributeName, String action)

  - ### addCodeAttributeAction

    public void addCodeAttributeAction(String attributeName, String action)

  - ### addFieldAttributeAction

    public void addFieldAttributeAction(String attributeName, String action)

  - ### addMethodAttributeAction

    public void addMethodAttributeAction(String attributeName, String action)

  - ### addPassFile

    public void addPassFile(String passFileName)
    Tell the compressor to pass the file with the given name, or if the name is a directory name all files under that directory will be passed.
    Parameters:
      `passFileName` - the file name

  - ### getDeflateHint

    public String getDeflateHint()

  - ### getEffort

    public int getEffort()

  - ### getLogFile

    public String getLogFile()

  - ### getModificationTime

    public String getModificationTime()

  - ### getSegmentLimit

    public long getSegmentLimit()

  - ### getUnknownAttributeAction

    public String getUnknownAttributeAction()

  - ### getUnknownAttributePrototypes

    public org.objectweb.asm.Attribute[] getUnknownAttributePrototypes()

  - ### getUnknownClassAttributeAction

    public String getUnknownClassAttributeAction(String type)

  - ### getUnknownCodeAttributeAction

    public String getUnknownCodeAttributeAction(String type)

  - ### getUnknownFieldAttributeAction

    public String getUnknownFieldAttributeAction(String type)

  - ### getUnknownMethodAttributeAction

    public String getUnknownMethodAttributeAction(String type)

  - ### isGzip

    public boolean isGzip()

  - ### isKeepDeflateHint

    public boolean isKeepDeflateHint()

  - ### isKeepFileOrder

    public boolean isKeepFileOrder()

  - ### isPassFile

    public boolean isPassFile(String passFileName)

  - ### isStripDebug

    public boolean isStripDebug()

  - ### isVerbose

    public boolean isVerbose()

  - ### removePassFile

    public void removePassFile(String passFileName)

  - ### setDeflateHint

    public void setDeflateHint(String deflateHint)

  - ### setEffort

    public void setEffort(int effort)
    Sets the compression effort level (0-9, equivalent to -E command line option)
    Parameters:
      `effort` - the compression effort level, 0-9.

  - ### setGzip

    public void setGzip(boolean gzip)

  - ### setKeepFileOrder

    public void setKeepFileOrder(boolean keepFileOrder)

  - ### setLogFile

    public void setLogFile(String logFile)

  - ### setModificationTime

    public void setModificationTime(String modificationTime)

  - ### setQuiet

    public void setQuiet(boolean quiet)

  - ### setSegmentLimit

    public void setSegmentLimit(long segmentLimit)
    Sets the segment limit (equivalent to -S command line option)
    Parameters:
      `segmentLimit` - - the limit in bytes

  - ### setStripDebug

    public void setStripDebug(boolean stripDebug)
    Sets strip debug attributes. If true, all debug attributes (i.e. LineNumberTable, SourceFile, LocalVariableTable and LocalVariableTypeTable attributes) are stripped when reading the input class files and not included in the output archive.
    Parameters:
      `stripDebug` - If true, all debug attributes.

  - ### setUnknownAttributeAction

    public void setUnknownAttributeAction(String unknownAttributeAction)
    Sets the compressor behavior when an unknown attribute is encountered.
    Parameters:
      `unknownAttributeAction` - - the action to perform

  - ### setVerbose

    public void setVerbose(boolean verbose)