Instance Method

tryFilter(_:)

Republishes all elements that match a provided error-throwing closure.

Declaration

func tryFilter(_ isIncluded: @escaping ((A.Output, B.Output, C.Output, D.Output)) throws -> Bool) -> Publishers.TryFilter<Publishers.Zip4<A, B, C, D>>

Parameters

isIncluded

A closure that takes one element and returns a Boolean value indicating whether to republish the element.

Return Value

A publisher that republishes all elements that satisfy the closure.

Discussion

If the isIncluded closure throws an error, the publisher fails with that error.