#NEWLINE# def load_plugin( self , plugin , options ) : #NEWLINE# #INDENT# '\n        Create and return Plugin object\n        ' #NEWLINE# try : #NEWLINE# #INDENT# template = self . get_template ( 'BasePlugin' ) #NEWLINE# #UNINDENT# except : #NEWLINE# #INDENT# template = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# #UNINDENT# if options . has_key ( 'Template' ) : #NEWLINE# #INDENT# template_custom = self . get_template ( options [ 'Template' ] ) #NEWLINE# template = dict ( template , ** template_custom ) #NEWLINE# #UNINDENT# if options . has_key ( 'Action' ) : #NEWLINE# #INDENT# options [ 'Action' ] = self . get_action ( options [ 'Action' ] ) #NEWLINE# #UNINDENT# params = dict ( template , ** plugin ) #NEWLINE# return Plugin ( plugin , params )