move filter logic to DataFilter class