1 Reply Latest reply on Nov 4, 2004 11:42 AM by Shigeru Chiba

    Inconsistency in CtConstructor.getName

    gpothier Newbie

      Here is the definition of CtConstructor.getName() in Javassist 3.0RC1:

      /**
      * Obtains the name of this constructor.
      * It is the same as the simple name of the class declaring this
      * constructor. If this object represents a class initializer,
      * then this method returns "<clinit>".
      */
      public String getName() {
      if (methodInfo.isStaticInitializer())
      return MethodInfo.nameClinit;
      else
      return declaringClass.getName();
      }

      It claims to return the simple name of the declaring class, but it actually returns the fully qualified name.
      Is this the appropriate place for reporting bugs?
      Guillaume