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

Erroneous information regarding array handling in "Using Java From Scripts"

    XMLWordPrintable

    Details

      Description

      The document "Using Java From Scripts" http://docs.oracle.com/javase/8/docs/technotes/guides/scripting/prog_guide/javascript.html has erroneous information regarding array handling. It states that arrays need to be explicitly converted to Java arrays when passed as parameter types, but that is not true. In 3.10 "Mapping Data Types" it says:

      "For example, arrays must be explicitly converted, ..."

      The first part of this is incorrect. Correct statement would be:

      "Arrays are automatically converted to Java array types, java.util.List, java.util.Collection, java.util.Queue and java.util.Deque type, ..."

        Attachments

          Activity

            People

            • Assignee:
              rgallard Raymond Gallardo
              Reporter:
              attila Attila Szegedi
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: