From: Frank T. B. <fbe...@ca...> - 2011-11-25 18:26:30
|
> But that's just lucky, if the ' parameter' elements haven't changed > between level 2 and level 3. Presumably the idea behind encoding levels into > the SBML namespace is to indicate infrequent but substantial changes within > the schema - so it's not a general solution that is guaranteed to work. One > solution might be to have 'list of namespaces' element which would be the > namespaces that the newxml is valid for, which by default would just be the > namespace of the model to which the change should be applied. > Correct, this is pure luck :) ... This was precisely my point before, all the changes that happen through raw XML manipulation is mostly luck if we can make it work. There are no guarantees that you will get a valid document at the end (just imagine the target xpath being just slightly different and suddenly things would no longer work out). No lust of namespaces will work :) What would work is to have more refined constructs, but those would likely have to be more language specific. > Also, as it stands , the XML is in the SED-ML namespace, which is incorrect - > isn't the situation more akin to that of annotations, where any content is OK > so long as it's in its own namespace? > That is a restriction we make in the spec, not something that would be enforced by the schema as it stands. In any case I don't mind adding the namespaces there. But as I said I don't see it as providing any real benefit, it is not going to add more safety or make it *more likely* that the raw XML manipulation succeeds, in fact it makes it less likely in cases like the one described above. Frank > Cheers > > Richard > > > > > > > > > So what happens if we now tag the XML with its own namespace? > > > > - it looks nicer and we are sure that the parameters really are not in > > the SED-ML namespace (but we knew that, right?) > > > > However, when *blindly* applying this change now to an SBML L3 model, > > this results in an invalid model. > > > > > > > I'm on the fence on this one. While it looks nicer it also ties the > > change closer to a specific model. We don't gain any validation > > capabilities at this point (as the schema says anything goes). So the > > best you can hope for is for a tool to exit sooner and refusing the > > modification of the source model. > > > > Frank > > > >> -----Original Message----- > >> From: Nicolas Le Novère [mailto:le...@eb...] > >> Sent: Friday, November 25, 2011 9:27 AM > >> To: sed...@li... > >> Subject: Re: [SED-ML-discuss] Namespaces in NewXML > >> > >> I think you are right. > >> > >> On 25/11/11 17:25, Richard Adams wrote: > >>> Hello All, > >>> I'm doing some work with adding /changing model XML via the Change > >>> elements - I think we really need to state somewhere that the > >>> added > >>> XML should be in its own namespace. As it stands, arbritary XML > >>> contained in a NewXML element is included in the SED-ML namespace. > >>> > >>> E.g., currently ( for an SBML model, for example ) > >>> <listOfChanges> > >>> <addXML > >> target="/sbml:sbml/sbml:model/sbml:listOfParameters"> > >>> <newXML> > >>> <parameter > >> metaid="metaid_0000010" id="newParam1" value="0.7" /> > >>> <parameter > >> metaid="metaid_0000011" id="newParam2" value="0.7" /> > >>> </newXML> > >>> </addXML> > >>> </listOfChanges> > >>> > >>> is currently valid, but I think it should be: > >>> > >>> <listOfChanges> > >>> <addXML > >> target="/sbml:sbml/sbml:model/sbml:listOfParameters"> > >>> <newXML> > >>> <parameter > >> xmlns="http://www.sbml.org/sbml/level2" > >>> metaid="metaid_0000010" id="newParam1" value="0.7" /> > >>> <parameter > >> xmlns="http://www.sbml.org/sbml/level2" > >>> metaid="metaid_0000011" id="newParam2" value="0.7" /> > >>> </newXML> > >>> </addXML> > >>> </listOfChanges> > >>> > >>> Or, declare in the toplevel of the sedML, for example. > >>> <sedML xmlns:sbml="http://www.sbml.org/sbml/level2" ...> ... > >>> <listOfChanges> > >>> <addXML > >> target="/sbml:sbml/sbml:model/sbml:listOfParameters"> > >>> <newXML> > >>> <sbml:parameter > >> metaid="metaid_0000010" id="newParam1" > >>> value="0.7" /> > >>> <sbml:parameter > >> metaid="metaid_0000011" id="newParam2" > >>> value="0.7" /> > >>> </newXML> > >>> </addXML> > >>> </listOfChanges> > >>> > >>> > >>> Cheers > >>> Richard > >>> > >>> > >>> > >>> Dr Richard Adams > >>> Software Development Team Leader, > >>> Centre For Systems Biology Edinburgh University of Edinburgh > >>> Tel: 0131 651 9019 > >>> email : ric...@ed... > >>> Web: http://csbe.bio.ed.ac.uk/adams.php > >>> > >>> > >>> > >>> > >>> > >>> > >> > >> > >> -- > >> Nicolas LE NOVERE, Computational Systems Neurobiology, EMBL-EBI, > >> WTGC, > >> Hinxton CB101SD UK, Mob:+447833147074, Tel:+441223494521 Fax:468, > >> le...@eb..., Skype:n.lenovere, twitter:@lenovere > >> http://www.ebi.ac.uk/~lenov/, http://www.ebi.ac.uk/compneur/ > >> > >> Fight against prostate cancer (and support my moustache): > >> Donate at http://mobro.co/lenov > >> > >> > >> > > ---------------------------------------------------------------------------- > > -- > >> All the data continuously generated in your IT infrastructure > >> contains a definitive record of customers, application performance, > >> security threats, fraudulent activity, and more. Splunk takes this > >> data and makes sense of it. IT sense. And common sense. > >> http://p.sf.net/sfu/splunk-novd2d > >> _______________________________________________ > >> SED-ML-discuss mailing list > >> SED...@li... > >> https://lists.sourceforge.net/lists/listinfo/sed-ml-discuss > > > > > > ---------------------------------------------------------------------------- -- > > All the data continuously generated in your IT infrastructure > > contains a definitive record of customers, application performance, > > security threats, fraudulent activity, and more. Splunk takes this > > data and makes sense of it. IT sense. And common sense. > > http://p.sf.net/sfu/splunk-novd2d > > _______________________________________________ > > SED-ML-discuss mailing list > > SED...@li... > > https://lists.sourceforge.net/lists/listinfo/sed-ml-discuss > > > > Dr Richard Adams > Software Development Team Leader, > Centre For Systems Biology Edinburgh > University of Edinburgh > Tel: 0131 651 9019 > email : ric...@ed... > Web: http://csbe.bio.ed.ac.uk/adams.php > > > > > > > -- > The University of Edinburgh is a charitable body, registered in > Scotland, with registration number SC005336. > > > ---------------------------------------------------------------------------- -- > All the data continuously generated in your IT infrastructure > contains a definitive record of customers, application performance, > security threats, fraudulent activity, and more. Splunk takes this > data and makes sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-novd2d > _______________________________________________ > SED-ML-discuss mailing list > SED...@li... > https://lists.sourceforge.net/lists/listinfo/sed-ml-discuss |