def _line_by_type(self, line, header, hgroups, htypes, out, want_type,
                      collapse_quals_fn = None):
        """Parse out key value pairs for line information based on a group of values.
        """
        for index, htype in ((i, t) for i, t in enumerate(htypes) if t == want_type):
            col = hgroups[index][0]
            key = header[col]#self._clean_header(header[col])
            if collapse_quals_fn:
                val = collapse_quals_fn(line, header, hgroups[index])
            else:
                val = line[col]
            out[key].add(val)
        return out
def _line_by_type ( self , line , header , hgroups , htypes , out , want_type , collapse_quals_fn = None ) : for index , htype in ( ( i , t ) for i , t in enumerate ( htypes ) if t == want_type ) : col = hgroups [ index ] [ 0 ] key = header [ col ] if collapse_quals_fn : val = collapse_quals_fn ( line , header , hgroups [ index ] ) else : val = line [ col ] out [ key ] . add ( val ) return out
Parse out key value pairs for line information based on a group of values.