@staticmethod<EOL><INDENT>def convert_plugin_def(http_method, funcs):<DEDENT>
methods = []<EOL>if http_method not in ('<STR_LIT:GET>', '<STR_LIT>', '<STR_LIT:POST>', '<STR_LIT>'):<EOL><INDENT>logger.error(<EOL>'<STR_LIT>',<EOL>http_method,<EOL>)<EOL>return methods<EOL><DEDENT>for fname, params in six.iteritems(funcs):<EOL><INDENT>method = {<EOL>'<STR_LIT>': [{'<STR_LIT>': '<STR_LIT>'}],<EOL>'<STR_LIT>': [],<EOL>}<EOL>method['<STR_LIT>'][<NUM_LIT:0>]['<STR_LIT>'] = http_method<EOL>method['<STR_LIT>'][<NUM_LIT:0>]['<STR_LIT>'] = '<STR_LIT>' + fname<EOL>method['<STR_LIT:name>'] = fname<EOL>for pname, pdef in six.iteritems(params):<EOL><INDENT>param = {<EOL>'<STR_LIT:name>': pname,<EOL>'<STR_LIT>': "<STR_LIT>" % pdef['<STR_LIT>'],<EOL>'<STR_LIT:description>': '<STR_LIT>',<EOL>'<STR_LIT>': pdef['<STR_LIT>'],<EOL>}<EOL>method['<STR_LIT>'].append(param)<EOL><DEDENT>methods.append(method)<EOL><DEDENT>return methods<EOL>
This function parses one of the elements of the definitions dict for a
plugin and extracts the relevant information

:param http_method: HTTP method that uses (GET, POST, DELETE, ...)
:param funcs: functions related to that HTTP method