title: calling QMetaObject::invokeMethod() with variable amount of parameters
body: <p>I´m porting FitNesse´s Slim-server at the moment and I´m kinda stuck right now.
  What I´m getting are strings like these:<br></p>
  
  <pre><code>("id_4", "call", "id", "setNumerator", "20")
  ("id_5", "call", "id", "setSomethingElse", "10", "8")
  </code></pre>
  
  <p>Where "setNumerator" and "setSomethingElse" are the names of methods that should be invoked and "20","10" and "8" are the arguments that I´m passing.<br><br>
  So my problem right now ist, I don´t know how to use <strong>one</strong> call to invokeMethod for both methods. My current workaround looks like this:</p>
  
  <pre><code>//(if instructionLength==5)
  metaObj-&gt;invokeMethod(className, methodName.toAscii().constData(), Qt::DirectConnection,
                                            Q_ARG(QVariant, instructions.at(index).at(4)))
  
  //(if instructionLength==6)
  metaObj-&gt;invokeMethod(className, methodName.toAscii().constData(), Qt::DirectConnection, Q_RETURN_ARG(QVariant, retArg),
                                            Q_ARG(QVariant, instructions.at(index).at(4)),
                                            Q_ARG(QVariant, instructions.at(index).at(5)))
  </code></pre>
  
  <p>and so on...<br><br>
  So on the one hand, it seems that every invokeMethod-call needs very specific information, which makes it hard to do it with a variable amount of arguments. On the other hand, there has to be a way so I don´t have to do the same thing two(or later: ten) times.<br><br>
  So the question is, is there another way to do it with one call?</p>