Class FilterNode<R>

java.lang.Object
org.apache.sis.internal.filter.Node
org.apache.sis.filter.FilterNode<R>
Type Parameters:
R - the type of resources (e.g. Feature) used as inputs.
All Implemented Interfaces:
Serializable, Predicate<R>, Filter<R>
Direct Known Subclasses:
BinaryGeometryFilter, ComparisonFilter.Between, IdentifierFilter, LikeFilter, LogicalFilter, LogicalFilter.Not

abstract class FilterNode<R> extends Node implements Filter<R>
Base class of some (not all) nodes that are filters. This base class overrides Predicate methods for building other Filter objects instead of default Java implementations that Apache SIS cannot recognize.

Note: this class duplicates the method definition in Optimization.OnFilter. This duplication exists because not all filter implementations extends this class, and not all implementations implement the Optimization.OnFilter interface.

Since:
1.1
Version:
1.1
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      For cross-version compatibility.
      See Also:
  • Constructor Details

    • FilterNode

      FilterNode()
      Creates a new node.
  • Method Details

    • and

      public final Predicate<R> and(Predicate<? super R> other)
      Returns the AND logical operation between this filter and the given predicate. This method duplicates the Optimization.OnFilter.and(Predicate) method, but is defined because not all subclasses implement the Optimization inner interface.
      Specified by:
      and in interface Predicate<R>
    • or

      public final Predicate<R> or(Predicate<? super R> other)
      Returns the OR logical operation between this filter and the given predicate. This method duplicates the Optimization.OnFilter.or(Predicate) method, but is defined because not all subclasses implement the Optimization inner interface.
      Specified by:
      or in interface Predicate<R>
    • negate

      public final Predicate<R> negate()
      Returns the logical negation of this filter.
      Specified by:
      negate in interface Predicate<R>