public List <Project> Filter(FilterLambda lambda) { List <Project> res = new List <Project>(); foreach (var item in _projects) { if (lambda(item)) { res.Add(item); } } return(res); }
public CircularDoublyLinkedList <T> Filter(FilterLambda predicate) { CircularDoublyLinkedList <T> newList = new CircularDoublyLinkedList <T>(); ForEach(node => { if (predicate(node)) { newList.Append(node.data); } }); return(newList); }