Implement filtering.