def call_method(self, method_name, packet, *args):
method = getattr(self, method_name, None)<EOL>if method is None:<EOL><INDENT>self.error('<STR_LIT>',<EOL>'<STR_LIT>' % method_name)<EOL>return<EOL><DEDENT>specs = inspect.getargspec(method)<EOL>func_args = specs.args<EOL>if not len(func_args) or func_args[<NUM_LIT:0>] != '<STR_LIT>':<EOL><INDENT>self.error("<STR_LIT>",<EOL>"<STR_LIT>"<EOL>"<STR_LIT>")<EOL>return<EOL><DEDENT>if hasattr(self, '<STR_LIT>'):<EOL><INDENT>method = self.exception_handler_decorator(method)<EOL><DEDENT>if len(func_args) == <NUM_LIT:2> and func_args[<NUM_LIT:1>] == '<STR_LIT>':<EOL><INDENT>return method(packet)<EOL><DEDENT>else:<EOL><INDENT>return method(*args)<EOL><DEDENT>
This function is used to implement the two behaviors on dispatched
        ``on_*()`` and ``recv_*()`` method calls.

        Those are the two behaviors:

        * If there is only one parameter on the dispatched method and
          it is named ``packet``, then pass in the packet dict as the
          sole parameter.

        * Otherwise, pass in the arguments as specified by the
          different ``recv_*()`` methods args specs, or the
          :meth:`process_event` documentation.

        This method will also consider the
        ``exception_handler_decorator``.  See Namespace documentation
        for details and examples.