Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8361891

Add origin info to ResolvedJavaType

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P4 P4
    • tbd
    • 26
    • hotspot

      Currently there is no way to find out where a ResolvedJavaType comes from. Java's concept of classloaders as the origin of the classes it loads and unloads has no representation in JVMCI yet.

      These concepts should be added as the following methods on ResolvedJavaType:

      /**
       * Returns equivalent of `Class.getProtectionDomain().getCodeSource().getLocation()`.
       */
      URL getCodeLocation();

      /**
       * Gets an opaque handle to the ClassLoader for this type.
       */
      JavaConstant getLoader();

          /**
           * Checks whether this type is a {@link Record}.
           * @return true if this type is a {@link Record}
           */
          boolean isRecord();

            dnsimon Douglas Simon
            pwoegerer Paul Woegerer
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated: