Package org.apache.commons.compress.harmony.unpack200

# Class NewAttributeBands

java.lang.Object
org.apache.commons.compress.harmony.unpack200.BandSet
org.apache.commons.compress.harmony.unpack200.NewAttributeBands

public class NewAttributeBands extends BandSet
Set of bands relating to a non-predefined attribute

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `class`
  `NewAttributeBands.Call`
  `static class`
  `NewAttributeBands.Callable`
  `class`
  `NewAttributeBands.Integral`
  `class`
  `NewAttributeBands.Reference`
  Constant Pool Reference
  `class`
  `NewAttributeBands.Replication`
  A replication is an array of layout elements, with an associated count
  `class`
  `NewAttributeBands.Union`
  A Union is a type of layout element where the tag value acts as a selector for one of the union cases
  `class`
  `NewAttributeBands.UnionCase`
  A Union case

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `protected List<org.apache.commons.compress.harmony.unpack200.NewAttributeBands.AttributeLayoutElement>`
  `attributeLayoutElements`

  ### Fields inherited from class org.apache.commons.compress.harmony.unpack200.BandSet

  `header, segment`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `NewAttributeBands(Segment segment, AttributeLayout attributeLayout)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `getBackwardsCallCount()`
  `BHSDCodec`
  `getCodec(String layoutElement)`
  Returns the `BHSDCodec` that should be used for the given layout element.
  `List<Attribute>`
  `parseAttributes(InputStream in, int occurrenceCount)`
  Parse the bands relating to this AttributeLayout and return the correct class file attributes as a List of `Attribute`.
  `void`
  `read(InputStream in)`
  `void`
  `setBackwardsCalls(int[] backwardsCalls)`
  Once the attribute bands have been read the callables can be informed about the number of times each is subject to a backwards call.
  `void`
  `unpack()`

  ### Methods inherited from class org.apache.commons.compress.harmony.unpack200.BandSet

  `decodeBandInt, decodeBandInt, getReferences, getReferences, parseCPClassReferences, parseCPDescriptorReferences, parseCPDoubleReferences, parseCPFieldRefReferences, parseCPFloatReferences, parseCPInterfaceMethodRefReferences, parseCPIntReferences, parseCPLongReferences, parseCPMethodRefReferences, parseCPSignatureReferences, parseCPSignatureReferences, parseCPStringReferences, parseCPUTF8References, parseCPUTF8References, parseFlags, parseFlags, parseFlags, parseFlags, parseReferences, parseReferences, unpack`

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

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

- ## Field Details

  - ### attributeLayoutElements

    protected List<org.apache.commons.compress.harmony.unpack200.NewAttributeBands.AttributeLayoutElement> attributeLayoutElements

- ## Constructor Details

  - ### NewAttributeBands

    public NewAttributeBands(Segment segment, AttributeLayout attributeLayout) throws IOException
    Throws:
      `IOException`

- ## Method Details

  - ### getBackwardsCallCount

    public int getBackwardsCallCount()

  - ### getCodec

    public BHSDCodec getCodec(String layoutElement)
    Returns the `BHSDCodec` that should be used for the given layout element.
    Parameters:
      `layoutElement` - TODO
    Returns:
      the `BHSDCodec` that should be used for the given layout element.

  - ### parseAttributes

    public List<Attribute> parseAttributes(InputStream in, int occurrenceCount) throws IOException, Pack200Exception
    Parse the bands relating to this AttributeLayout and return the correct class file attributes as a List of `Attribute`.
    Parameters:
      `in` - parse source.
      `occurrenceCount` - TODO
    Returns:
      Class file attributes as a List of `Attribute`.
    Throws:
      `IOException` - If an I/O error occurs.
      `Pack200Exception` - TODO

  - ### read

    public void read(InputStream in) throws IOException, Pack200Exception
    Specified by:
      `read` in class `BandSet`
    Throws:
      `IOException`
      `Pack200Exception`

  - ### setBackwardsCalls

    public void setBackwardsCalls(int[] backwardsCalls) throws IOException
    Once the attribute bands have been read the callables can be informed about the number of times each is subject to a backwards call. This method is used to set this information.
    Parameters:
      `backwardsCalls` - one int for each backwards callable, which contains the number of times that callable is subject to a backwards call.
    Throws:
      `IOException` - If an I/O error occurs.

  - ### unpack

    public void unpack() throws IOException, Pack200Exception
    Specified by:
      `unpack` in class `BandSet`
    Throws:
      `IOException`
      `Pack200Exception`