Returns True if the field is in the list of conditions. Returns False otherwise.

        :param dict row: The row.

        :rtype: bool
345579
def match(self, row):
        
        if row[self._field] in self._values:
            return True

        for condition in self._conditions:
            if condition.match(row):
                return True

        return False
398901
def get_value(row, field_name):
    '''
    
    '''
    result = None
    dict_row = convert_to_dict(row)
    if detect_list(field_name):
        temp = row
        for field in field_name:
            dict_temp = convert_to_dict(temp)
            temp = dict_temp.get(field, None)
        result = temp
    else:
        result = dict_row.get(field_name, None)
    return result
1206803
def __check_existing(self, row):
        
        if self.__update_keys is not None:
            key = tuple(row[key] for key in self.__update_keys)
            if key in self.__bloom:
                return True
            self.__bloom.add(key)
            return False
        return False
704248
private static boolean isPartialRow(Iterable<ExpandedPair> pairs, Iterable<ExpandedRow> rows) {
    for (ExpandedRow r : rows) {
      boolean allFound = true;
      for (ExpandedPair p : pairs) {
        boolean found = false;
        for (ExpandedPair pp : r.getPairs()) {
          if (p.equals(pp)) {
            found = true;
            break;
          }
        }
        if (!found) {
          allFound = false;
          break;
        }
      }
      if (allFound) {
        // the row 'r' contain all the pairs from 'pairs'
        return true;
      }
    }
    return false;
  }
602856
def empty_row?(row)
    is_empty = true
    row.each do |item|
      is_empty = false if item && !item.empty?
    end
    is_empty
  end
1112692
protected function isAllHeadingValuesPresentInRow(?array $row){

        if (true === empty($row)) {
            return false;
        }

        foreach($this->targettedHeadingValues as $headerValue){

            if (false === in_array(trim($headerValue), $row)) {
                //print($headerValue . ' not in ' . print_r($row,true));
                return false;
            }

        }

        return true;
    }
509809
def filter_rows_with_differences(rows):
    
    if not rows:
        # empty table
        return []
    if len(rows[0].results) == 1:
        # table with single column
        return []


    def get_index_of_column(name, cols):
        for i in range(0, len(cols)):
            if cols[i].title == name:
                return i
        return -1


    def all_equal_result(listOfResults):
        relevant_columns = set()
        for res in listOfResults:
            for relevant_column in res.columns_relevant_for_diff:
                relevant_columns.add(relevant_column)
        if len(relevant_columns) == 0:
            relevant_columns.add("status")

        status = []
        for col in relevant_columns:
            # It's necessary to search for the index of a column every time
            # because they can differ between results
            status.append(
                set(
                    res.values[get_index_of_column(col, res.columns)]
                    for res in listOfResults))

        return reduce(lambda x, y: x and (len(y) <= 1), status, True)


    rowsDiff = [row for row in rows if not all_equal_result(row.results)]

    if len(rowsDiff) == 0:
        logging.info("---> NO DIFFERENCE FOUND IN SELECTED COLUMNS")
    elif len(rowsDiff) == len(rows):
        logging.info("---> DIFFERENCES FOUND IN ALL ROWS, NO NEED TO CREATE DIFFERENCE TABLE")
        return []

    return rowsDiff
435674
def _check_list_len(row, length):
        
        if len(row) != length:
            raise Exception(
                "row length does not match expected length of " +
                str(length) + "\nrow: " + str(row))
357017
protected function evaluateCondition($row, $config) {
		if (isset($this->condition))
			return call_user_func($this->condition, $row, $config);
		return true;
	}
738415
def parse_row(self):
        
        fields = self.mapping
        for i, cell in enumerate(self.row[0:len(fields)]):
            field_name, field_type = fields[str(i)]
            parsed_cell = self.clean_cell(cell, field_type)
            self.parsed_row[field_name] = parsed_cell
1171361
def is_condition_met(self, hand, *args):
        
        indices = reduce(lambda z, y: z + y, hand)
        return all(x in HONOR_INDICES for x in indices)
642531
function _validate_row_conditions ($row = array(), $conditions = null) {
		if ( !empty($row) ) {
			if ( !empty($conditions) ) {
				$conditions = (strpos($conditions, ' OR ') !== false) ? explode(' OR ', $conditions) : array($conditions) ;
				$or = '';
				foreach( $conditions as $key => $value ) {
					if ( strpos($value, ' AND ') !== false ) {
						$value = explode(' AND ', $value);
						$and = '';
						foreach( $value as $k => $v ) {
							$and .= $this->_validate_row_condition($row, $v);
						}
						$or .= (strpos($and, '0') !== false) ? '0' : '1' ;
					} else {
						$or .= $this->_validate_row_condition($row, $value);
					}
				}
				return (strpos($or, '1') !== false) ? true : false ;
			}
			return true;
		}
		return false;
	}
262935
def filterAcceptsRow(self, row_num, parent):
        
        model = self.sourceModel()
        name = model.row(row_num).name
        r = re.search(self.pattern, name)

        if r is None:
            return False
        else:
            return True
426888
def get_row(self, row):
        ''''''

        if isinstance(self.fields, dict):
            return dict([
                (key, text_type(value).format(**row) if RE_FORMATTED.match(value) else row[value])
                for key, value in self.fields.items()
            ])
        else:
            return [text_type(field).format(**row) if RE_FORMATTED.match(field)
                    else row[field]
                    for field in self.fields]
605437
def parse_condition(self, condition):
        
        if isinstance(condition, bytes):
            sql = " where {}".format(condition)
        elif isinstance(condition, dict):
            conditions = []
            for k, v in condition.iteritems():
                if isinstance(v, unicode):
                    v = v.encode('utf-8')
                s = "{}='{}'".format(k, v) if isinstance(v, bytes) else "{}={}".format(k, v)
                conditions.append(s)
            sql = " where {}".format(', '.join(conditions))
        else:
            sql = ""
        return sql
464889
def _validate_row(row, sep=',', required_length=None):
    '''

    '''
    if not isinstance(row, list):
        row = _parse_row(row, sep)

    if required_length:
        length = len(row)
        if length != required_length:
            bot.warning('Row should have length %s (not %s)' %(required_length,
                                                               length))
            bot.warning(row) 
            row = None

    return row
309424
def hasColumn(self, column, recurse=True, flags=0):
        
        return column in self.columns(recurse=recurse, flags=flags)