9.1.2.5. GeoHealthCheck.factory
9.1.2.5.1. Module Contents
9.1.2.5.1.1. Classes
Object, Function class Factory (Pattern). |
9.1.2.5.1.2. Attributes
- GeoHealthCheck.factory.LOGGER
- class GeoHealthCheck.factory.Factory
Object, Function class Factory (Pattern). Based on: http://stackoverflow.com/questions/2226330/
instantiate-a-python-class-from-a-name
Also contains introspection util functions.
- static create_obj(class_string)
- static create_class(class_string)
Returns class instance specified by a string.
- Args:
class_string: The string representing a class.
- Raises:
ValueError if module part of the class is not specified.
- static create_module(module_string)
Returns module instance specified by a string.
- Args:
module_string: The string representing a module.
- Raises:
ValueError if module can not be imported from string.
- static create_function(function_string)
- static get_class_vars(clazz, candidates=[])
Class method to get all (uppercase) class variables of a class as a dict
- static get_class_for_method(method)
- static full_class_name_for_obj(o)