Re: Units inheritance in Level 3
20 Mar '12 02:55
Am 3/20/12 10:50 AM, schrieb Sarah Keating:
> Hi Andreas
>> compartment and fix this problem for Level 3 models. Furthermore, when
>> deriving units, I would also like to have a mechanism that goes through
>> all units in the model's list of units and identifies the first unit
>> that is identically defined as the derived unit. In this way, the
>> derived unit would preferably be part of the SBML model, only in some
>> cases it would not be part of the model. Currently, it might happen that
>> the getDerivedUnits() method returns some unit definition that is
>> equally defined as some other unit definition within the model, but the
>> returned element is not part of the model.
> Can I clarify if I understand this correctly ?
> The function getDerivedUnits() returns a unitDefinition object (as
> defined by SBML). It is possible that the Model already contains a
> unitDefinition object which is identical to the returned
> unitDefinition. If this is the case you want to return the actual
> instance of the unitDefinition from the model rather than create a new
> unitDefinition object that is identical to one that already exists.
> Is that correct ?
Yes. That's what I would like to do. It is actually very easy using a
filter for listOf<UnitDefinition> that accepts the first identical
UnitDefinition (using a call like
with XX being the counter in the for-each loop).
Dr. Andreas Dräger
University of Tuebingen
Center for Bioinformatics Tuebingen (ZBIT)
To manage your jsbml-development list subscription, visit
For a web interface to the jsbml-development mailing list, visit
For questions or feedback about the jsbml-development list,
Powered by FUDforum. (Copyright Advanced Internet Designs Inc.)