[x3d-public] Minutes of JavaScript/JSON meeting 28 July 2021

John Carlson yottzumm at gmail.com
Tue Jun 29 19:40:46 PDT 2021


Good news, the zjsonpatch program works! Here are the results below 
between HelloWorldProgramOutput.json (input) and JsonLoaderTest.json 
(output for JsonLoaderTest.java).


Analysis:

A translated meta statement has been added.

Many children have been removed from the LoadSensor node.

DisEntityManager children have been removed.

A couple of Group children have been removed.

Where have all the children gone? 
https://www.youtube.com/watch?v=T1tqtvxG8O4 (a bit of Pete Seeger nostalgia)

Great teamwork, Don, thanks for finding zjsonpatch!

I think we need to get into XML diff to really attack this issue.  That 
way, I can compare what I send to X3DLoaderDOM to XML produced by 
X3DJSAIL, both pretty-print XML and final.  When I look XML I send to 
X3DLoaderDOM.java, I see the missing children. Are Don and I the only 
two Java/XSLT people who can work on this? Is there an "xml diff/patch"?

Or we could create a custom X3DJSAIL scene diff, possibly based on JSON 
and XML diff programs.  Let me know.  This would probably be highly 
desirable for reducing network traffic in a distributed world.

Why is this vital?   It's a pathway for JSON to enter X3DJSAIL. There 
may be alternatives, such as adding  a X3D JSON parser (other than 
X3DJSONLD.java) to X3DJSAIL.  In some ways, this might be desirable, but 
I haven't had much success myself with reading X3D JSON into an SAI 
library. It's an easier path for me to use existing DOM import that I've 
found in X3DOM and X_ITE, plus I don't have to change a lot of X3DOM and 
X_ITE, the changes are minimal to them.

Subsequent messages will containing working file attachments.

Thanks, again!

$ jsonlint RunZPatchResults.json

[
   {
     "op": "add",
     "path": "/X3D/head/meta/23",
     "value": {
       "@name": "translated",
       "@content": "28 June 2021"
     }
   },
   {
     "op": "copy",
     "from": "/X3D/head/meta/21",
     "path": "/X3D/head/meta/24"
   },
   {
     "op": "copy",
     "from": "/X3D/head/meta/22",
     "path": "/X3D/head/meta/25"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/48/Group/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/48/Group/-children/3"
   },
   {
     "op": "remove",
     "path": 
"/X3D/Scene/-children/51/Transform/-children/5/DISEntityManager/-children"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/56/DISEntityManager/-children"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   },
   {
     "op": "remove",
     "path": "/X3D/Scene/-children/57/LoadSensor/-children/2"
   }
]



More information about the x3d-public mailing list