Package htsjdk.samtools.filter

# Class InvertFilter

java.lang.Object
htsjdk.samtools.filter.InvertFilter

All Implemented Interfaces:
  `SamRecordFilter`

public class InvertFilter extends Object implements SamRecordFilter
Wraps an existing filter and inverts it. If the wrapped filter would have filtered something out this will keep it and vice versa.

## Constructor Summary

Constructors
Constructor
Description
`InvertFilter(SamRecordFilter filter)`
Constructor

## Method Summary

Modifier and Type
Method
Description
`boolean`
`filterOut(SAMRecord record)`
Determines whether a SAMRecord matches this filter
`boolean`
`filterOut(SAMRecord first, SAMRecord second)`
Determines whether a pair of SAMRecord matches this filter

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

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

## Constructor Details

### InvertFilter

public InvertFilter(SamRecordFilter filter)
Constructor

Parameters:
  `filter` - the filter that this Filter inverts

## Method Details

### filterOut

public boolean filterOut(SAMRecord record)
Determines whether a SAMRecord matches this filter

Specified by:
  `filterOut` in interface `SamRecordFilter`
Parameters:
  `record` - the SAMRecord to evaluate
Returns:
  inverts the result from filter

### filterOut

public boolean filterOut(SAMRecord first, SAMRecord second)
Determines whether a pair of SAMRecord matches this filter

Specified by:
  `filterOut` in interface `SamRecordFilter`
Parameters:
  `first` - the first SAMRecord to evaluate
  `second` - the second SAMRecord to evaluate
Returns:
  inverts the result from filter