title: Get Nashorn JsonObject in Java
body: <p>In my JavaScript I have a JSON Object which I use as a parameter of a Java object. On the Java side I receive a <code>jdk.nashorn.internal.scripts.JO4</code> but only the <code>jdk.nashorn.internal.scripts.JO</code> class exits. How can I access this JSON Object?</p>
  <pre><code>var test = {
      &quot;id&quot;: 10,
      &quot;Hello&quot;: &quot;World&quot;,
      &quot;test&quot;: {
          &quot;Lorem&quot; : &quot;Ipsum&quot;,
          &quot;java&quot;  : true
      }
  }
  
  m.call(test);
  </code></pre>