Forums

F.A.Q. F.A.Q.    Register Register    Login Login    Home Home
Search Search
SBML Discussions » jsbml-development » create compartment is missing id
Show: Today's Posts  :: Message Navigator
| Subscribe to topic 
Return to the default flat view Create a new topic Submit Reply
AuthorTopic
rodrigue


Posts: 307
Location:
Cambridge UK
Registered:
February 2005
Re: create compartment is missing id 18 Apr '11 10:42 Go to previous messageGo to previous message

On 18/04/2011 12:59, Clemens Wrzodek wrote:
> I think, if something has a defined level/version, other than the
> parent, throw an exception.
> If level/version is undefined, change it recursively.
>

Yes, I think that is the best way.

Nico


> Am 18.04.2011 18:56, schrieb Andreas Dräger:
>> Dear all,
>>
>>>>> listOfCompartments.add(compartment );
>>>>> document.getModel().setListOfCompartments(listOfCompartments );
>>> What happens is that when writing this model to XML the writer does
>>> not know that you desire to write a compartment of Level 2, it
>>> therefore only writes the name as this is done in Level 1.
>> While checking this example in detail I noticed that JSBML adapts the
>> Level/Version combination when adding elements to that of the parent.
>> See the method setThisAsParentSBMLObject in AbstractSBase. There you
>> can see that the method checkLevelAndVersionCompatibility actually
>> changes the Level/Version combination of an element. This is not done
>> recursively. To set L/V recursively, we have to set both at the same
>> time to avoid invalid L/V combinations. However, I am asking myself if
>> JSBML should be more strict and throw an exception when trying to add
>> something with different L/V combination to a parent object. What do
>> people think?
>>
>> Way 1: Silently change the L/V combination in a recursive way
>> Way 2: Throw an exception.
>>
>> What is better?
>>
>> Cheers
>> Andreas
>>

____________________________________________________________
To manage your jsbml-development list subscription, visit
https://utils.its.caltech.edu/mailman/listinfo/jsbml-development

For a web interface to the jsbml-development mailing list, visit
http://sbml.org/Forums/

For questions or feedback about the jsbml-development list,
contact sbml-team@caltech.edu

      

SubjectPosterDate
Read Message   create compartment is missing id spike18 Apr '11 02:57
Read Message   Re: create compartment is missing id Mike Hucka18 Apr '11 09:00
Read Message   Re: create compartment is missing id Lucian Smith18 Apr '11 19:49
Read Message   Re: create compartment is missing id Mike Hucka18 Apr '11 20:16
Read Message   Re: create compartment is missing id Andreas Dräger18 Apr '11 09:28
Read Message   Re: create compartment is missing id Andreas Dräger18 Apr '11 09:56
Read Message   Re: create compartment is missing id Clemens Wrzodek18 Apr '11 09:59
Read Message   Re: create compartment is missing id  rodrigue18 Apr '11 10:42
Read Message   Re: create compartment is missing id Lucian Smith18 Apr '11 19:50
Read Message   Re: create compartment is missing id Andreas Dräger18 Apr '11 20:17
Read Message   Re: create compartment is missing id spike19 Apr '11 01:34
Previous Topic:how to represent a family of proteins
Next Topic:Write to SBML
Go to forum:
-=] Back to Top [=-

Powered by FUDforum. (Copyright Advanced Internet Designs Inc.)

Please use our issue tracking system for any questions or suggestions about this website.