Package org.apache.storm.trident.operation

# Interface Filter

All Superinterfaces:
  `EachOperation`, `Operation`, `Serializable`

All Known Implementing Classes:
  `BaseFilter`, `Debug`, `Equals`, `FilterNull`, `Negate`, `TrueFilter`, `TrueFilter`

public interface Filter extends EachOperation
Filters take in a tuple as input and decide whether or not to keep that tuple or not.

If the `isKeep()` method of a Filter returns `false` for a tuple, that tuple will be filtered out of the Stream

### Configuration If your `Filter` implementation has configuration requirements, you will typically want to extend `BaseFilter` and override the `Operation.prepare(Map, TridentOperationContext)` method to perform your custom initialization.

See Also:
  - `Stream`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `isKeep(TridentTuple tuple)`
  Determines if a tuple should be filtered out of a stream.

  ### Methods inherited from interface org.apache.storm.trident.operation.Operation

  `cleanup, prepare`

- ## Method Details

  - ### isKeep

    boolean isKeep(TridentTuple tuple)
    Determines if a tuple should be filtered out of a stream.
    Parameters:
      `tuple` - the tuple being evaluated
    Returns:
      `false` to drop the tuple, `true` to keep the tuple