Return fieldnames and values of either a namedtuple or GOEnrichmentRecord.

def _get_field_values(item, fldnames, rpt_fmt=None, itemid2name=None):
        """Return fieldnames and values of either a namedtuple or GOEnrichmentRecord."""
        if hasattr(item, "_fldsdefprt"): # Is a GOEnrichmentRecord
            return item.get_field_values(fldnames, rpt_fmt, itemid2name)
        if hasattr(item, "_fields"): # Is a namedtuple
            return [getattr(item, f) for f in fldnames]