title: Constructors: get type list from argument list
body: <p>I'm currently working on a program where I will be dynamically loading classes at runtime and am building a library of functions to support it.  One of these functions is a method to easily search a given jar file for a given class name and create a new instance from the given set of initialization arguments.</p>
  
  <p>The issue is arguments. I know how to find a constructor for a class for a set of class types, however, trying to find a constructor that accepts a list of arguments is harder.  My first thought was to iterate through the arguments and call <code>getClass()</code> on each, but what about null arguments which may well be a valid thing for some constructors?</p>
  
  <p>Is there any sensible way to find the correct constructor for a given set of arguments?</p>
  
  <p>NOTE: standard Java only, this is a joint project so Java derived languages and 3rd party libraries are not available.  </p>