def templated_plugin_factory(identifier, template_name, **kwargs):
 ns = {u'identifier': identifier, u'template_name': template_name}
 ns.update(kwargs)
 ns.setdefault(u'name', space_case(identifier).title())
 return type(str((u'%sPlugin' % identifier)), (TemplatedPlugin,), ns)

def templated_plugin_factory ( identifier , template_name , ** kwargs ) : ns = { u'identifier' : identifier , u'template_name' : template_name } ns . update ( kwargs ) ns . setdefault ( u'name' , space_case ( identifier ) . title ( ) ) return type ( str ( ( u'%sPlugin' % identifier ) ) , ( TemplatedPlugin , ) , ns )
a factory to quickly create simple plugins .