def lookup_class(fully_qualified_name):
    """
    Given its fully qualified name, finds the desired class and imports it.
    Returns the Class object if found.
    """
    module_name, class_name = str(fully_qualified_name).rsplit(".", 1)
    module = __import__(module_name, globals(), locals(), [class_name], 0)
    Class = getattr(module, class_name)

    if not inspect.isclass(Class):
        raise TypeError(
            "%s is not of type class: %s" % (class_name, type(Class)))

    return Class
Given its fully qualified name, finds the desired class and imports it.
    Returns the Class object if found.