[x3d-public] X3dToJava.xslt errors? confirmed, now fixed
Brutzman, Donald (Don) (CIV)
brutzman at nps.edu
Sun Jul 30 09:46:46 PDT 2023
BLUF: found and fixed stylesheet error, correction committed back into version control.
1. Confirm that your java program is not working.
2. I tried to find your original .x3d source at the advertised meta location (in your java source) but no joy. Am trying to duplicate the error production.
<td style="text-align:right; vertical-align: text-top;"> <i> title </i> </td>
<td> <a href=https://coderextreme.net/X3DJSONLD/abox.x3d>abox.x3d</a> </td>
Sidebar: note that meta title typically indicates filename, while meta identifier is typically url location.
* X3D Scene Authoring Hints: meta
* https://www.web3d.org/x3d/content/examples/X3dSceneAuthoringHints.html#meta
* X3D Tooltips, meta, name
* https://www.web3d.org/x3d/content/X3dTooltips.html#meta.name
* Hint: for broadest searchability, use Dublin Core Metadata Initiative (DCMI) terms for name values. https://www.dublincore.org/documents/dcmi-terms
* https://www.dublincore.org/specifications/dublin-core/dcmi-terms/#http://purl.org/dc/terms/title
* Definition: a name given to the resource
3. I did a search and found some version of your original .x3d model at
* https://github.com/coderextreme/X3DJSONLD/blob/master/src/main/data/abox.x3d
* This one has more suitable meta tags, but still (apparently) an incorrect url as identifier.
<meta name='title' content='abox.x3d'/>
<meta name='creator' content='John Carlson'/>
<meta name='generator' content='manual'/>
<meta name='identifier' content='https://coderextreme.net/X3DJSONLD/abox.x3d'/>
<meta name='description' content='a box'/>
4. Downloaded the model and loaded it in X3D-Edit 4.0.
Canonicalization (C14N) version attached for simpler scrutiny.
Validation (checkmark) passed, results follow.
--------- X3D Validator checks commenced for abox.x3d ---------
Performing well-formed XML check...
Checking file:/C:/Users/brutzman/OneDrive%20-%20Naval%20Postgraduate%20School/Desktop/abox.x3d...
Well-formed XML check: pass
Performing DOCTYPE check...
[X3dDoctypeChecker] success: valid XML declaration found.[X3dDoctypeChecker] success: final X3D 3.3 DOCTYPE found.
Performing DTD validation...
Checking file:/C:/Users/brutzman/OneDrive%20-%20Naval%20Postgraduate%20School/Desktop/abox.x3d...
XML DTD validation: pass
Performing X3D schema validation...
Checking file:/C:/Users/brutzman/OneDrive%20-%20Naval%20Postgraduate%20School/Desktop/abox.x3d...
Referenced entity at http://www.w3.org/TR/2002/REC-xmldsig-core-20020212/xmldsig-core-schema.xsd.
Referenced entity at http://www.w3.org/2001/XMLSchema.dtd.
Referenced entity at http://www.w3.org/2001/datatypes.dtd.
XML schema validation: pass
Performing X3D regular expression (regex) values check...
X3D regex check: complete
Performing X3dToX3dvClassicVrmlEncoding.xslt conversion check...
[hint] Recommended: add <meta name='created' /> date content for documentation [check X3D source or VRML output to find pertinent head]
[hint] Recommended: add <meta name='modified' /> date content for documentation [check X3D source or VRML output to find pertinent head]
Performing X3D Schematron check...
<ProtoInstance name='one' DEF=''> <fieldValue name='myShape' value=''/> has matching ProtoDeclare with same name, but no corresponding field match for this fieldValue name='myShape' [/X3D/Scene/ProtoInstance/fieldValue, error]
--------- X3D Validator checks complete for abox.x3d ---------
5. Performed an X3dToJava.xslt conversion. Got the same error as you. Not sure why this wasn’t picked up before, will look further at that.
Aha, error confirmed. Missing line, just preceding the self-validation error:
String validationResults = thisExampleX3dModel.validationReport();
Checked in XSLT correction, thanks for report. Available at
* https://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/stylesheets/X3dToJava.xslt
* https://sourceforge.net/p/x3d/code/35290
Hopefully that fixes your production chain. Apologies for misstep.
Again thanks. Very timely since we plan to deploy an X3D-Edit update tomorrow in preparation for SIGGRAPH release.
Have fun with X3D Java! 8)
all the best, Don
--
Don Brutzman Naval Postgraduate School, Code USW/Br brutzman at nps.edu
Watkins 270, MOVES Institute, Monterey CA 93943-5000 USA +1.831.656.2149
X3D graphics, virtual worlds, navy robotics https://faculty.nps.edu/brutzman
From: x3d-public <x3d-public-bounces at web3d.org> On Behalf Of John Carlson
Sent: Sunday, July 30, 2023 12:21 AM
To: X3D Graphics public mailing list <x3d-public at web3d.org>
Subject: [x3d-public] X3dToJava.xslt errors?
I'm getting lots of errors like this with files combine out of X3dToJava.xslt.
Please check your own generated Java, if you're still working with Java.
$ javac -cp ~/pythonSAI/X3DJSAIL.4.0.full.jar net/x3djsonld/data/abox.java
net\x3djsonld\data\abox.java:175: error: cannot find symbol
if (validationResults.length() > 10)
^
symbol: variable validationResults
location: class abox
net\x3djsonld\data\abox.java:177: error: cannot find symbol
System.out.println(validationResults);
^
symbol: variable validationResults
location: class abox
2 errors
Code attached.
Thanks,
John
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20230730/8ff8f3a7/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: abox.x3d
Type: model/x3d+xml
Size: 1724 bytes
Desc: not available
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20230730/8ff8f3a7/attachment-0001.x3d>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5464 bytes
Desc: not available
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20230730/8ff8f3a7/attachment-0001.p7s>
More information about the x3d-public
mailing list