Returns the elements of self
that satisfy is
.
SDK
- Xcode 7.1+
Framework
- Swift Standard Library
Declaration
func filter(_ isIncluded: @escaping (Base.Element) -> Bool) -> Lazy Filter Sequence<Base>
Discussion
Note
The elements of the result are computed on-demand, as the result is used. No buffering storage is allocated and each traversal step invokes predicate
on one or more underlying elements.