Package org.apache.commons.imaging.formats.png.transparencyfilters

# Class AbstractTransparencyFilter

java.lang.Object
org.apache.commons.imaging.common.BinaryFileParser
org.apache.commons.imaging.formats.png.transparencyfilters.AbstractTransparencyFilter

Direct Known Subclasses:
  `TransparencyFilterGrayscale`, `TransparencyFilterIndexedColor`, `TransparencyFilterTrueColor`

public abstract class AbstractTransparencyFilter extends BinaryFileParser

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AbstractTransparencyFilter(byte[] bytes)`
  Constructs a new instance.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `abstract int`
  `filter(int rgb, int index)`
  `byte`
  `getByte(int offset)`
  Gets the byte at the given offset.
  `int`
  `getLength()`
  Gets the length.

  ### Methods inherited from class org.apache.commons.imaging.common.BinaryFileParser

  `debugNumber, debugNumber, getByteOrder, setByteOrder`

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

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

- ## Constructor Details

  - ### AbstractTransparencyFilter

    public AbstractTransparencyFilter(byte[] bytes)
    Constructs a new instance.
    Parameters:
      `bytes` - bytes.

- ## Method Details

  - ### filter

    public abstract int filter(int rgb, int index) throws ImagingException, IOException
    Throws:
      `ImagingException`
      `IOException`

  - ### getByte

    public byte getByte(int offset)
    Gets the byte at the given offset.
    Parameters:
      `offset` - offset.
    Returns:
      a byte.

  - ### getLength

    public int getLength()
    Gets the length.
    Returns:
      the length