[x3d-public] 6 versions of X3DJSONLD.js. Develop a formal package?

John Carlson yottzumm at gmail.com
Thu May 24 17:04:49 PDT 2018


I currently have at least 6 versions of X3DJSONLD.js (X3D JSON -> DOM aka JSONParser.js aka X3D JSON Loader): X3DJSONLD’s for conversions, X3DOM’s, X_ITE’s, X3DJSAIL’s Java and JavaScript versions, and an alpha C++ version.  I am considering separating X3DJSONLD.js into a separate package (probably called X3dJson2Dom) that the others will rely on, and have official releases, etc.  I need to know what is expected in this package.  Here are likely candidates:

1. X3D JSON -> DOM translation (current, stays)
2. DOM Serialization to XML (current, may leave)
3. X3D JSON document validation (half present—currently relies on JQuery or http client or node to load Schemas—there are no current plans to bring to X3DOM or X_ITE, unless there is demand.  If there’s no demand, I currently plan to excise this function from X3DJSONLD.js, and move loadX3DJS() into loaderJQuery.js and convertJSON.js in X3DJSONLD…wow!).  The main conversion utility will be replaced with loadJsonIntoXml (probably will add a DOM function as well, and will move the Xml version out if DOM serialization gets moved out—I don’t really want to move DOM serialization out).
4. Proto Expansion of X3D JSON for X3DOM (comes before translation to DOM)
5. Script Preprocessor of X3D JSON for X3DOM (does not change X3D JSON or DOM, pure JS)
6. Inline URL loading (commented out—uses loadURLs, so loadURLs is currently unused, candidate for removal)
7. C++ version
8. Java version
9. DOM -> X3D JSON translation (is it possible to write a single set of functions to translate both ways???)
10. Browser functions

What would you like to see in this package, and would you accept maintenance separate from X3DOM, X_ITE, X3DJSAIL, and X3DJSONLD and other browsers for the C++ version?   What is currently in X3DJSONLD’s X3DJSONLD.js that is currently unacceptable?

https://github.com/coderextreme/X3DJSONLD/blob/master/src/main/node/X3DJSONLD.js

Also, if you have experience creating an npm package and uploading it to npm sites, creating releases of software, CDN, testing X3DJSONLD.js, etc., I may want to call on you.

Jeff, can you look into creating this new repository, X3dJson2Dom, from the existing X3DJSONLD repository, without the supporting files? I think the essentials are X3DJSONLD.js, package.json, X3DJSONLD.java and the src/main/cplusplus folder.  Maybe create top level folders of src/js, src/java, src/cplusplus, then construct a build script (an npm script is okay) for Java (compile and create a jar on popular platforms).

Thanks,

John

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20180524/0b187743/attachment.html>


More information about the x3d-public mailing list