presto-main/src/main/java/io/prestosql/connector/system/jdbc/FilterUtil.java/FilterUtil/filter
class FilterUtil:    public static <T> Iterable<T> filter(Iterable<T> items, Optional<T> filter)
    {
        if (!filter.isPresent()) {
            return items;
        }
        return Iterables.filter(items, Predicates.equalTo(filter.get()));
    }