Java adapters don't have facility to call super methods

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P2
    • 8
    • Affects Version/s: 8
    • Component/s: core-libs
    • None
    • b106
    • generic
    • generic
    • Verified

      Currently, it's not possible to do an equivalent of "super.foo()" from the body of a Java class adapter. E.g. in this example where we want a filter writer that capitalizes its output:

      var cap = new java.io.FilterWriter(w) {
          write: function(s, off, len) {
              cap.super$write(capitalize(s), off, len)
          }
      }

      function capitalize(s) { ... } // capitalizes a string

      The basic idea is to add methods prefixed with "super$" for every non-abstract overridable method from the adapter's superclass.

            Assignee:
            Attila Szegedi
            Reporter:
            Attila Szegedi
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: