Package ghidra.program.model.lang.protorules

# Class AndFilter

java.lang.Object
ghidra.program.model.lang.protorules.AndFilter

All Implemented Interfaces:
  `QualifierFilter`

public class AndFilter extends Object implements QualifierFilter
Logically AND multiple QualifierFilters together into a single filter. An instances contains some number of other arbitrary filters. In order for this filter to pass, all these contained filters must pass.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AndFilter(AndFilter op)`
  `AndFilter(ArrayList<QualifierFilter> qualifierList)`
  The AndFilter assumes ownership of all the filters in the ArrayList

- ## Method Summary

  Modifier and Type
  Method
  Description
  `QualifierFilter`
  `clone()`
  Make a copy of this qualifier
  `void`
  `encode(Encoder encoder)`
  Save this filter and its configuration to a stream
  `boolean`
  `filter(PrototypePieces proto, int pos)`
  Test whether the given function prototype meets this filter's criteria
  `boolean`
  `isEquivalent(QualifierFilter op)`
  Test if the given filter is configured and performs identically to this
  `void`
  `restoreXml(XmlPullParser parser)`
  Configure details of the criteria being filtered from the given stream

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

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

- ## Constructor Details

  - ### AndFilter

    public AndFilter(ArrayList<QualifierFilter> qualifierList)
    The AndFilter assumes ownership of all the filters in the ArrayList
    Parameters:
      `qualifierList` - is the list of filters pulled into this filter

  - ### AndFilter

    public AndFilter(AndFilter op)

- ## Method Details

  - ### clone

    public QualifierFilter clone()
    Description copied from interface: `QualifierFilter`
    Make a copy of this qualifier
    Specified by:
      `clone` in interface `QualifierFilter`
    Overrides:
      `clone` in class `Object`
    Returns:
      the copy

  - ### isEquivalent

    public boolean isEquivalent(QualifierFilter op)
    Description copied from interface: `QualifierFilter`
    Test if the given filter is configured and performs identically to this
    Specified by:
      `isEquivalent` in interface `QualifierFilter`
    Parameters:
      `op` - is the given filter
    Returns:
      true if the two filters are equivalent

  - ### filter

    public boolean filter(PrototypePieces proto, int pos)
    Description copied from interface: `QualifierFilter`
    Test whether the given function prototype meets this filter's criteria
    Specified by:
      `filter` in interface `QualifierFilter`
    Parameters:
      `proto` - is the high-level description of the function prototype to test
      `pos` - is the position of a specific output (pos=-1) or input (pos >=0) in context
    Returns:
      true if the prototype meets the criteria, false otherwise

  - ### encode

    public void encode(Encoder encoder) throws IOException
    Description copied from interface: `QualifierFilter`
    Save this filter and its configuration to a stream
    Specified by:
      `encode` in interface `QualifierFilter`
    Parameters:
      `encoder` - is the stream encoder
    Throws:
      `IOException` - for problems writing to the stream

  - ### restoreXml

    public void restoreXml(XmlPullParser parser) throws XmlParseException
    Description copied from interface: `QualifierFilter`
    Configure details of the criteria being filtered from the given stream
    Specified by:
      `restoreXml` in interface `QualifierFilter`
    Parameters:
      `parser` - is the given stream decoder
    Throws:
      `XmlParseException` - if there are problems with the stream