src/dirbs/listgen/generator.py
def _is_valid_and_check_digit_queries(self):
        """Property generating a tuple of queries to generate is_valid and imei_norm_with_check_digit values."""
        if not self._output_invalid_imeis or self._generate_check_digit:
            is_valid_query = sql.SQL('SELECT is_valid_imei_norm(imei_norm) AS is_valid')
        else:
            is_valid_query = sql.SQL('SELECT NULL::BOOLEAN AS is_valid')

        if self._generate_check_digit:
            imei_norm_with_check_digit_query = sql.SQL("""SELECT CASE
                                                                 WHEN is_valid = TRUE
                                                                 THEN luhn_check_digit_append(imei_norm)
                                                                 ELSE imei_norm
                                                                 END AS imei_norm_with_check_digit""")
        else:
            imei_norm_with_check_digit_query = sql.SQL('SELECT NULL::TEXT AS imei_norm_with_check_digit')

        return is_valid_query, imei_norm_with_check_digit_query
Property generating a tuple of queries to generate is_valid and imei_norm_with_check_digit values.
Property generating a tuple of queries to generate is_valid and imei_norm_with_check_digit values.
Property generating a tuple of queries to generate is_valid and imei_norm_with_check_digit values .
def _is_valid_and_check_digit_queries(self):
        if not self._output_invalid_imeis or self._generate_check_digit:
            is_valid_query = sql.SQL('SELECT is_valid_imei_norm(imei_norm) AS is_valid')
        else:
            is_valid_query = sql.SQL('SELECT NULL::BOOLEAN AS is_valid')
        if self._generate_check_digit:
            imei_norm_with_check_digit_query = sql.SQL("""SELECT CASE
                                                                 WHEN is_valid = TRUE
                                                                 THEN luhn_check_digit_append(imei_norm)
                                                                 ELSE imei_norm
                                                                 END AS imei_norm_with_check_digit""")
        else:
            imei_norm_with_check_digit_query = sql.SQL('SELECT NULL::TEXT AS imei_norm_with_check_digit')
        return is_valid_query, imei_norm_with_check_digit_query
def _is_valid_and_check_digit_queries ( self ) : if not self . _output_invalid_imeis or self . _generate_check_digit : is_valid_query = sql . SQL ( 'SELECT is_valid_imei_norm(imei_norm) AS is_valid' ) else : is_valid_query = sql . SQL ( 'SELECT NULL::BOOLEAN AS is_valid' ) if self . _generate_check_digit : imei_norm_with_check_digit_query = sql . SQL ( """SELECT CASE
                                                                 WHEN is_valid = TRUE
                                                                 THEN luhn_check_digit_append(imei_norm)
                                                                 ELSE imei_norm
                                                                 END AS imei_norm_with_check_digit""" ) else : imei_norm_with_check_digit_query = sql . SQL ( 'SELECT NULL::TEXT AS imei_norm_with_check_digit' ) return is_valid_query , imei_norm_with_check_digit_query
Property generating a tuple of queries to generate is_valid and imei_norm_with_check_digit values.
Property generating a tuple of queries to generate is_valid and imei_norm_with_check_digit values .
"""Property generating a tuple of queries to generate is_valid and imei_norm_with_check_digit values."""
self