From: Richard A. <ra...@st...> - 2009-03-22 23:36:11
|
Oh great, That all sounds fine then. I'll try to look at your example next week Dagmar. Frank, so you mean something like: String sedMLDoc.getModel(String modelId); which would hide all the need for getting XPath terms, and return a String of the model? That would be more direct, for sure. Richard > Just to say that I agree with everything Frank wrote (hopefully I > understood right what he meant ;-)). > > Dagmar > > > > Frank Bergmann wrote: >> Hello ... >> >> >>> Hi, >>> Just a query about the listOfModels element - is it assumed to be >>> the case that, for a given sedml document, it will describe a single >>> 'reference' model version, which will be the first model in the list, >>> and subsequent entries in the list will refer to that base model, >>> applying changes (as is the case with the example 'oscillation to >>> chaos' model)? Or, is it possible that a given sedml document could >>> refer to >1 reference model? >>> >> >> Definitely ... you can (and should be able to) refer to more than one model. >> >> >> >>> I'm asking from the point of view of how a self-contained .miase >>> archive file might look. (By self contained, I mean that the >>> application using it will be able to access all the information needed >>> to run a simulation without having to query repositories - with the >>> help of a supporting library. ) In the first case above, it would >>> only ever contain a single model file, in the second case, it could >>> contain multiple models. >>> >> >> In my implementation, the self-contained .miase file, still has the option >> of referring to external sources. Thus There could be 0 or more models >> contained in the archive. >> >> >>> Also, do we want to allow archives which contain all model variants as >>> complete models, or are we going to stick with a 'reference' version >>> of the model, and generate new, altered versions of the model by >>> applying Xpath changes on the fly at runtime? I assume the latter, but >>> I can't find anything in the current examples, or in the CMSB2008.pdf >>> to distinguish between these possibilities. >>> >>> >> >> I hoped to keep the .miase file as simple as possible. It really just >> provides the option of storing (locally) referenced files conveniently. >> Apart from that there should not be more logic needed to interpret a .miase >> file, as compared to the original experiment description. For that reason >> I'd opt of making the changes on the fly, they won't be expensive to do. >> While writing out you can opt to refer to the altered models if you so >> desire, however with that you loose the information, that the second model >> is actually the first model with a handful of changes ... >> >> >>> From the point of view of supporting library methods, I was thinking >>> something along the lines of: >>> >>> MiaseArchive archive = libSedml.readArchive(String >>> filepathToMiaseArchive); >>> >>> // A MiaseArchive enables access to a sedml document, and model >>> file(s?) >>> SedmlDocument document = archive.getSedMlDocument(); >>> // access Sedml DOM via >>> document.getSedMlModel(); >>> >>> //access model file ( or is it possible to have > 1 model file >>> here??) >>> >> >> YES it is ... :) ... >> >> >>> // if the latter, need method to iterate over multiple model files. >>> String referenceModelContents = archive.getModelAsString(); >>> >>> //now, get XPath change from SedML model and apply it >>> ListOfChanges changes = >>> sedMl.getListOfModels.getModelById(modelID).getListOfChanges(); >>> String alteredModelContents = >>> document.applyChanges(referenceModelContents,changes); >>> >>> >> >> Instead of >> >> document.applyChanges(referenceModelContents,changes); >> >> I'd prefer to just grab the changed model. That's what I did in my >> implementation, for a user there is hardly a difference on the two model >> types. Thy have the option of getting the model source from both, and in >> that case the changed model, applies the changes automatically. >> >> Best >> Frank >> >> >> ------------------------------------------------------------------------------ >> Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are >> powering Web 2.0 with engaging, cross-platform capabilities. Quickly and >> easily build your RIAs with Flex Builder, the Eclipse(TM)based development >> software that enables intelligent coding and step-through debugging. >> Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com >> _______________________________________________ >> Miase-discuss mailing list >> Mia...@li... >> https://lists.sourceforge.net/lists/listinfo/miase-discuss >> > > > ------------------------------------------------------------------------------ > Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are > powering Web 2.0 with engaging, cross-platform capabilities. Quickly and > easily build your RIAs with Flex Builder, the Eclipse(TM)based development > software that enables intelligent coding and step-through debugging. > Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com > _______________________________________________ > Miase-discuss mailing list > Mia...@li... > https://lists.sourceforge.net/lists/listinfo/miase-discuss > > -- Dr Richard Adams Senior Software Developer, Computational Systems Biology Group, University of Edinburgh Tel: 0131 650 8285 email : ric...@ed... -- The University of Edinburgh is a charitable body, registered in Scotland, with registration number SC005336. |