def load_class(self, classname, namespace=None):
if namespace is None and '<STR_LIT::>' in classname:<EOL><INDENT>namespace, classname = classname.split('<STR_LIT::>', <NUM_LIT:1>)<EOL>return self.load_class(classname, namespace)<EOL><DEDENT>if namespace:<EOL><INDENT>if namespace not in self._namespaces:<EOL><INDENT>raise NoRegisteredError("<STR_LIT>".format(namespace))<EOL><DEDENT>try:<EOL><INDENT>module = importlib.import_module(self._namespaces[namespace])if isinstance(self._namespaces[namespace], str) else self._namespaces[namespace]<EOL>return import_class(classname, module.__name__)<EOL><DEDENT>except (AttributeError, ImportError):<EOL><INDENT>raise ImportError("<STR_LIT>".format(classname,<EOL>namespace))<EOL><DEDENT><DEDENT>return super(LoaderNamespace, self).load_class(classname)<EOL>
Loads a class looking for it in each module registered. It's possible to load a class from
specific namespace using **namespace** parameter or using classname as "namespace:classname".

:param classname: Class name you want to load.
:type classname: str
:param namespace: Specific namespace where to look for class.
:type namespace: str
:return: Class object
:rtype: type