@classmethod
def _get_fieldnames_to_extract(cls):
    """
        Return a list of fieldname to extract - which means dumping
        PID fields.
        """
    fieldnames = cls._get_fieldnames_to_serialize()
    if hasattr(cls, 'pid_fields'):
        for fname in cls.pid_fields:
            if fname in fieldnames:
                fieldnames.remove(fname)
    return fieldnames
