- From: Mary Brady <mbrady@nist.gov>
- Date: Thu, 31 May 2001 12:02:20 -0400
- To: <www-dom-ts@w3.org>
----- Original Message ----- From: "Dimitris Dimitriadis" <dimitris.dimitriadis@improve.se> To: "'Mary Brady'" <mbrady@nist.gov>; <www-dom-ts@w3.org> Sent: Wednesday, May 30, 2001 9:51 AM Subject: SV: First pass at generated schema for DOM 1 + HTML > I think we should create a thread to discuss exactly what vocabulary we > intend to produce. Generating directly from the schema lets us use the > native inerface and method names. I'd like to see that we do this. > Okay --here's a start-- * Use IDL for attribute / method names * Specify var's, parameters, and returnTypes according to the spec: Spec always --> required in the schema Spec sometimes --> optional in the schema Spec never --> should not appear in the schema * Interface name -- should be inferable from somewhere, or defined as an attribute on the method name - defaulted as an attribute in cases where it is unambiguous - one of a list if it is available in more than one place. * Exceptions -- correspond according to the spec -- ie, only be able to specify the particular exceptions that can be thrown on a given attribute or method. any others ... > For the rest I propose the following for immediate action: > > 1. separate the dom ts ml generating parts from the language construct parts > in the schema > 2. write a simple app to run the xsl against all dom source files > 3. collect the schema snippets into one file, or create a master schema > (perhaps with the constructs and the packaging/suite info) and include the > other files. > Does any of this still need to be done? I have some cycles that I can spend ... Later today, I should be able to put out a NIST Test Matrix Table, that indicates what tests we have for a given interface. This is a first pass, much of which has been automatically generated -- it still needs work, but will give everyone an idea of the kind of coverage we have to offer. --Mary > /Dimitris > > -----Ursprungligt meddelande----- > Från: Mary Brady [mailto:mbrady@nist.gov] > Skickat: den 30 maj 2001 15:40 > Till: www-dom-ts@w3.org > Ämne: Re: First pass at generated schema for DOM 1 + HTML > > > This looks quite good -- I like the idea of > generating directly from the spec -- is it > the intent that the generated schema will > be equivalent to Curt's latest schema, if > we had updated it to include all of DOM > Level 1? > > --Mary > > ----- Original Message ----- > From: "Dimitris Dimitriadis" <dimitris.dimitriadis@improve.se> > To: "'Curt Arnold'" <carnold@houston.rr.com>; <www-dom-ts@w3.org> > Sent: Wednesday, May 30, 2001 9:16 AM > Subject: SV: First pass at generated schema for DOM 1 + HTML > > > > I've added the simpleTypes > > > > <xsd:simpleType name="DOMExceptionCode"> > > <xsd:annotation> > > <xsd:documentation>DOMExceptions raised</xsd:documentation> > > </xsd:annotation> > > <xsd:restriction base="xsd:string"> > > <xsd:pattern value="[A-Z][_]*"/> > > </xsd:restriction> > > </xsd:simpleType> > > <xsd:simpleType name="RangeExceptionCode"> > > <xsd:annotation> > > <xsd:documentation>RangeExceptionCode</xsd:documentation> > > </xsd:annotation> > > <xsd:restriction base="xsd:string"> > > </xsd:restriction> > > </xsd:simpleType> > > <xsd:simpleType name="EventExceptionCode"> > > <xsd:annotation> > > <xsd:documentation>EventExceptionCode</xsd:documentation> > > </xsd:annotation> > > <xsd:restriction base="xsd:string"> > > </xsd:restriction> > > </xsd:simpleType> > > > > to my local Copy as well as preliminary definitions of the followinf > (taken > > from Curt's original schema) > > > > <xsd:element name="dispatchEvent" substitutionGroup="DOMFunction"> > > <xsd:annotation> > > <xsd:appinfo> > > <!--<annot:function featureOf="EventTarget" > > return="boolean"/>--> > > </xsd:appinfo> > > </xsd:annotation> > > <xsd:complexType> > > <xsd:complexContent> > > <xsd:extension base="DOMFunction"> > > <xsd:attribute name="event" type="variable" > > use="required"/> > > </xsd:extension> > > </xsd:complexContent> > > </xsd:complexType> > > </xsd:element> > > <xsd:complexType name="DOMFunction"> > > <xsd:attribute name="obj" type="variable" use="required"/> > > > > <xsd:attribute name="var" type="variable" use="required"/> > > </xsd:complexType> > > <xsd:element name="DOMFunction" type="DOMFunction" abstract="true"/> > > > > and it seems to work fine. I'll continue tuning it and post the result > later > > today. > > > > I have som eproblems with my source files, though, for example the > > Document.xml for level 1 doesn't have a root node. This goes for some of > the > > HTML interfaces as well. > > > > /Dimitris > > > > > > -----Ursprungligt meddelande----- > > Från: Curt Arnold [mailto:carnold@houston.rr.com] > > Skickat: den 30 maj 2001 08:53 > > Till: www-dom-ts@w3.org > > Ämne: First pass at generated schema for DOM 1 + HTML > > > > > > I've posted an XSLT transform and a generated XML Schema from the DOM 1 > xml > > sources at http://home.houston.rr.com/curta/domtest/genschema.zip It is > > really fresh and only superficially checked. I executed the transform > with > > SAXON 6.2.2. > > > > It should be pretty easy to generate both XML Schema and DTD's from the > DOM > > specs XML sources and so eliminate the need for XML Schema to DTD > > conversion. However, I started with XML Schema first, as always. > > > > The transform isn't smart enough yet to handle an read-write property name > > that has different types in different uses or methods with different > calling > > signatures in different uses. > > > > I've not tried the transform against the level 2 sources, but I did take a > > quick look at them. There were a couple of issues, first the directory > > entries in the xml-sources.zip file contained "..", for example, one file > > was named "..\..\..\pubtext\xmlspec-v21-dom.dtd". This requires you to > > unpack to a directory at least 3 levels deep. It would also be helpful to > > know what parameters can accept a null string or node. > > > > > > > > >
Received on Thursday, 31 May 2001 12:04:22 UTC