def METHOD_NAME(self, attrs):
    if attrs.has_key('datahandler'):
        v = Vendor(attrs['name'], attrs['datahandler'])
    else:
        v = Vendor(attrs['name'])
    if attrs.has_key('scroll'):
        v.scroll = attrs['scroll']
    self.vendors.append(v)