<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _update_record(self, identifier, rtype=None, name=None, content=None):
 """Updates the specified record in a new Gandi zone 'content' should be a string or a list of strings """

        if self.protocol == 'rpc':
            return self.rpc_helper.update_record(identifier, rtype, name, content)

        data = {}
        if rtype:
            data['rrset_type'] = rtype
        if name:
            data['rrset_name'] = self._relative_name(name)
        if content:
            if isinstance(content, (list, tuple, set)):
                data['rrset_values'] = list(content)
            else:
                data['rrset_values'] = [content]
        if rtype is not None:
            # replace the records of a specific rtype
            url = '/domains/{0}/records/{1}/{2}'.format(self.domain_id,
                                                        identifier or self._relative_name(
                                                            name),
                                                        rtype)
            self._put(url, data)
        else:
            # replace all records with a matching name
            url = '/domains/{0}/records/{1}'.format(self.domain_id,
                                                    identifier or self._relative_name(name))
            self._put(url, {'items': [data]})
        LOGGER.debug('update_record: %s', True)
        return True