

def import_clazz(fqn):
    'Returns a class specified by the fully qualified name. For example:\n       foo.baz.MyClass'
    clazz = None
    index = fqn.rfind('.')
    if (index != (- 1)):
        clazz_name = fqn[(index + 1):]
        mod = __import__(fqn[:clazz], globals(), locals(), [clazz_name])
        clazz = getattr(mod, clazz_name)
    return clazz

dataset/ETHPy150Open bartdag/recodoc2/recodoc2/apps/docutil/commands_util.py import_clazz/VarMisuse@56/99 `index`->`clazz`