8 Replies Latest reply on Jan 11, 2008 4:37 PM by Ales Justin


    Ales Justin Master

      OK, this look pretty straight forward, except that I don't like where the code resides. :-)

      Doing this in ArrayInfoImpl.getType is where this is needed:

       if (annotatedElement == null)
       annotatedElement = Class.forName(name, true, componentType.getType().getClassLoader());
       catch (Throwable t)
       throw new UndeclaredThrowableException(t);
       return (Class<? extends Object>)annotatedElement;

      But using Class.forName outside TypeInfoFactory (TIF) doesn't seem right.
      Should I introduce new method on TIF?
      If so, how to name it, params, ...

      Perhaps this?
      TypeInfo getTypeInfo(String name, boolean initialize, ClassLoader cl) throws ClassNotFoundException;