[x3d-public] ECMAScript (JavaScript) language support for X3D
John Carlson
yottzumm at gmail.com
Sun Jun 7 03:28:21 PDT 2020
I don't know as there were additional validations added to JSON schema
2019-08 over JSON schema draft07. More of a renaming is what I saw was the
difference. Are you suggesting regular expression testing? We'll have to
compare regexp languages, perhaps. I have some regex stuff commented out
in the current version of the draft07 X3D JSON schema generator. That
would likely add a big plus, hopefully with little effort. We could
probably add autogenerated enums, possibly getting rid of Roy's geoSystem
handcoding.
I've already done much of the comparison between Roy's schema and the
autogenerated schema. We can review that if you want, but I don't think
we'll magically find new things to work on.
What additional validations would you like to add that we could submit to
the JSON schema site or the schema validator packages?
We can work on a second autogenerated JSON schema, perhaps using XMLSpy?
I now see:
JavaScript: https://github.com/hyperjump-io/json-schema-validator
https://github.com/cfworker/cfworker/blob/master/packages/json-schema/README.md
Java: https://github.com/ssilverman/snowy-json
for JSON schema 2019-09 validators. It seems like things have advanced a
few inches.
Please give Snow a "whirl," if it has that correct license.
For schema generation, check out:
https://github.com/victools/jsonschema-generator
Please provide updates on which JSON schema draft versions XMLSpy uses. I
suggest you create some workflows or whatever they are called in XMLSpy to
validate JSON automatically with XMLSpy.
I think I need to add validation capabilities from X3DUOM into the es6x3d
libraries. I can up the priority of that, adding set routine to
constructors so that validation is done during instance construction and in
setters, as you suggested.
I may not get to that for a couple of weeks. I seem to have switched back
into procedural generation mode again, this time probably for HAnim. So
HAnim will probably consume me for a while, I hope.
I found your 7 link. It's important to note that not all browsers track
the standards lockstep. I think we should probably track ES2015 (aka ES6)
as that has the most browser support, unless you can find a reference
suggesting otherwise. I think if we move away from ES6, it should be
towards TypeScript, which can likely transpile nearly any JavaScript
version you like. I don't think JSON has moved much. But yeah, we should
be able to use the TypeScript transpiler or Babel on ECMA, JS, ISO, etc. to
get a version which runs in many browsers.
John
On Sun, Jun 7, 2020 at 1:55 AM Don Brutzman <brutzman at nps.edu> wrote:
> On 6/4/2020 12:31 AM, John Carlson wrote:
> > I also saw that JSON was standardized by ISO. See:
> >
> > https://www.iso.org/standard/71616.html
>
> Dated 2017.
>
> ISO reference [7] below includes JSON and is dated 2018, so that takes
> precedence.
>
> X3D is an ISO/IEC spec so we always list other ISO/IEC specs first, based
> on ISO rules.
>
> ISO has been closely tracking with ECMA for a number of years now. ECMA
> has liaison status so it is an additional layer of formal review that
> occurs.
>
> > Good news!
>
> Yes
>
> > Can we progress without a standardized schema?
>
> Why sure. Validation is never a requirement for operation, it is "merely"
> exceptionally valuable to tell whether something is correct or not.
>
> I personally don't think further work on X3D JSON is worthwhile on that
> until we get JSON validation capabilities. What we have now seems to work
> for all cases, so further refinements will depend on such testing. YMMV.
>
> > John
> >
> > On Thu, Jun 4, 2020 at 2:28 AM John Carlson <yottzumm at gmail.com <mailto:
> yottzumm at gmail.com>> wrote:
> >
> > I saw internationalization for ECMAScript in your included image.
> Very important!
> >
> > John
> >
> > On Wed, Jun 3, 2020 at 8:15 AM Don Brutzman <brutzman at nps.edu
> <mailto:brutzman at nps.edu>> wrote:
> >
> > As we start exploring potential upgrade to X3D Scene Access
> Interface (SAI) for ECMAScript (JavaScript), it is good to establish
> expectations for support.
> >
> > Summary recommendation: we should use latest version for best
> compatibility and future stability.
> >
> > This will be an agenda item Friday for X3D Working Group, let's
> discuss to ensure complete clarity, then enter a Mantis issue for planned
> X3D specification updates.
> >
> > References of interest follow, all freely available:
> >
> > [0] X3D Graphics Standards Relationships
> >
> https://www.web3d.org/specifications/X3dSpecificationRelationships.png
> >
> https://www.web3d.org/specifications/X3dSpecificationRelationships.pdf
> >
> > [1] X3D Architecture, 29.4.1 Script
> >
> https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/scripting.html#Script
> >
> > "Browsers are not required to support any specific language.
> Detailed information on scripting languages is described in 29.2 Concepts.
> Browsers supporting a scripting language for which a language binding is
> specified shall adhere to that language binding (see _ISO/IEC 19777_)."
> >
> > [2] X3D Architecture, 29.2.1 Overview
> >
> https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/scripting.html#ScriptingOverview
> >
> > "This clause describes the general mechanisms and semantics of
> all scripting access. _2.[I19775-2]_ defines a set of abstract scripting
> services and specific languages bound to those services."
> >
> > TODO editorial erratum: inconsistent referencing style
> >
> > [3] X3D Abstract : Scene Access Interface (SAI), ISO/IEC
> 19775-2:2015
> > Clause 7 Conformance and minimum support requirements
> >
> https://www.web3d.org/documents/specifications/19775-2/V3.3/Part02/conformance.html
> >
> > [4] X3D Language Bindings : ECMAScript (JavaScript)
> > ISO/IEC CD 19777-1:201x, Edition 2, v3.3
> >
> https://www.web3d.org/documents/specifications/19777-1/V3.3/index.html
> >
> > [5] X3D Language Bindings : ECMAScript (JavaScript), 2 Normative
> references
> > I16262 - ISO/IEC 16262:2011 Information technology —
> ECMAScript language specification
> >
> https://www.web3d.org/documents/specifications/19777-1/V3.3/Part1/references.html
> >
> > [6] ISO/IEC 16262:2011
> > Information technology — Programming languages, their
> environments and system software interfaces — ECMAScript language
> specification
> >
> > "This standard has been revised by ISO/IEC 22275:2018"
> >
> > [7] ISO/IEC 22275:2018
> > Information technology — Programming languages, their
> environments, and system software interfaces — ECMAScript® Specification
> Suite
> > https://www.iso.org/standard/73002.html
> >
> > The electronic version of this International Standard can
> be downloaded from the ISO/IEC Information Technology Task Force (ITTF) web
> site.
> >
> http://isotc.iso.org/livelink/livelink/fetch/2000/2489/Ittf_Home/PubliclyAvailableStandards.htm
> >
> https://standards.iso.org/ittf/PubliclyAvailableStandards/c073002_ISO_IEC_22275_2018.zip
> > (10 pages long)
> >
> > "The following Standards constitute the current ECMAScript
> Specification Suite (see Figure 1)"
> >
> > * ECMA-262, ECMAScript® Language Specification
> > * ECMA-402, ECMAScript® Internationalization API Specification
> > * ISO/IEC 21778, Information technology — The JSON data
> interchange syntax [Adoption of ECMA-404]
> >
> > Attached: Figure 1 — Components of the ECMAScript Specification
> Suite Standard
> >
> > [8] Standard ECMA-262 - Ecma International
> >
> https://www.ecma-international.org/publications/standards/Ecma-262.htm
> > 10th edition (June 2019)
> >
> > "Standard ECMA-262. This Standard defines the ECMAScript 2019
> general-purpose programming language. Kindly note that the normative copy
> is the HTML version; the PDF version has been produced to generate a
> printable document. This 10th edition has been prepared under the Ecma RF
> patent policy."
> >
> > Gosh, that was easy wasn't it...
> >
> > As ever, all comments welcome. Have fun with X3D and
> JavaScript! 8)
> >
> > all the best, Don
> > --
> > Don Brutzman Naval Postgraduate School, Code USW/Br
> brutzman at nps.edu <mailto:brutzman at nps.edu>
> > Watkins 270, MOVES Institute, Monterey CA 93943-5000 USA
> +1.831.656.2149
> > X3D graphics, virtual worlds, navy robotics
> http://faculty.nps.edu/brutzman
> > _______________________________________________
> > x3d-public mailing list
> > x3d-public at web3d.org <mailto:x3d-public at web3d.org>
> > http://web3d.org/mailman/listinfo/x3d-public_web3d.org
> >
>
> 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
> http://faculty.nps.edu/brutzman
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20200607/3824171d/attachment.html>
More information about the x3d-public
mailing list