'Batch-version of `add()`. This is more efficient than
repeat-calling add when having many Attributes to add.
Args:
key (list): A list of Attribute names to add.
value (list): A list of values. It must match the `key`
list.  If `strattr` keyword is set, all entries *must* be
strings.
category (str, optional): The category for the Attribute.
The default `None` is the normal category used.
lockstring (str, optional): A lock string limiting access
to the attribute.
strattr (bool, optional): Make this a string-only Attribute.
This is only ever useful for optimization purposes.
accessing_obj (object, optional): An entity to check for
the `attrcreate` access-type. If not passing, this method
will be exited.
default_access (bool, optional): What access to grant if
`accessing_obj` is given but no lock of the type
`attrcreate` is defined on the Attribute in question.
Raises:
RuntimeError: If `key` and `value` lists are not of the
same lengths.'

def batch_add(self, key, value, category=None, lockstring='', strattr=False, accessing_obj=None, default_access=True):

    if (accessing_obj and (not self.obj.access(accessing_obj, self._attrcreate, default=default_access))):
        return
    (keys, values) = (make_iter(key), make_iter(value))
    if (len(keys) != len(values)):
        raise RuntimeError(('AttributeHandler.add():    key    and    value    lists    of    different    length:    %s    vs    %s' % key), value)
    category = (category.strip().lower() if (category is not None) else None)
    new_attrobjs = []
    for (ikey, keystr) in enumerate(keys):
        keystr = keystr.strip().lower()
        new_value = values[ikey]
        attr_objs = self._getcache(keystr, category)
        if attr_objs:
            attr_obj = attr_objs[0]
            if strattr:
                attr_obj.db_strvalue = new_value
                attr_obj.save(update_fields=['db_strvalue'])
            else:
                attr_obj.value = new_value
        else:
            kwargs = {'db_key': keystr, 'db_category': category, 'db_model': self._model, 'db_attrtype': self._attrtype, 'db_value': (None if strattr else to_pickle(new_value)), 'db_strvalue': (value if strattr else None)}
            new_attr = Attribute(**kwargs)
            new_attr.save()
            new_attrobjs.append(new_attr)
            self._setcache(keystr, category, new_attr)
    if new_attrobjs:
        getattr(self.obj, self._m2m_fieldname).add(*new_attrobjs)
