def trigger_methods(instance, args):
<EOL>for name in sorted(args):<EOL><INDENT>value = args[name]<EOL>target = instance<EOL>if name.startswith('<STR_LIT>') or name.startswith('<STR_LIT>'):<EOL><INDENT>name = name.replace('<STR_LIT>', '<STR_LIT>').replace('<STR_LIT>', '<STR_LIT>')<EOL>if hasattr(instance, '<STR_LIT>'):<EOL><INDENT>target = instance._response<EOL><DEDENT><DEDENT>member = getattr(target, name, None)<EOL>isattr = name in dir(target)<EOL>iscallable = ismethod(member) and not isfunction(member)<EOL>if not iscallable and not isattr:<EOL><INDENT>raise PookInvalidArgument('<STR_LIT>'.format(name))<EOL><DEDENT>if iscallable:<EOL><INDENT>member(value)<EOL><DEDENT>else:<EOL><INDENT>setattr(target, name, value)<EOL><DEDENT><DEDENT>
Triggers specific class methods using a simple reflection
mechanism based on the given input dictionary params.

Arguments:
    instance (object): target instance to dynamically trigger methods.
    args (iterable): input arguments to trigger objects to

Returns:
    None