Uploaded image for project: 'mdsal'
  1. mdsal
  2. MDSAL-737

Eliminate the use of Java reflection from mdsal-binding-dom-codec

XMLWordPrintable

    • Icon: Epic Epic
    • Resolution: Unresolved
    • Icon: Medium Medium
    • 14.0.0
    • None
    • Binding runtime
    • None
    • No runtime reflection

      mdsal-binding-runtime-api coupled with GeneratedType should be able provide us with authoritative information about class layout we are expected to encounter at runtime.

      For historical reasons there is a ton for fiddling with java.lang.Class and its shape via BindingReflections. Gradually migrate all reliance on Reflection and instead perform inferences on GeneratedType, which really gives us the same information that is input mdsal-binding-java-api-generator.

      Whenever the class shape does not match at runtime, just throw a LinkageError, as at this point we expect BindingRuntimeContext (and more importantly BindingRuntimeTypes) to have a proper self-contained view of the classes present at runtime.

      This is a prerequisite to being able to execute Binding Spec in images in AOT environments.

            Unassigned Unassigned
            rovarga Robert Varga
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: