<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body>
<p>2 email images attached for your convenience, Don and others with
URL translation issues. Hopefully I won't exceed email
restrictions.<br>
</p>
<p>We discussed 3 things:</p>
<p>1. Python JSON Schema generation and validation</p>
<p>Sample script in X3DJSONLD/src/main/python (open project in
PyCharm).</p>
<p>Run file generateSchemas.py in PyCharm</p>
<p>Reads X3DUOM specifications from X3DJSONLD/src/specifications<br>
</p>
<p>Produces X3DJSONLD/src/main/schema files<br>
</p>
<p>Which are copied to x3dschema (below).<br>
</p>
<p>X3DJSONLD/src/main/python/validator.py is a python script to
validate X3D JSON in python, which depends on python generated
from JSON schema.<br>
</p>
<p>2. JSON schema validation in Java and JavaScript is done in the
x3dschema project</p>
<p>Original launch bash script is validate.sh (validates JSON in X3D
resources examples found under
/c/x3d-code/.../x3d/content/examples using javaScript and Java)</p>
<p> downloads jar files to $HOME/.m2/repository<br>
</p>
<p>New ant script is build.xml which compiles Java files and
validates JSON in x3d resources examples with Everit 1.12.3.
Compatible with draft07 of json-schema</p>
<p>All schema validation is done with draft07 of json-schema</p>
<p>3. JSON loader for X3DJSAIL</p>
<p>Attached here, and in other emails. JsonLoaderTest.java should
be placed in
./x3d-code/www_web3d_org/x3d/stylesheets/java/tests/org/web3d/x3d/tests/JsonLoaderTest.java
on sourceforge</p>
<p>There are lots of error messages that need to be resolved before
X3DJSAIL will be "good to go" for JSON Loading. These seem to
center around X3DLoadDOM.java from X3DJSAIL, but could be in
output from X3DJSAIL</p>
<p>Run the NetBeans project from x3d/stylesheets/java click down
through 2 "tests" folders above to where you placed the attached
Java file and run JsonLoaderTest.java</p>
<p>Final files:<br>
</p>
<p>./x3d-code/www.web3d.org/x3d/stylesheets/java/examples/JsonLoaderTest.json<br>
./x3d-code/www.web3d.org/x3d/stylesheets/java/examples/JsonLoaderTest.x3d</p>
<p>Intermediate files:</p>
<p>./x3d-code/www.web3d.org/x3d/stylesheets/java/examples/JsonLoaderTestPrettyPrint.intermediate.x3d</p>
<p>(prior to X3DLoaderDOM.java processing)<br>
</p>
<p>./x3d-code/www.web3d.org/x3d/stylesheets/java/examples/LoadedJsonConversion.xml</p>
<p>Somewhat useful tools for comparing output, but there are online
tools as well:<br>
</p>
<p>X3DJSONLD/src/main/node/xmldiff.js<br>
X3DJSONLD/src/main/node/jsondiff.js</p>
<p><br>
</p>
<p>==========================</p>
<p>References:</p>
<p><a class="moz-txt-link-freetext" href="https://github.com/coderextreme/X3DJSONLD">https://github.com/coderextreme/X3DJSONLD</a></p>
<p><a class="moz-txt-link-freetext" href="https://github.com/coderextreme/x3dschema">https://github.com/coderextreme/x3dschema</a></p>
<p><a class="moz-txt-link-freetext" href="https://sourceforge.net/p/x3d/code/HEAD/tree/">https://sourceforge.net/p/x3d/code/HEAD/tree/</a> (for X3DJSAIL, see
X3DJSAIL web page
<a class="moz-txt-link-freetext" href="https://www.web3d.org/specifications/java/X3DJSAIL.html">https://www.web3d.org/specifications/java/X3DJSAIL.html</a>)<br>
</p>
<p>JSON examples:
<a class="moz-txt-link-freetext" href="https://www.web3d.org/x3d/content/examples/X3dExampleArchivesJsonScenes.zip">https://www.web3d.org/x3d/content/examples/X3dExampleArchivesJsonScenes.zip</a></p>
<p><img src="cid:part1.4E77912E.95C38F4E@gmail.com" alt=""></p>
<p><img src="cid:part2.C4F27DC5.88D7A050@gmail.com" alt=""></p>
<p><br>
</p>
</body>
</html>