code: public <T extends ICDKObject> T ofClass(Class<T> intf, Object... objects) {
  
          try {
  
              if (!intf.isInterface()) throw new IllegalArgumentException("expected interface, got " + intf.getClass());
  
              Creator<T> constructor = get(new ObjectBasedKey(intf, objects));
              return constructor.create(objects);
  
          } catch (InstantiationException e) {
              throw new IllegalArgumentException("unable to instantiate chem object: ", e);
          } catch (IllegalAccessException e) {
              throw new IllegalArgumentException("constructor is not accessible: ", e);
          } catch (InvocationTargetException e) {
              throw new IllegalArgumentException("invocation target exception: ", e);
          }
  
      }
docs: Construct an implementation using a constructor whose parameters match
  that of the provided objects.
  
  @param intf the interface to construct an instance of
  @param <T>  the type of the class
  @return an implementation of provided interface
  @throws IllegalArgumentException thrown if the implementation can not be
  constructed
  @throws IllegalArgumentException thrown if the provided class is not an
  interface