Interface PredicateFactory

Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface PredicateFactory
Deferred factory for creating a Predicate within a CamelContext.

Being a FunctionalInterface, implementations are typically supplied as lambdas or method references wherever a context-aware predicate must be constructed lazily, for example when wiring filter or choice EIP definitions during route startup. The factory receives the context so it can resolve language services or configuration values needed to build the predicate.

Since:
3.8
See Also:
  • Method Details

    • createPredicate

      Predicate createPredicate(CamelContext camelContext)
      Creates a predicate
      Parameters:
      camelContext - the camel context
      Returns:
      the created predicate.