[x3d-public] X3dToJson.xlst fails in the context of toStringJSON in functiontoFileJavaScript in X3DJSAIL.

John Carlson yottzumm at gmail.com
Sun Nov 5 18:27:21 PST 2017


Here’s a zip with my patch to x3d-code/www.web3d.org/x3d/stylesheets, as it now stands.  It doesn’t work yet, and I’d like to modify the main Create stylesheet and build.xml some more

Contents:
nashorn/examples/ -- examples folder for build.xml

nashorn/node is X3DJSONLD files and can be licensed with the standard Web3D license.
nashorn/node/fieldTypes.js
nashorn/node/JavaScriptSerializer.js --  X3D JSON -> Nashorn serializer.
nashorn/node/mapToMethod.js
nashorn/node/mapToMethod2.js
nashorn/node/X3DJSONLD.js

nashorn/repeatPolyfill.js – repeat polyfill – copied from Mozilla
nashorn/jvm-npm.js – require for nashorn – from jvm-npm npm package with my modifications to fix java.util.Scanner code.

test.bat – run this to test Create stylesheet and test-nashorn targets

x3d.stylesheets.patch – patches to apply to existing code.

Ideally, we’d have the nashorn folder under a separate license mentioning jvm-npm  (Apache) and the repeat polyfill from Mozilla and X3DJSONLD

The rest I grant license to the Web3D consortium.

The main problem appears to be extra newlines added by the stylesheet process, but we need to keep the intermediate files to make sure.

I believe this is all that is needed for nashorn output from X3DJSAIL, minus some patches.

X3DJSAIL in this state does not run script code.  Only the ant target does that.

John

Sent from Mail for Windows 10

From: John Carlson
Sent: Sunday, November 5, 2017 9:03 PM
To: x3d-public at web3d.org; Don Brutzman
Subject: X3dToJson.xlst fails in the context of toStringJSON in functiontoFileJavaScript in X3DJSAIL.

Extra newlines are added for long lines.  I think it’s a stylesheet running problem.  Possible a configuration issue with HelloWorldProgram.java or HelloWorldProgramOutput.java.

I will try to create a reproducible diff.

John


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20171105/50d72098/attachment-0001.html>


More information about the x3d-public mailing list