|
From: Peter Murray-R. <pm...@ca...> - 2015-03-31 21:14:54
|
I am afraid it is the W3C specification for XML names and we have adopted that . if you use any character like / or () it will break XML compliant software where this is a name. As you have it , it's a data item but some tools attempt to validate it. It may be more human-readable but it's machine unreadable. see http://www.xml.com/pub/a/2001/07/25/namingparts.html or the XML spec. And these names can expand into RDF URLs where again punctuation characters would break them. Great to have your interest P. On Tue, Mar 31, 2015 at 9:20 PM, Oliver Stueker <oli...@mu...> wrote: > Hi everyone, > I've cross-posted to the cml-discuss and quixote lists as I think I need > input from both groups. > > I have just started trying to validate my CML/CompChem files using a > standalone cml-validator.jar (from Bitbucket). > > And I get errors like: > <?xml version="1.0" encoding="UTF-8"?> > <report xmlns="http://www.xml-cml.org/report/"> > <final-report> > <well-formed-test> > <valid>xml is well formed</valid> > </well-formed-test> > <schema-validation-test> > <error>cvc-pattern-valid: Value 'x:QCISD(T)' is not > facet-valid with respect to pattern > '[A-Za-z][A-Za-z0-9_]*:[A-Za-z][A-Za-z0-9_\.\-]*' for type > 'namespaceRefType'.</error> > </schema-validation-test> > </final-report> > </report> > > complaining that my dictRef="x:QCISD(T)" contains parenthesis. > This is a pity because I would really like to use things like: > > <scalar dataType="xsd:double" dictRef="cc:Energy(0K)" > units="nonSi:hartree">-40.422101</scalar> > <scalar dataType="xsd:double" dictRef="cc:Energy(T)" > units="nonSi:hartree">-40.419229</scalar> > <scalar dataType="xsd:double" units="nonSi:hartree" > dictRef="g:energy(MP2/G3Bas1)">-40.3325515</scalar> > <scalar dataType="xsd:double" units="nonSi:hartree" > dictRef="g:energy(QCISD(T)/G3Bas1)">-40.3559402</scalar> > <scalar dataType="xsd:double" units="nonSi:hartree" > dictRef="g:energy(G3MP2)">-40.4221009</scalar> > > As I think they are more instructive than: > > <scalar dataType="xsd:double" dictRef="cc:Energy_0K" > units="nonSi:hartree">-40.422101</scalar> > <scalar dataType="xsd:double" dictRef="cc:Energy_T" > units="nonSi:hartree">-40.419229</scalar> > <scalar dataType="xsd:double" units="nonSi:hartree" > dictRef="g:energy_MP2_G3Bas1">-40.3325515</scalar> > <scalar dataType="xsd:double" units="nonSi:hartree" > dictRef="g:energy_QCISD_T_G3Bas1">-40.3559402</scalar> > <scalar dataType="xsd:double" units="nonSi:hartree" > dictRef="g:energy_G3MP2_">-40.4221009</scalar> > > Especially I find the "dictRef="g:energy(QCISD(T)/G3Bas1)" is much more > readable than dictRef="g:energy_QCISD_T_G3Bas1" . > > Is there a good reason to restrict the allowed characters of > namespaceRefType to '[A-Za-z0-9_\.\-]' ? > > I'm open for comments and suggestions. > > > Cheers, > Oliver > > > -- > Oliver Stueker, Dr. rer. nat. > Department of Chemistry, Memorial University > > -- > You received this message because you are subscribed to the Google Groups > "Quixote project on QC databases" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to qui...@go.... > For more options, visit https://groups.google.com/d/optout. > -- Peter Murray-Rust Reader in Molecular Informatics Unilever Centre, Dep. Of Chemistry University of Cambridge CB2 1EW, UK +44-1223-763069 |