def get_parameters(self):
if self.plugin_class is None:<EOL><INDENT>sig = inspect.signature(self.func)<EOL>for index, parameter in enumerate(sig.parameters.values()):<EOL><INDENT>if not parameter.kind in [parameter.POSITIONAL_ONLY, parameter.KEYWORD_ONLY, parameter.POSITIONAL_OR_KEYWORD]:<EOL><INDENT>raise RuntimeError("<STR_LIT>".format(parameter, parameter.kind))<EOL><DEDENT>yield parameter<EOL><DEDENT><DEDENT>else:<EOL><INDENT>var_keyword_seen = set()<EOL>for cls in inspect.getmro(self.plugin_class):<EOL><INDENT>if issubclass(cls, BasePlugin) and hasattr(cls, self.func.__name__):<EOL><INDENT>func = getattr(cls, self.func.__name__)<EOL>logger.debug("<STR_LIT>", func, cls)<EOL>var_keyword_found = False<EOL>sig = inspect.signature(func)<EOL>for index, parameter in enumerate(sig.parameters.values()):<EOL><INDENT>if index == <NUM_LIT:0>:<EOL><INDENT>continue<EOL><DEDENT>if parameter.kind == inspect.Parameter.VAR_KEYWORD:<EOL><INDENT>var_keyword_found = True<EOL>continue<EOL><DEDENT>if parameter.kind in [parameter.POSITIONAL_ONLY, parameter.VAR_POSITIONAL]:<EOL><INDENT>raise RuntimeError("<STR_LIT>".format(func, parameter))<EOL><DEDENT>if not parameter.name in var_keyword_seen:<EOL><INDENT>var_keyword_seen.add(parameter.name)<EOL>logger.debug("<STR_LIT>", parameter, parameter.kind)<EOL>yield parameter<EOL><DEDENT><DEDENT>if not var_keyword_found:<EOL><INDENT>break<EOL><DEDENT><DEDENT><DEDENT><DEDENT>
Returns a list of parameters