#NEWLINE# @ staticmethod #NEWLINE# def _get_plugin( plugin_path ) : #NEWLINE# #INDENT# 'Given a qualified class name (eg. foo.bar.Foo), return the class\n\n        :rtype: object\n\n        ' #NEWLINE# try : #NEWLINE# #INDENT# ( package , class_name ) = plugin_path . rsplit ( '.' , 1 ) #NEWLINE# #UNINDENT# except ValueError : #NEWLINE# #INDENT# return None #NEWLINE# #UNINDENT# try : #NEWLINE# #INDENT# module_handle = importlib . import_module ( package ) #NEWLINE# class_handle = getattr ( module_handle , class_handle ) #NEWLINE# return class_handle #NEWLINE# #UNINDENT# except ImportError : #NEWLINE# #INDENT# LOGGER . exception ( 'Attempting to import %s' , plugin_path ) #NEWLINE# return None