def _create_filter(names):
    """
    Create a filter function matching names.
    """
    if names == "*":
        return lambda k: False
    names = names.split("|")
    return lambda k: k not in names