The glanceclient.openstack.common.importutils Module

Import related utilities and helper functions.

glanceclient.openstack.common.importutils.import_class(import_str)

Returns a class from a string including module and class

glanceclient.openstack.common.importutils.import_module(import_str)

Import a module.

glanceclient.openstack.common.importutils.import_object(import_str, *args, **kwargs)

Import a class and return an instance of it.

glanceclient.openstack.common.importutils.import_object_ns(name_space, import_str, *args, **kwargs)

Import a class and return an instance of it, first by trying to find the class in a default namespace, then failing back to a full path if not found in the default namespace.

glanceclient.openstack.common.importutils.try_import(import_str, default=None)

Try to import a module and if it fails return default.

This Page