001/* ---------------------------------------------------------------------------- 002 * This file was automatically generated by SWIG (http://www.swig.org). 003 * Version 3.0.8 004 * 005 * Do not make changes to this file unless you know what you are doing--modify 006 * the SWIG interface file instead. 007 * ----------------------------------------------------------------------------- */ 008 009package org.sbml.libsbml; 010 011/** 012 * An SBML <em>species</em> – a pool of entities. 013 <p> 014 * A <em>species</em> in SBML refers to a pool of entities that (a) are 015 * considered indistinguishable from each other for the purposes of the 016 * model, (b) participate in reactions, and (c) are located in a specific 017 * <em>compartment</em>. The SBML {@link Species} object class is intended to represent 018 * these pools. 019 <p> 020 * As with other major constructs in SBML, {@link Species} has a mandatory 021 * attribute, 'id', used to give the species type an identifier in the 022 * model. The identifier must be a text string conforming to the identifer 023 * syntax permitted in SBML. {@link Species} also has an optional 'name' 024 * attribute, of type <code>string.</code> The 'id' and 'name' must be used 025 * according to the guidelines described in the SBML specifications. 026 <p> 027 * The required attribute 'compartment' is used to identify the compartment 028 * in which the species is located. The attribute's value must be the 029 * identifier of an existing {@link Compartment} object. It is important to note 030 * that there is no default value for the 'compartment' attribute on 031 * {@link Species}; every species in an SBML model must be assigned a compartment 032 * <em>explicitly</em>. (This also implies that every model with one or more 033 * {@link Species} objects must define at least one {@link Compartment} object.) 034 <p> 035 * <h2>The initial amount and concentration of a species</h2> 036 <p> 037 * The optional attributes 'initialAmount' and 'initialConcentration', both 038 * having a data type of <code>double</code>, can be used to set the <em>initial</em> 039 * quantity of the species in the compartment where the species is located. 040 * These attributes are mutually exclusive; i.e., <em>only one</em> can 041 * have a value on any given instance of a {@link Species} object. Missing 042 * 'initialAmount' and 'initialConcentration' values implies that their 043 * values either are unknown, or to be obtained from an external source, or 044 * determined by an {@link InitialAssignment} or other SBML construct elsewhere in 045 * the model. 046 <p> 047 * A species' initial quantity in SBML is set by the 'initialAmount' or 048 * 'initialConcentration' attribute exactly once. If the 'constant' 049 * attribute is <code>true</code>, then the value of the species' quantity is fixed 050 * and cannot be changed except by an {@link InitialAssignment}. These methods 051 * differ in that the 'initialAmount' and 'initialConcentration' attributes 052 * can only be used to set the species quantity to a literal floating-point 053 * number, whereas the use of an {@link InitialAssignment} object allows the value 054 * to be set using an arbitrary mathematical expression (which, thanks to 055 * MathML's expressiveness, may evaluate to a rational number). If the 056 * species' 'constant' attribute is <code>false</code>, the species' quantity value 057 * may be overridden by an {@link InitialAssignment} or changed by {@link AssignmentRule} 058 * or {@link AlgebraicRule}, and in addition, for <em>t > 0</em>, it may also be 059 * changed by a {@link RateRule}, {@link Event} objects, and as a result of being a 060 * reactant or product in one or more {@link Reaction} objects. (However, some 061 * constructs are mutually exclusive; see the SBML specifications for the 062 * precise details.) It is not an error to define 'initialAmount' or 063 * 'initialConcentration' on a species and also redefine the value using an 064 * {@link InitialAssignment}, but the 'initialAmount' or 'initialConcentration' 065 * setting in that case is ignored. The SBML specifications provide 066 * additional information about the semantics of assignments, rules and 067 * values for simulation time <em>t</em> ≤ <em>0</em>. 068 <p> 069 * SBML Level 2 additionally stipulates that in cases where a species' 070 * compartment has a 'spatialDimensions' value of <code>0</code> (zero), the species 071 * cannot have a value for 'initialConcentration' because the concepts of 072 * concentration and density break down when a container has zero 073 * dimensions. 074 <p> 075 * <h2>The units of a species' amount or concentration</h2> 076 <p> 077 * When the attribute 'initialAmount' is set, the unit of measurement 078 * associated with the value of 'initialAmount' is specified by the {@link Species} 079 * attribute 'substanceUnits'. When the 'initialConcentration' attribute 080 * is set, the unit of measurement associated with this concentration value 081 * is {<em>unit of amount</em>} divided by {<em>unit of size</em>}, where 082 * the {<em>unit of amount</em>} is specified by the {@link Species} 083 * 'substanceUnits' attribute, and the {<em>unit of size</em>} is specified 084 * by the 'units' attribute of the {@link Compartment} object in which the species 085 * is located. Note that in either case, a unit of <em>amount</em> is 086 * involved and determined by the 'substanceUnits' attribute. Note 087 * <strong>these two attributes alone do not determine the units of the 088 * species when the species identifier appears in a mathematical 089 * expression</strong>; <em>that</em> aspect is determined by the attribute 090 * 'hasOnlySubstanceUnits' discussed below. 091 <p> 092 * In SBML Level 3, if the 'substanceUnits' attribute is not set on a 093 * given {@link Species} object instance, then the unit of <em>amount</em> for that 094 * species is inherited from the 'substanceUnits' attribute on the 095 * enclosing {@link Model} object instance. If that attribute on {@link Model} is not set 096 * either, then the unit associated with the species' quantity is 097 * undefined. 098 <p> 099 * In SBML Level 2, if the 'substanceUnits' attribute is not set on a 100 * given {@link Species} object instance, then the unit of <em>amount</em> for that 101 * species is taken from the predefined SBML unit identifier 102 * <code>'substance'.</code> The value assigned to 'substanceUnits' must be chosen from 103 * one of the following possibilities: one of the base unit identifiers 104 * defined in SBML, the built-in unit identifier <code>'substance'</code>, or the 105 * identifier of a new unit defined in the list of unit definitions in the 106 * enclosing {@link Model} object. The chosen units for 'substanceUnits' must be 107 * be <code>'dimensionless'</code>, <code>'mole'</code>, <code>'item'</code>, <code>'kilogram'</code>, <code>'gram'</code>, 108 * or units derived from these. 109 <p> 110 * As noted at the beginning of this section, simply setting 111 * 'initialAmount' or 'initialConcentration' alone does <em>not</em> determine 112 * whether a species identifier represents an amount or a concentration 113 * when it appears elsewhere in an SBML model. The role of the attribute 114 * 'hasOnlySubstanceUnits' is to indicate whether the units of the species, 115 * when the species identifier appears in mathematical formulas, are 116 * intended to be concentration or amount. The attribute takes on a 117 * boolean value. In SBML Level 3, the attribute has no default value 118 * and must always be set in a model; in SBML Level 2, it has a 119 * default value of <code>false.</code> 120 <p> 121 * The <em>units of the species</em> are used in the following ways: 122 * <ul> 123<p> 124 * <li> When the species' identifier appears in a MathML formula, it 125 * represents the species' quantity, and the unit of measurement associated 126 * with the quantity is as described above. 127 <p> 128 * <li> The 'math' elements of {@link AssignmentRule}, {@link InitialAssignment} and 129 * {@link EventAssignment} objects referring to this species should all have the 130 * same units as the unit of measurement associated with the species 131 * quantity. 132 <p> 133 * <li> In a {@link RateRule} object that defines the rate of change of the 134 * species' quantity, the unit associated with the rule's 'math' element 135 * should be equal to the unit of the species' quantity divided by the 136 * model-wide unit of <em>time</em>; in other words, {<em>unit of species 137 * quantity</em>}/{<em>unit of time</em>}. 138 <p> 139 * </ul> 140 <p> 141 * <h2>The 'constant' and 'boundaryCondition' attributes</h2> 142 <p> 143 * The {@link Species} object class has two boolean attributes named 'constant' and 144 * 'boundaryCondition', used to indicate whether and how the quantity of 145 * that species can vary during a simulation. In SBML Level 2 they 146 * are optional; in SBML Level 3 they are mandatory. The following 147 * table shows how to interpret the combined values of these attributes. 148 <p> 149 * <table border="0" class="centered text-table width80 normal-font alt-row-colors"> 150<caption class="top-caption">Interpretation 151of species' <code>constant</code> and <code>boundaryCondition</code> 152attributes.</caption> 153 <tr> 154 <th align="left" valign="bottom"> 155 <code>constant</code><br>value 156 </th> 157 <th align="left" valign="bottom"> 158 <code>boundaryCondition</code><br>value 159 </th> 160 <th align="left" valign="bottom"> 161 Can have<br>assignment<br>or rate rule? 162 </th> 163 <th align="left" valign="bottom"> 164 Can be<br>reactant<br>or product? 165 </th> 166 <th align="left" valign="bottom"> 167 Species' quantity<br>can be changed by 168 </th> 169 </tr> 170 <tr> 171 <td><code>true</code></td> 172 <td><code>true</code></td> 173 <td>no</td> 174 <td>yes</td> 175 <td>(never changes)</td> 176 </tr> 177 <tr> 178 <td><code>false</code></td> 179 <td><code>true</code></td> 180 <td>yes</td> 181 <td>yes</td> 182 <td>rules and events</td> 183 </tr> 184 <tr> 185 <td><code>true</code></td> 186 <td><code>false</code></td> 187 <td>no</td> 188 <td>no</td> 189 <td>(never changes)</td> 190 </tr> 191 <tr> 192 <td><code>false</code></td> 193 <td><code>false</code></td> 194 <td>yes</td> 195 <td>yes</td> 196 <td>reactions <em>or</em> rules (but not both at the same time), and events</td> 197 </tr> 198</table> 199 200 201 <p> 202 * By default, when a species is a product or reactant of one or more 203 * reactions, its quantity is determined by those reactions. In SBML, it 204 * is possible to indicate that a given species' quantity is <em>not</em> 205 * determined by the set of reactions even when that species occurs as a 206 * product or reactant; i.e., the species is on the <em>boundary</em> of 207 * the reaction system, and its quantity is not determined by the 208 * reactions. The boolean attribute 'boundaryCondition' can be used to 209 * indicate this. A value of <code>false</code> indicates that the species <em>is</em> 210 * part of the reaction system. In SBML Level 2, the attribute has a 211 * default value of <code>false</code>, while in SBML Level 3, it has no 212 * default. 213 <p> 214 * The 'constant' attribute indicates whether the species' quantity can be 215 * changed at all, regardless of whether by reactions, rules, or constructs 216 * other than {@link InitialAssignment}. A value of <code>false</code> indicates that the 217 * species' quantity can be changed. (This is also a common value because 218 * the purpose of most simulations is precisely to calculate changes in 219 * species quantities.) In SBML Level 2, the attribute has a default 220 * value of <code>false</code>, while in SBML Level 3, it has no default. Note 221 * that the initial quantity of a species can be set by an 222 * {@link InitialAssignment} irrespective of the value of the 'constant' attribute. 223 <p> 224 * In practice, a 'boundaryCondition' value of <code>true</code> means a differential 225 * equation derived from the reaction definitions should not be generated 226 * for the species. However, the species' quantity may still be changed by 227 * {@link AssignmentRule}, {@link RateRule}, {@link AlgebraicRule}, {@link Event}, and {@link InitialAssignment} 228 * constructs if its 'constant' attribute is <code>false.</code> Conversely, if the 229 * species' 'constant' attribute is <code>true</code>, then its value cannot be 230 * changed by anything except {@link InitialAssignment}. 231 <p> 232 * A species having 'boundaryCondition'=<code>false</code> and 'constant'=<code>false</code> 233 * can appear as a product and/or reactant of one or more reactions in the 234 * model. If the species is a reactant or product of a reaction, it must 235 * <em>not</em> also appear as the target of any {@link AssignmentRule} or {@link RateRule} 236 * object in the model. If instead the species has 'boundaryCondition'= 237 * <code>false</code> and 'constant'=<code>true</code>, then it cannot appear as a reactant or 238 * product, or as the target of any {@link AssignmentRule}, {@link RateRule} or 239 * {@link EventAssignment} object in the model. 240 <p> 241 * <h2>The conversionFactor attribute in SBML Level 3</h2> 242 <p> 243 * In SBML Level 3, {@link Species} has an additional optional attribute, 244 * 'conversionFactor', that defines a conversion factor that applies to a 245 * particular species. The value must be the identifier of a {@link Parameter} 246 * object instance defined in the model. That {@link Parameter} object must be a 247 * constant, meaning its 'constant' attribute must be set to <code>true.</code> 248 * If a given {@link Species} object definition defines a value for its 249 * 'conversionFactor' attribute, it takes precedence over any factor 250 * defined by the {@link Model} object's 'conversionFactor' attribute. 251 <p> 252 * The unit of measurement associated with a species' quantity can be 253 * different from the unit of extent of reactions in the model. SBML 254 * Level 3 avoids implicit unit conversions by providing an explicit 255 * way to indicate any unit conversion that might be required. The use of 256 * a conversion factor in computing the effects of reactions on a species' 257 * quantity is explained in detail in the SBML Level 3 specification 258 * document. Because the value of the 'conversionFactor' attribute is the 259 * identifier of a {@link Parameter} object, and because parameters can have units 260 * attached to them, the transformation from reaction extent units to 261 * species units can be completely specified using this approach. 262 <p> 263 * Note that the unit conversion factor is <strong>only applied when 264 * calculating the effect of a reaction on a species</strong>. It is not 265 * used in any rules or other SBML constructs that affect the species, and 266 * it is also not used when the value of the species is referenced in a 267 * mathematical expression. 268 <p> 269 * <h2>The speciesType attribute in SBML Level 2 Versions 2–4</h2> 270 <p> 271 * In SBML Level 2 Versions 2–4, each species in a model 272 * may optionally be designated as belonging to a particular species type. 273 * The optional attribute 'speciesType' is used to identify the species 274 * type of the chemical entities that make up the pool represented by the 275 * {@link Species} objects. The attribute's value must be the identifier of an 276 * existing {@link SpeciesType} object in the model. If the 'speciesType' 277 * attribute is not present on a particular species definition, it means 278 * the pool contains chemical entities of a type unique to that pool; in 279 * effect, a virtual species type is assumed for that species, and no other 280 * species can belong to that species type. The value of 'speciesType' 281 * attributes on species have no effect on the numerical interpretation of 282 * a model; simulators and other numerical analysis software may ignore 283 * 'speciesType' attributes. 284 <p> 285 * There can be only one species of a given species type in any given 286 * compartment of a model. More specifically, for all {@link Species} objects 287 * having a value for the 'speciesType' attribute, the pair 288 * <center> 289 * ('speciesType' attribute value, 'compartment' attribute value) 290 * </center> 291 <p> 292 * must be unique across the set of all {@link Species} object in a model. 293 <p> 294 * <h2>The spatialSizeUnits attribute in SBML Level 2 Versions 1–2</h2> 295 <p> 296 * In versions of SBML Level 2 before Version 3, the class 297 * {@link Species} included an attribute called 'spatialSizeUnits', which allowed 298 * explicitly setting the units of size for initial concentration. LibSBML 299 * retains this attribute for compatibility with older definitions of 300 * Level 2, but its use is strongly discouraged because many software 301 * tools do no properly interpret this unit declaration and it is 302 * incompatible with all SBML specifications after Level 2 303 * Version 3. 304 <p> 305 * <h2>Additional considerations for interpreting the numerical value of a species</h2> 306 <p> 307 * {@link Species} are unique in SBML in that they have a kind of duality: a 308 * species identifier may stand for either substance amount (meaning, a 309 * count of the number of individual entities) or a concentration or 310 * density (meaning, amount divided by a compartment size). The previous 311 * sections explain the meaning of a species identifier when it is 312 * referenced in a mathematical formula or in rules or other SBML 313 * constructs; however, it remains to specify what happens to a species 314 * when the compartment in which it is located changes in size. 315 <p> 316 * When a species definition has a 'hasOnlySubstanceUnits' attribute value 317 * of <code>false</code> and the size of the compartment in which the species is 318 * located changes, the default in SBML is to assume that it is the 319 * concentration that must be updated to account for the size change. This 320 * follows from the principle that, all other things held constant, if a 321 * compartment simply changes in size, the size change does not in itself 322 * cause an increase or decrease in the number of entities of any species 323 * in that compartment. In a sense, the default is that the <em>amount</em> of 324 * a species is preserved across compartment size changes. Upon such size 325 * changes, the value of the concentration or density must be recalculated 326 * from the simple relationship <em>concentration = amount / size</em> if 327 * the value of the concentration is needed (for example, if the species 328 * identifier appears in a mathematical formula or is otherwise referenced 329 * in an SBML construct). There is one exception: if the species' quantity 330 * is determined by an {@link AssignmentRule}, {@link RateRule}, {@link AlgebraicRule}, or an 331 * {@link EventAssignment} and the species has a 'hasOnlySubstanceUnits' attribute 332 * value of <code>false</code>, it means that the <em>concentration</em> is assigned 333 * by the rule or event; in that case, the <em>amount</em> must be 334 * calculated when the compartment size changes. (Events also require 335 * additional care in this situation, because an event with multiple 336 * assignments could conceivably reassign both a species quantity and a 337 * compartment size simultaneously. Please refer to the SBML 338 * specifications for the details.) 339 <p> 340 * Note that the above only matters if a species has a 341 * 'hasOnlySubstanceUnits' attribute value of <code>false</code>, meaning that the 342 * species identifier refers to a concentration wherever the identifier 343 * appears in a mathematical formula. If instead the attribute's value is 344 * <code>true</code>, then the identifier of the species <em>always</em> stands for 345 * an amount wherever it appears in a mathematical formula or is referenced 346 * by an SBML construct. In that case, there is never a question about 347 * whether an assignment or event is meant to affect the amount or 348 * concentration: it is always the amount. 349 <p> 350 * A particularly confusing situation can occur when the species has 351 * 'constant' attribute value of <code>true</code> in combination with a 352 * 'hasOnlySubstanceUnits' attribute value of <code>false.</code> Suppose this 353 * species is given a value for 'initialConcentration'. Does a 'constant' 354 * value of <code>true</code> mean that the concentration is held constant if the 355 * compartment size changes? No; it is still the amount that is kept 356 * constant across a compartment size change. The fact that the species 357 * was initialized using a concentration value is irrelevant. 358 */ 359 360public class Species extends SBase { 361 private long swigCPtr; 362 363 protected Species(long cPtr, boolean cMemoryOwn) 364 { 365 super(libsbmlJNI.Species_SWIGUpcast(cPtr), cMemoryOwn); 366 swigCPtr = cPtr; 367 } 368 369 protected static long getCPtr(Species obj) 370 { 371 return (obj == null) ? 0 : obj.swigCPtr; 372 } 373 374 protected static long getCPtrAndDisown (Species obj) 375 { 376 long ptr = 0; 377 378 if (obj != null) 379 { 380 ptr = obj.swigCPtr; 381 obj.swigCMemOwn = false; 382 } 383 384 return ptr; 385 } 386 387 protected void finalize() { 388 delete(); 389 } 390 391 public synchronized void delete() { 392 if (swigCPtr != 0) { 393 if (swigCMemOwn) { 394 swigCMemOwn = false; 395 libsbmlJNI.delete_Species(swigCPtr); 396 } 397 swigCPtr = 0; 398 } 399 super.delete(); 400 } 401 402 403/** 404 * Creates a new {@link Species} using the given SBML <code>level</code> and <code>version</code> 405 * values. 406 <p> 407 * @param level a long integer, the SBML Level to assign to this {@link Species} 408 <p> 409 * @param version a long integer, the SBML Version to assign to this 410 * {@link Species} 411 <p> 412 * <p> 413 * @throws SBMLConstructorException 414 * Thrown if the given <code>level</code> and <code>version</code> combination are invalid 415 * or if this object is incompatible with the given level and version. 416 <p> 417 * <p> 418 * @note Attempting to add an object to an {@link SBMLDocument} having a different 419 * combination of SBML Level, Version and XML namespaces than the object 420 * itself will result in an error at the time a caller attempts to make the 421 * addition. A parent object must have compatible Level, Version and XML 422 * namespaces. (Strictly speaking, a parent may also have more XML 423 * namespaces than a child, but the reverse is not permitted.) The 424 * restriction is necessary to ensure that an SBML model has a consistent 425 * overall structure. This requires callers to manage their objects 426 * carefully, but the benefit is increased flexibility in how models can be 427 * created by permitting callers to create objects bottom-up if desired. In 428 * situations where objects are not yet attached to parents (e.g., 429 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help 430 * libSBML determine such things as whether it is valid to assign a 431 * particular value to an attribute. 432 */ public 433 Species(long level, long version) throws org.sbml.libsbml.SBMLConstructorException { 434 this(libsbmlJNI.new_Species__SWIG_0(level, version), true); 435 } 436 437 438/** 439 * Creates a new {@link Species} using the given {@link SBMLNamespaces} object 440 * <code>sbmlns</code>. 441 <p> 442 * <p> 443 * The {@link SBMLNamespaces} object encapsulates SBML Level/Version/namespaces 444 * information. It is used to communicate the SBML Level, Version, and (in 445 * Level 3) packages used in addition to SBML Level 3 Core. A 446 * common approach to using libSBML's {@link SBMLNamespaces} facilities is to create an 447 * {@link SBMLNamespaces} object somewhere in a program once, then hand that object 448 * as needed to object constructors that accept {@link SBMLNamespaces} as arguments. 449 <p> 450 * It is worth emphasizing that although this constructor does not take 451 * an identifier argument, in SBML Level 2 and beyond, the 'id' 452 * (identifier) attribute of a {@link Species} is required to have a value. 453 * Thus, callers are cautioned to assign a value after calling this 454 * constructor. Setting the identifier can be accomplished using the 455 * method {@link Species#setId(String)}. 456 <p> 457 * @param sbmlns an {@link SBMLNamespaces} object. 458 <p> 459 * <p> 460 * @throws SBMLConstructorException 461 * Thrown if the given <code>sbmlns</code> is inconsistent or incompatible 462 * with this object. 463 <p> 464 * <p> 465 * @note Attempting to add an object to an {@link SBMLDocument} having a different 466 * combination of SBML Level, Version and XML namespaces than the object 467 * itself will result in an error at the time a caller attempts to make the 468 * addition. A parent object must have compatible Level, Version and XML 469 * namespaces. (Strictly speaking, a parent may also have more XML 470 * namespaces than a child, but the reverse is not permitted.) The 471 * restriction is necessary to ensure that an SBML model has a consistent 472 * overall structure. This requires callers to manage their objects 473 * carefully, but the benefit is increased flexibility in how models can be 474 * created by permitting callers to create objects bottom-up if desired. In 475 * situations where objects are not yet attached to parents (e.g., 476 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help 477 * libSBML determine such things as whether it is valid to assign a 478 * particular value to an attribute. 479 */ public 480 Species(SBMLNamespaces sbmlns) throws org.sbml.libsbml.SBMLConstructorException { 481 this(libsbmlJNI.new_Species__SWIG_1(SBMLNamespaces.getCPtr(sbmlns), sbmlns), true); 482 } 483 484 485/** 486 * Copy constructor; creates a copy of this {@link Species} object. 487 <p> 488 * @param orig the object to copy. 489 */ public 490 Species(Species orig) throws org.sbml.libsbml.SBMLConstructorException { 491 this(libsbmlJNI.new_Species__SWIG_2(Species.getCPtr(orig), orig), true); 492 } 493 494 495/** 496 * Creates and returns a deep copy of this {@link Species} object. 497 <p> 498 * @return the (deep) copy of this {@link Species} object. 499 */ public 500 Species cloneObject() { 501 long cPtr = libsbmlJNI.Species_cloneObject(swigCPtr, this); 502 return (cPtr == 0) ? null : new Species(cPtr, true); 503 } 504 505 506/** 507 * Initializes the fields of this {@link Species} object to 'typical' defaults 508 * values. 509 <p> 510 * The SBML {@link Species} component has slightly different aspects and 511 * default attribute values in different SBML Levels and Versions. 512 * This method sets the values to certain common defaults, based 513 * mostly on what they are in SBML Level 2. Specifically: 514 * <ul> 515 * <li> Sets 'boundaryCondition' to <code>false</code> 516 * <li> Sets 'constant' to <code>false</code> 517 * <li> sets 'hasOnlySubstanceUnits' to <code>false</code> 518 * <li> (Applies to Level 3 models only) Sets attribute 'substanceUnits' to <code>mole</code> 519 * </ul> 520 */ public 521 void initDefaults() { 522 libsbmlJNI.Species_initDefaults(swigCPtr, this); 523 } 524 525 526/** 527 * Returns the value of the 'id' attribute of this {@link Species} object. 528 <p> 529 * @return the id of this {@link Species} object. 530 */ public 531 String getId() { 532 return libsbmlJNI.Species_getId(swigCPtr, this); 533 } 534 535 536/** 537 * Returns the value of the 'name' attribute of this {@link Species} object. 538 <p> 539 * @return the name of this {@link Species} object. 540 */ public 541 String getName() { 542 return libsbmlJNI.Species_getName(swigCPtr, this); 543 } 544 545 546/** 547 * Get the type of this {@link Species} object object. 548 <p> 549 * @return the value of the 'speciesType' attribute of this 550 * {@link Species} as a string. 551 <p> 552 * @note The 'speciesType' attribute is only available in SBML 553 * Level 2 Versions 2–4. 554 */ public 555 String getSpeciesType() { 556 return libsbmlJNI.Species_getSpeciesType(swigCPtr, this); 557 } 558 559 560/** 561 * Get the compartment in which this species is located. 562 <p> 563 * The compartment is designated by its identifier. 564 <p> 565 * @return the value of the 'compartment' attribute of this {@link Species} 566 * object, as a string. 567 */ public 568 String getCompartment() { 569 return libsbmlJNI.Species_getCompartment(swigCPtr, this); 570 } 571 572 573/** 574 * Get the value of the 'initialAmount' attribute. 575 <p> 576 * @return the initialAmount of this {@link Species}, as a float-point number. 577 */ public 578 double getInitialAmount() { 579 return libsbmlJNI.Species_getInitialAmount(swigCPtr, this); 580 } 581 582 583/** 584 * Get the value of the 'initialConcentration' attribute. 585 <p> 586 * @return the initialConcentration of this {@link Species},, as a float-point 587 * number. 588 <p> 589 * @note The attribute 'initialConcentration' is only available in SBML 590 * Level 2 and 3. It does not exist on {@link Species} in Level 1. 591 */ public 592 double getInitialConcentration() { 593 return libsbmlJNI.Species_getInitialConcentration(swigCPtr, this); 594 } 595 596 597/** 598 * Get the value of the 'substanceUnits' attribute. 599 <p> 600 * @return the value of the 'substanceUnits' attribute of this {@link Species}, 601 * as a string. An empty string indicates that no units have been 602 * assigned. 603 <p> 604 * <p> 605 * @note There is an important distinction to be made between <em>no units 606 * assigned</em>, and assuming a value without units has any specific unit 607 * such as <code>dimensionless</code>. In SBML, default units are never 608 * attributed to numbers, and numbers without units are not automatically 609 * assumed to have the unit <code>dimensionless</code>. Please consult the 610 * relevant SBML specification document for a more in-depth explanation of 611 * this topic and the SBML unit system. 612 <p> 613 * @see #isSetSubstanceUnits() 614 * @see #setSubstanceUnits(String sid) 615 */ public 616 String getSubstanceUnits() { 617 return libsbmlJNI.Species_getSubstanceUnits(swigCPtr, this); 618 } 619 620 621/** 622 * Get the value of the 'spatialSizeUnits' attribute. 623 <p> 624 * @return the value of the 'spatialSizeUnits' attribute of this {@link Species} 625 * object, as a string. 626 <p> 627 * <p> 628 * @warning <span class='warning'>In versions of SBML Level 2 before 629 * Version 3, the class {@link Species} included an attribute called 630 * 'spatialSizeUnits', which allowed explicitly setting the units of size for 631 * initial concentration. This attribute was removed in SBML Level 2 632 * Version 3. LibSBML retains this attribute for compatibility with 633 * older definitions of Level 2, but its use is strongly discouraged 634 * because it is incompatible with Level 2 Version 3 and 635 * Level 2 Version 4.</span> 636 */ public 637 String getSpatialSizeUnits() { 638 return libsbmlJNI.Species_getSpatialSizeUnits(swigCPtr, this); 639 } 640 641 642/** 643 * Get the value of the 'units' attribute. 644 <p> 645 * @return the units of this {@link Species} (L1 only). 646 <p> 647 * <p> 648 * @note The 'units' attribute is defined only in SBML Level 1. In 649 * SBML Level 2 and Level 3, it has been replaced by a 650 * combination of 'substanceUnits' and the units of the {@link Compartment} 651 * object in which a species is located. In SBML Level 2 652 * Versions 1–2, an additional attribute 'spatialSizeUnits' 653 * helps determine the units of the species quantity, but this attribute 654 * was removed in later versions of SBML Level 2. 655 */ public 656 String getUnits() { 657 return libsbmlJNI.Species_getUnits(swigCPtr, this); 658 } 659 660 661/** 662 * Get the value of the 'hasOnlySubstanceUnits' attribute. 663 <p> 664 * @return <code>true</code> if this {@link Species}' 'hasOnlySubstanceUnits' attribute 665 * value is nonzero, <code>false</code> otherwise. 666 <p> 667 * @note The 'hasOnlySubstanceUnits' attribute does not exist in SBML 668 * Level 1. 669 */ public 670 boolean getHasOnlySubstanceUnits() { 671 return libsbmlJNI.Species_getHasOnlySubstanceUnits(swigCPtr, this); 672 } 673 674 675/** 676 * Get the value of the 'boundaryCondition' attribute. 677 <p> 678 * @return <code>true</code> if this {@link Species}' 'boundaryCondition' attribute value 679 * is nonzero, <code>false</code> otherwise. 680 */ public 681 boolean getBoundaryCondition() { 682 return libsbmlJNI.Species_getBoundaryCondition(swigCPtr, this); 683 } 684 685 686/** 687 * Get the value of the 'charge' attribute. 688 <p> 689 * @return the charge of this {@link Species} object. 690 <p> 691 * <p> 692 * @note Beginning in SBML Level 2 Version 2, the 'charge' 693 * attribute on {@link Species} is deprecated and in SBML Level 3 it does 694 * not exist at all. Its use strongly discouraged. Its presence is 695 * considered a misfeature in earlier definitions of SBML because its 696 * implications for the mathematics of a model were never defined, and in 697 * any case, no known modeling system ever used it. Instead, models take 698 * account of charge values directly in their definitions of species by 699 * (for example) having separate species identities for the charged and 700 * uncharged versions of the same species. This allows the condition to 701 * affect model mathematics directly. LibSBML retains this method for 702 * easier compatibility with SBML Level 1. 703 */ public 704 int getCharge() { 705 return libsbmlJNI.Species_getCharge(swigCPtr, this); 706 } 707 708 709/** 710 * Get the value of the 'constant' attribute. 711 <p> 712 * @return <code>true</code> if this {@link Species}'s 'constant' attribute value is 713 * nonzero, <code>false</code> otherwise. 714 <p> 715 * @note The attribute 'constant' is only available in SBML Levels 2 716 * and 3. It does not exist on {@link Species} in Level 1. 717 */ public 718 boolean getConstant() { 719 return libsbmlJNI.Species_getConstant(swigCPtr, this); 720 } 721 722 723/** 724 * Get the value of the 'conversionFactor' attribute. 725 <p> 726 * @return the conversionFactor of this {@link Species}, as a string. 727 <p> 728 * @note The 'conversionFactor' attribute was introduced in SBML 729 * Level 3. It does not exist on {@link Species} in SBML Levels 1 730 * and 2. 731 */ public 732 String getConversionFactor() { 733 return libsbmlJNI.Species_getConversionFactor(swigCPtr, this); 734 } 735 736 737/** 738 * Predicate returning <code>true</code> if this 739 * {@link Species} object's 'id' attribute is set. 740 <p> 741 * @return <code>true</code> if the 'id' attribute of this {@link Species} is 742 * set, <code>false</code> otherwise. 743 */ public 744 boolean isSetId() { 745 return libsbmlJNI.Species_isSetId(swigCPtr, this); 746 } 747 748 749/** 750 * Predicate returning <code>true</code> if this 751 * {@link Species} object's 'name' attribute is set. 752 <p> 753 * @return <code>true</code> if the 'name' attribute of this {@link Species} is 754 * set, <code>false</code> otherwise. 755 */ public 756 boolean isSetName() { 757 return libsbmlJNI.Species_isSetName(swigCPtr, this); 758 } 759 760 761/** 762 * Predicate returning <code>true</code> if this {@link Species} object's 763 * 'speciesType' attribute is set. 764 <p> 765 * @return <code>true</code> if the 'speciesType' attribute of this {@link Species} is 766 * set, <code>false</code> otherwise. 767 <p> 768 * @note The 'speciesType' attribute is only available in SBML 769 * Level 2 Versions 2–4. 770 */ public 771 boolean isSetSpeciesType() { 772 return libsbmlJNI.Species_isSetSpeciesType(swigCPtr, this); 773 } 774 775 776/** 777 * Predicate returning <code>true</code> if this 778 * {@link Species} object's 'compartment' attribute is set. 779 <p> 780 * @return <code>true</code> if the 'compartment' attribute of this {@link Species} is 781 * set, <code>false</code> otherwise. 782 */ public 783 boolean isSetCompartment() { 784 return libsbmlJNI.Species_isSetCompartment(swigCPtr, this); 785 } 786 787 788/** 789 * Predicate returning <code>true</code> if this 790 * {@link Species} object's 'initialAmount' attribute is set. 791 <p> 792 * @return <code>true</code> if the 'initialAmount' attribute of this {@link Species} is 793 * set, <code>false</code> otherwise. 794 <p> 795 * @note In SBML Level 1, {@link Species}' 'initialAmount' is required and 796 * therefore <em>should always be set</em>. (However, in Level 1, the 797 * attribute has no default value either, so this method will not return 798 * <code>true</code> until a value has been assigned.) In SBML Level 2, 799 * 'initialAmount' is optional and as such may or may not be set. 800 */ public 801 boolean isSetInitialAmount() { 802 return libsbmlJNI.Species_isSetInitialAmount(swigCPtr, this); 803 } 804 805 806/** 807 * Predicate returning <code>true</code> if this 808 * {@link Species} object's 'initialConcentration' attribute is set. 809 <p> 810 * @return <code>true</code> if the 'initialConcentration' attribute of this {@link Species} is 811 * set, <code>false</code> otherwise. 812 <p> 813 * @note The attribute 'initialConcentration' is only available in SBML 814 * Level 2 and 3. It does not exist on {@link Species} in Level 1. 815 */ public 816 boolean isSetInitialConcentration() { 817 return libsbmlJNI.Species_isSetInitialConcentration(swigCPtr, this); 818 } 819 820 821/** 822 * Predicate returning <code>true</code> if this 823 * {@link Species} object's 'substanceUnits' attribute is set. 824 <p> 825 * @return <code>true</code> if the 'substanceUnits' attribute of this {@link Species} is 826 * set, <code>false</code> otherwise. 827 */ public 828 boolean isSetSubstanceUnits() { 829 return libsbmlJNI.Species_isSetSubstanceUnits(swigCPtr, this); 830 } 831 832 833/** 834 * Predicate returning <code>true</code> if this 835 * {@link Species} object's 'spatialSizeUnits' attribute is set. 836 <p> 837 * @return <code>true</code> if the 'spatialSizeUnits' attribute of this {@link Species} is 838 * set, <code>false</code> otherwise. 839 <p> 840 * <p> 841 * @warning <span class='warning'>In versions of SBML Level 2 before 842 * Version 3, the class {@link Species} included an attribute called 843 * 'spatialSizeUnits', which allowed explicitly setting the units of size for 844 * initial concentration. This attribute was removed in SBML Level 2 845 * Version 3. LibSBML retains this attribute for compatibility with 846 * older definitions of Level 2, but its use is strongly discouraged 847 * because it is incompatible with Level 2 Version 3 and 848 * Level 2 Version 4.</span> 849 */ public 850 boolean isSetSpatialSizeUnits() { 851 return libsbmlJNI.Species_isSetSpatialSizeUnits(swigCPtr, this); 852 } 853 854 855/** 856 * Predicate returning <code>true</code> if 857 * this {@link Species} object's 'units' attribute is set. 858 <p> 859 * @return <code>true</code> if the 'units' attribute of this {@link Species} is 860 * set, <code>false</code> otherwise. 861 */ public 862 boolean isSetUnits() { 863 return libsbmlJNI.Species_isSetUnits(swigCPtr, this); 864 } 865 866 867/** 868 * Predicate returning <code>true</code> if this 869 * {@link Species} object's 'charge' attribute is set. 870 <p> 871 * @return <code>true</code> if the 'charge' attribute of this {@link Species} is 872 * set, <code>false</code> otherwise. 873 <p> 874 * <p> 875 * @note Beginning in SBML Level 2 Version 2, the 'charge' 876 * attribute on {@link Species} is deprecated and in SBML Level 3 it does 877 * not exist at all. Its use strongly discouraged. Its presence is 878 * considered a misfeature in earlier definitions of SBML because its 879 * implications for the mathematics of a model were never defined, and in 880 * any case, no known modeling system ever used it. Instead, models take 881 * account of charge values directly in their definitions of species by 882 * (for example) having separate species identities for the charged and 883 * uncharged versions of the same species. This allows the condition to 884 * affect model mathematics directly. LibSBML retains this method for 885 * easier compatibility with SBML Level 1. 886 */ public 887 boolean isSetCharge() { 888 return libsbmlJNI.Species_isSetCharge(swigCPtr, this); 889 } 890 891 892/** 893 * Predicate returning <code>true</code> if this 894 * {@link Species} object's 'conversionFactor' attribute is set. 895 <p> 896 * @return <code>true</code> if the 'conversionFactor' attribute of this {@link Species} is 897 * set, <code>false</code> otherwise. 898 <p> 899 * @note The 'conversionFactor' attribute was introduced in SBML 900 * Level 3. It does not exist on {@link Species} in SBML Levels 1 901 * and 2. 902 */ public 903 boolean isSetConversionFactor() { 904 return libsbmlJNI.Species_isSetConversionFactor(swigCPtr, this); 905 } 906 907 908/** 909 * Predicate returning <code>true</code> if this 910 * {@link Species} object's 'boundaryCondition' attribute is set. 911 <p> 912 * @return <code>true</code> if the 'boundaryCondition' attribute of this {@link Species} is 913 * set, <code>false</code> otherwise. 914 */ public 915 boolean isSetBoundaryCondition() { 916 return libsbmlJNI.Species_isSetBoundaryCondition(swigCPtr, this); 917 } 918 919 920/** 921 * Predicate returning <code>true</code> if this 922 * {@link Species} object's 'hasOnlySubstanceUnits' attribute is set. 923 <p> 924 * @return <code>true</code> if the 'hasOnlySubstanceUnits' attribute of this {@link Species} is 925 * set, <code>false</code> otherwise. 926 <p> 927 * @note The 'hasOnlySubstanceUnits' attribute does not exist in SBML 928 * Level 1. 929 */ public 930 boolean isSetHasOnlySubstanceUnits() { 931 return libsbmlJNI.Species_isSetHasOnlySubstanceUnits(swigCPtr, this); 932 } 933 934 935/** 936 * Predicate returning <code>true</code> if this 937 * {@link Species} object's 'constant' attribute is set. 938 <p> 939 * @return <code>true</code> if the 'constant' attribute of this {@link Species} is 940 * set, <code>false</code> otherwise. 941 <p> 942 * @note The attribute 'constant' is only available in SBML Levels 2 943 * and 3. It does not exist on {@link Species} in Level 1. 944 */ public 945 boolean isSetConstant() { 946 return libsbmlJNI.Species_isSetConstant(swigCPtr, this); 947 } 948 949 950/** 951 * Sets the value of the 'id' attribute of this {@link Species} object. 952 <p> 953 * The string <code>sid</code> is copied. 954 <p> 955 * <p> 956 * SBML has strict requirements for the syntax of identifiers, that is, the 957 * values of the 'id' attribute present on most types of SBML objects. 958 * The following is a summary of the definition of the SBML identifier type 959 * <code>SId</code>, which defines the permitted syntax of identifiers. We 960 * express the syntax using an extended form of BNF notation: 961 * <pre style='margin-left: 2em; border: none; font-weight: bold; font-size: 13px; color: black'> 962 * letter .= 'a'..'z','A'..'Z' 963 * digit .= '0'..'9' 964 * idChar .= letter | digit | '_' 965 * SId .= ( letter | '_' ) idChar*</pre> 966 * The characters <code>(</code> and <code>)</code> are used for grouping, the 967 * character <code>*</code> 'zero or more times', and the character 968 * <code>|</code> indicates logical 'or'. The equality of SBML identifiers is 969 * determined by an exact character sequence match; i.e., comparisons must be 970 * performed in a case-sensitive manner. In addition, there are a few 971 * conditions for the uniqueness of identifiers in an SBML model. Please 972 * consult the SBML specifications for the exact details of the uniqueness 973 * requirements. 974 <p> 975 * @param sid the string to use as the identifier of this {@link Species} 976 <p> 977 * <p> 978 * @return integer value indicating success/failure of the 979 * function. The possible values 980 * returned by this function are: 981 * <ul> 982 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 983 * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE} 984 * </ul> 985 */ public 986 int setId(String sid) { 987 return libsbmlJNI.Species_setId(swigCPtr, this, sid); 988 } 989 990 991/** 992 * Sets the value of the 'name' attribute of this {@link Species} object. 993 <p> 994 * The string in <code>name</code> is copied. 995 <p> 996 * @param name the new name for the {@link Species} 997 <p> 998 * <p> 999 * @return integer value indicating success/failure of the 1000 * function. The possible values 1001 * returned by this function are: 1002 * <ul> 1003 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1004 * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE} 1005 * </ul> 1006 */ public 1007 int setName(String name) { 1008 return libsbmlJNI.Species_setName(swigCPtr, this, name); 1009 } 1010 1011 1012/** 1013 * Sets the 'speciesType' attribute of this {@link Species} object. 1014 <p> 1015 * @param sid the identifier of a {@link SpeciesType} object defined elsewhere 1016 * in this {@link Model}. 1017 <p> 1018 * <p> 1019 * @return integer value indicating success/failure of the 1020 * function. The possible values 1021 * returned by this function are: 1022 * <ul> 1023 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1024 * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE} 1025 * <li> {@link libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE} 1026 * 1027 * </ul> <p> 1028 * @note The 'speciesType' attribute is only available in SBML 1029 * Level 2 Versions 2–4. 1030 */ public 1031 int setSpeciesType(String sid) { 1032 return libsbmlJNI.Species_setSpeciesType(swigCPtr, this, sid); 1033 } 1034 1035 1036/** 1037 * Sets the 'compartment' attribute of this {@link Species} object. 1038 <p> 1039 * @param sid the identifier of a {@link Compartment} object defined elsewhere 1040 * in this {@link Model}. 1041 <p> 1042 * <p> 1043 * @return integer value indicating success/failure of the 1044 * function. The possible values 1045 * returned by this function are: 1046 * <ul> 1047 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1048 * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE} 1049 * </ul> 1050 */ public 1051 int setCompartment(String sid) { 1052 return libsbmlJNI.Species_setCompartment(swigCPtr, this, sid); 1053 } 1054 1055 1056/** 1057 * Sets the 'initialAmount' attribute of this {@link Species} and marks the field 1058 * as set. 1059 <p> 1060 * This method also unsets the 'initialConcentration' attribute. 1061 <p> 1062 * @param value the value to which the 'initialAmount' attribute should 1063 * be set. 1064 <p> 1065 * <p> 1066 * @return integer value indicating success/failure of the 1067 * function. The possible values 1068 * returned by this function are: 1069 * <ul> 1070 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1071 * </ul> 1072 */ public 1073 int setInitialAmount(double value) { 1074 return libsbmlJNI.Species_setInitialAmount(swigCPtr, this, value); 1075 } 1076 1077 1078/** 1079 * Sets the 'initialConcentration' attribute of this {@link Species} and marks 1080 * the field as set. 1081 <p> 1082 * This method also unsets the 'initialAmount' attribute. 1083 <p> 1084 * @param value the value to which the 'initialConcentration' attribute 1085 * should be set. 1086 <p> 1087 * <p> 1088 * @return integer value indicating success/failure of the 1089 * function. The possible values 1090 * returned by this function are: 1091 * <ul> 1092 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1093 * <li> {@link libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE} 1094 * 1095 * </ul> <p> 1096 * @note The attribute 'initialConcentration' is only available in SBML 1097 * Level 2 and 3. It does not exist on {@link Species} in Level 1. 1098 */ public 1099 int setInitialConcentration(double value) { 1100 return libsbmlJNI.Species_setInitialConcentration(swigCPtr, this, value); 1101 } 1102 1103 1104/** 1105 * Sets the 'substanceUnits' attribute of this {@link Species} object. 1106 <p> 1107 * @param sid the identifier of the unit to use. 1108 <p> 1109 * <p> 1110 * @return integer value indicating success/failure of the 1111 * function. The possible values 1112 * returned by this function are: 1113 * <ul> 1114 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1115 * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE} 1116 * </ul> 1117 */ public 1118 int setSubstanceUnits(String sid) { 1119 return libsbmlJNI.Species_setSubstanceUnits(swigCPtr, this, sid); 1120 } 1121 1122 1123/** 1124 * (SBML Level 2 Versions 1–2) Sets the 'spatialSizeUnits' attribute of this {@link Species} object. 1125 <p> 1126 * @param sid the identifier of the unit to use. 1127 <p> 1128 * <p> 1129 * @return integer value indicating success/failure of the 1130 * function. The possible values 1131 * returned by this function are: 1132 * <ul> 1133 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1134 * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE} 1135 * <li> {@link libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE} 1136 * 1137 * </ul> <p> 1138 * <p> 1139 * @warning <span class='warning'>In versions of SBML Level 2 before 1140 * Version 3, the class {@link Species} included an attribute called 1141 * 'spatialSizeUnits', which allowed explicitly setting the units of size for 1142 * initial concentration. This attribute was removed in SBML Level 2 1143 * Version 3. LibSBML retains this attribute for compatibility with 1144 * older definitions of Level 2, but its use is strongly discouraged 1145 * because it is incompatible with Level 2 Version 3 and 1146 * Level 2 Version 4.</span> 1147 */ public 1148 int setSpatialSizeUnits(String sid) { 1149 return libsbmlJNI.Species_setSpatialSizeUnits(swigCPtr, this, sid); 1150 } 1151 1152 1153/** 1154 * (SBML Level 1 only) Sets the units of this {@link Species} object. 1155 <p> 1156 * @param sname the identifier of the unit to use. 1157 <p> 1158 * <p> 1159 * @return integer value indicating success/failure of the 1160 * function. The possible values 1161 * returned by this function are: 1162 * <ul> 1163 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1164 * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE} 1165 * </ul> 1166 */ public 1167 int setUnits(String sname) { 1168 return libsbmlJNI.Species_setUnits(swigCPtr, this, sname); 1169 } 1170 1171 1172/** 1173 * Sets the 'hasOnlySubstanceUnits' attribute of this {@link Species} object. 1174 <p> 1175 * @param value boolean value for the 'hasOnlySubstanceUnits' attribute. 1176 <p> 1177 * <p> 1178 * @return integer value indicating success/failure of the 1179 * function. The possible values 1180 * returned by this function are: 1181 * <ul> 1182 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1183 * <li> {@link libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE} 1184 * 1185 * </ul> <p> 1186 * @note The 'hasOnlySubstanceUnits' attribute does not exist in SBML 1187 * Level 1. 1188 */ public 1189 int setHasOnlySubstanceUnits(boolean value) { 1190 return libsbmlJNI.Species_setHasOnlySubstanceUnits(swigCPtr, this, value); 1191 } 1192 1193 1194/** 1195 * Sets the 'boundaryCondition' attribute of this {@link Species} object. 1196 <p> 1197 * @param value boolean value for the 'boundaryCondition' attribute. 1198 <p> 1199 * <p> 1200 * @return integer value indicating success/failure of the 1201 * function. The possible values 1202 * returned by this function are: 1203 * <ul> 1204 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1205 * </ul> 1206 */ public 1207 int setBoundaryCondition(boolean value) { 1208 return libsbmlJNI.Species_setBoundaryCondition(swigCPtr, this, value); 1209 } 1210 1211 1212/** 1213 * Sets the 'charge' attribute of this {@link Species} object. 1214 <p> 1215 * @param value an integer to which to set the 'charge' to. 1216 <p> 1217 * <p> 1218 * @note Beginning in SBML Level 2 Version 2, the 'charge' 1219 * attribute on {@link Species} is deprecated and in SBML Level 3 it does 1220 * not exist at all. Its use strongly discouraged. Its presence is 1221 * considered a misfeature in earlier definitions of SBML because its 1222 * implications for the mathematics of a model were never defined, and in 1223 * any case, no known modeling system ever used it. Instead, models take 1224 * account of charge values directly in their definitions of species by 1225 * (for example) having separate species identities for the charged and 1226 * uncharged versions of the same species. This allows the condition to 1227 * affect model mathematics directly. LibSBML retains this method for 1228 * easier compatibility with SBML Level 1. 1229 <p> 1230 * <p> 1231 * @return integer value indicating success/failure of the 1232 * function. The possible values 1233 * returned by this function are: 1234 * <ul> 1235 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1236 * <li> {@link libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE} 1237 * </ul> 1238 */ public 1239 int setCharge(int value) { 1240 return libsbmlJNI.Species_setCharge(swigCPtr, this, value); 1241 } 1242 1243 1244/** 1245 * Sets the 'constant' attribute of this {@link Species} object. 1246 <p> 1247 * @param value a boolean value for the 'constant' attribute 1248 <p> 1249 * <p> 1250 * @return integer value indicating success/failure of the 1251 * function. The possible values 1252 * returned by this function are: 1253 * <ul> 1254 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1255 * <li> {@link libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE} 1256 * 1257 * </ul> <p> 1258 * @note The attribute 'constant' is only available in SBML Levels 2 1259 * and 3. It does not exist on {@link Species} in Level 1. 1260 */ public 1261 int setConstant(boolean value) { 1262 return libsbmlJNI.Species_setConstant(swigCPtr, this, value); 1263 } 1264 1265 1266/** 1267 * Sets the value of the 'conversionFactor' attribute of this {@link Species} object. 1268 <p> 1269 * The string in <code>sid</code> is copied. 1270 <p> 1271 * @param sid the new conversionFactor for the {@link Species} 1272 <p> 1273 * <p> 1274 * @return integer value indicating success/failure of the 1275 * function. The possible values 1276 * returned by this function are: 1277 * <ul> 1278 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1279 * <li> {@link libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE} 1280 * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE} 1281 * 1282 * </ul> <p> 1283 * @note The 'conversionFactor' attribute was introduced in SBML 1284 * Level 3. It does not exist on {@link Species} in SBML Levels 1 1285 * and 2. 1286 */ public 1287 int setConversionFactor(String sid) { 1288 return libsbmlJNI.Species_setConversionFactor(swigCPtr, this, sid); 1289 } 1290 1291 1292/** 1293 * Unsets the value of the 'name' attribute of this {@link Species} object. 1294 <p> 1295 * <p> 1296 * @return integer value indicating success/failure of the 1297 * function. The possible values 1298 * returned by this function are: 1299 * <ul> 1300 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1301 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1302 * </ul> 1303 */ public 1304 int unsetName() { 1305 return libsbmlJNI.Species_unsetName(swigCPtr, this); 1306 } 1307 1308 1309/** 1310 * Unsets the value of the 'constant' attribute of this {@link Species} object. 1311 <p> 1312 * <p> 1313 * @return integer value indicating success/failure of the 1314 * function. The possible values 1315 * returned by this function are: 1316 * <ul> 1317 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1318 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1319 * 1320 * </ul> <p> 1321 * @see #isSetConstant() 1322 * @see #setConstant(boolean) 1323 * @see #getConstant() 1324 */ public 1325 int unsetConstant() { 1326 return libsbmlJNI.Species_unsetConstant(swigCPtr, this); 1327 } 1328 1329 1330/** 1331 * Unsets the 'speciesType' attribute value of this {@link Species} object. 1332 <p> 1333 * <p> 1334 * @return integer value indicating success/failure of the 1335 * function. The possible values 1336 * returned by this function are: 1337 * <ul> 1338 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1339 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1340 * 1341 * </ul> <p> 1342 * @note The attribute 'speciesType' is only available in SBML 1343 * Level 2 Versions 2–4. 1344 */ public 1345 int unsetSpeciesType() { 1346 return libsbmlJNI.Species_unsetSpeciesType(swigCPtr, this); 1347 } 1348 1349 1350/** 1351 * Unsets the 'initialAmount' attribute value of this {@link Species} object. 1352 <p> 1353 * <p> 1354 * @return integer value indicating success/failure of the 1355 * function. The possible values 1356 * returned by this function are: 1357 * <ul> 1358 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1359 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1360 * </ul> 1361 */ public 1362 int unsetInitialAmount() { 1363 return libsbmlJNI.Species_unsetInitialAmount(swigCPtr, this); 1364 } 1365 1366 1367/** 1368 * Unsets the 'initialConcentration' attribute value of this {@link Species} object. 1369 <p> 1370 * <p> 1371 * @return integer value indicating success/failure of the 1372 * function. The possible values 1373 * returned by this function are: 1374 * <ul> 1375 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1376 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1377 * 1378 * </ul> <p> 1379 * @note The attribute 'initialConcentration' is only available in SBML 1380 * Level 2 and 3. It does not exist on {@link Species} in Level 1. 1381 */ public 1382 int unsetInitialConcentration() { 1383 return libsbmlJNI.Species_unsetInitialConcentration(swigCPtr, this); 1384 } 1385 1386 1387/** 1388 * Unsets the 'substanceUnits' attribute value of this {@link Species} object. 1389 <p> 1390 * <p> 1391 * @return integer value indicating success/failure of the 1392 * function. The possible values 1393 * returned by this function are: 1394 * <ul> 1395 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1396 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1397 * </ul> 1398 */ public 1399 int unsetSubstanceUnits() { 1400 return libsbmlJNI.Species_unsetSubstanceUnits(swigCPtr, this); 1401 } 1402 1403 1404/** 1405 * Unsets the 'spatialSizeUnits' attribute value of this {@link Species} object. 1406 <p> 1407 * <p> 1408 * @return integer value indicating success/failure of the 1409 * function. The possible values 1410 * returned by this function are: 1411 * <ul> 1412 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1413 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1414 * 1415 * </ul> <p> 1416 * <p> 1417 * @warning <span class='warning'>In versions of SBML Level 2 before 1418 * Version 3, the class {@link Species} included an attribute called 1419 * 'spatialSizeUnits', which allowed explicitly setting the units of size for 1420 * initial concentration. This attribute was removed in SBML Level 2 1421 * Version 3. LibSBML retains this attribute for compatibility with 1422 * older definitions of Level 2, but its use is strongly discouraged 1423 * because it is incompatible with Level 2 Version 3 and 1424 * Level 2 Version 4.</span> 1425 */ public 1426 int unsetSpatialSizeUnits() { 1427 return libsbmlJNI.Species_unsetSpatialSizeUnits(swigCPtr, this); 1428 } 1429 1430 1431/** 1432 * Unsets the 'units' attribute value of this {@link Species} object. 1433 <p> 1434 * <p> 1435 * @return integer value indicating success/failure of the 1436 * function. The possible values 1437 * returned by this function are: 1438 * <ul> 1439 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1440 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1441 * </ul> 1442 */ public 1443 int unsetUnits() { 1444 return libsbmlJNI.Species_unsetUnits(swigCPtr, this); 1445 } 1446 1447 1448/** 1449 * Unsets the 'charge' attribute 1450 * value of this {@link Species} object. 1451 <p> 1452 * <p> 1453 * @return integer value indicating success/failure of the 1454 * function. The possible values 1455 * returned by this function are: 1456 * <ul> 1457 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1458 * <li> {@link libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE} 1459 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1460 * 1461 * </ul> <p> 1462 * <p> 1463 * @note Beginning in SBML Level 2 Version 2, the 'charge' 1464 * attribute on {@link Species} is deprecated and in SBML Level 3 it does 1465 * not exist at all. Its use strongly discouraged. Its presence is 1466 * considered a misfeature in earlier definitions of SBML because its 1467 * implications for the mathematics of a model were never defined, and in 1468 * any case, no known modeling system ever used it. Instead, models take 1469 * account of charge values directly in their definitions of species by 1470 * (for example) having separate species identities for the charged and 1471 * uncharged versions of the same species. This allows the condition to 1472 * affect model mathematics directly. LibSBML retains this method for 1473 * easier compatibility with SBML Level 1. 1474 */ public 1475 int unsetCharge() { 1476 return libsbmlJNI.Species_unsetCharge(swigCPtr, this); 1477 } 1478 1479 1480/** 1481 * Unsets the 'conversionFactor' attribute value of this {@link Species} object. 1482 <p> 1483 * <p> 1484 * @return integer value indicating success/failure of the 1485 * function. The possible values 1486 * returned by this function are: 1487 * <ul> 1488 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1489 * <li> {@link libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE} 1490 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1491 * 1492 * </ul> <p> 1493 * @note The 'conversionFactor' attribute was introduced in SBML 1494 * Level 3. It does not exist on {@link Species} in SBML Levels 1 1495 * and 2. 1496 */ public 1497 int unsetConversionFactor() { 1498 return libsbmlJNI.Species_unsetConversionFactor(swigCPtr, this); 1499 } 1500 1501 1502/** 1503 * Unsets the 'compartment' attribute value of this {@link Species} object. 1504 <p> 1505 * <p> 1506 * @return integer value indicating success/failure of the 1507 * function. The possible values 1508 * returned by this function are: 1509 * <ul> 1510 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1511 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1512 * </ul> 1513 */ public 1514 int unsetCompartment() { 1515 return libsbmlJNI.Species_unsetCompartment(swigCPtr, this); 1516 } 1517 1518 1519/** 1520 * Unsets the 'boundaryCondition' attribute value of this {@link Species} object. 1521 <p> 1522 * <p> 1523 * @return integer value indicating success/failure of the 1524 * function. The possible values 1525 * returned by this function are: 1526 * <ul> 1527 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1528 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1529 * </ul> 1530 */ public 1531 int unsetBoundaryCondition() { 1532 return libsbmlJNI.Species_unsetBoundaryCondition(swigCPtr, this); 1533 } 1534 1535 1536/** 1537 * Unsets the 'hasOnlySubstanceUnits' attribute value of this {@link Species} object. 1538 <p> 1539 * <p> 1540 * @return integer value indicating success/failure of the 1541 * function. The possible values 1542 * returned by this function are: 1543 * <ul> 1544 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 1545 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 1546 * </ul> 1547 */ public 1548 int unsetHasOnlySubstanceUnits() { 1549 return libsbmlJNI.Species_unsetHasOnlySubstanceUnits(swigCPtr, this); 1550 } 1551 1552 1553/** 1554 * Constructs and returns a {@link UnitDefinition} that corresponds to the units 1555 * of this {@link Species}' amount or concentration. 1556 <p> 1557 * {@link Species} in SBML have an attribute ('substanceUnits') for declaring the 1558 * units of measurement intended for the species' amount or concentration 1559 * (depending on which one applies). In the absence of a value given for 1560 * 'substanceUnits', the units are taken from the enclosing {@link Model}'s 1561 * definition of <code>'substance'</code> or <code>'substance'</code>/<em>(size of the 1562 * compartment)</em> in which the species is located, or finally, if 1563 * these are not redefined by the {@link Model}, the relevant SBML default units 1564 * for those quantities. Following that procedure, the method 1565 * {@link Species#getDerivedUnitDefinition()} 1566 * returns a {@link UnitDefinition} based on the 1567 * interpreted units of this species's amount or concentration. 1568 <p> 1569 * Note that the functionality that facilitates unit analysis depends 1570 * on the model as a whole. Thus, in cases where the object has not 1571 * been added to a model or the model itself is incomplete, 1572 * unit analysis is not possible and this method will return <code>null.</code> 1573 <p> 1574 * Note also that unit declarations for {@link Species} are in terms of the 1575 * <em>identifier</em> of a unit, but this method returns a {@link UnitDefinition} object, 1576 * not a unit identifier. It does this by constructing an appropriate 1577 * {@link UnitDefinition}. Callers may find this particularly useful when used 1578 * in conjunction with the helper methods on {@link UnitDefinition} for comparing 1579 * different {@link UnitDefinition} objects. 1580 <p> 1581 * In SBML Level 2 specifications prior to Version 3, {@link Species} 1582 * includes an additional attribute named 'spatialSizeUnits', which 1583 * allows explicitly setting the units of size for initial concentration. 1584 * The {@link Species#getDerivedUnitDefinition()} 1585 * takes this into account for models 1586 * expressed in SBML Level 2 Versions 1 and 2. 1587 <p> 1588 * @return a {@link UnitDefinition} that expresses the units of this 1589 * {@link Species}, or <code>null</code> if one cannot be constructed. 1590 <p> 1591 * @see #getSubstanceUnits() 1592 */ public 1593 UnitDefinition getDerivedUnitDefinition() { 1594 long cPtr = libsbmlJNI.Species_getDerivedUnitDefinition__SWIG_0(swigCPtr, this); 1595 return (cPtr == 0) ? null : new UnitDefinition(cPtr, false); 1596 } 1597 1598 1599/** 1600 * Returns the libSBML type code for this SBML object. 1601 <p> 1602 * <p> 1603 * LibSBML attaches an identifying code to every kind of SBML object. These 1604 * are integer constants known as <em>SBML type codes</em>. The names of all 1605 * the codes begin with the characters <code>SBML_</code>. 1606 * In the Java language interface for libSBML, the 1607 * type codes are defined as static integer constants in the interface class 1608 * {@link libsbmlConstants}. Note that different Level 3 1609 * package plug-ins may use overlapping type codes; to identify the package 1610 * to which a given object belongs, call the <code>getPackageName()</code> 1611 * method on the object. 1612 <p> 1613 * @return the SBML type code for this object: 1614 * {@link libsbmlConstants#SBML_SPECIES SBML_SPECIES} (default). 1615 <p> 1616 * <p> 1617 * @warning <span class='warning'>The specific integer values of the possible 1618 * type codes may be reused by different Level 3 package plug-ins. 1619 * Thus, to identifiy the correct code, <strong>it is necessary to invoke 1620 * both getTypeCode() and getPackageName()</strong>.</span> 1621 <p> 1622 * @see #getElementName() 1623 * @see #getPackageName() 1624 */ public 1625 int getTypeCode() { 1626 return libsbmlJNI.Species_getTypeCode(swigCPtr, this); 1627 } 1628 1629 1630/** 1631 * Returns the XML element name of this object, which for {@link Species}, is 1632 * always <code>'species'.</code> 1633 <p> 1634 * @return the name of this element, i.e., <code>'species'.</code> 1635 */ public 1636 String getElementName() { 1637 return libsbmlJNI.Species_getElementName(swigCPtr, this); 1638 } 1639 1640 1641/** 1642 * Predicate returning <code>true</code> if 1643 * all the required attributes for this {@link Species} object 1644 * have been set. 1645 <p> 1646 * The required attributes for a {@link Species} object are: 1647 * <ul> 1648 * <li> 'id' (or 'name' in SBML Level 1) 1649 * <li> 'compartment' 1650 * <li> 'initialAmount' (required in SBML Level 1 only; optional otherwise) 1651 * <li> 'hasOnlySubstanceUnits' (required in SBML Level 3; optional in SBML Level 2) 1652 * <li> 'boundaryCondition' (required in SBML Level 3; optional in Levels 1 and 2) 1653 * <li> 'constant' (required in SBML Level 3; optional in SBML Level 2) 1654 * 1655 * </ul> <p> 1656 * @return <code>true</code> if the required attributes have been set, <code>false</code> 1657 * otherwise. 1658 */ public 1659 boolean hasRequiredAttributes() { 1660 return libsbmlJNI.Species_hasRequiredAttributes(swigCPtr, this); 1661 } 1662 1663 1664/** 1665 * <p> 1666 * Replaces all uses of a given <code>SIdRef</code> type attribute value with another 1667 * value. 1668 <p> 1669 * <p> 1670 * In SBML, object identifiers are of a data type called <code>SId</code>. 1671 * In SBML Level 3, an explicit data type called <code>SIdRef</code> was 1672 * introduced for attribute values that refer to <code>SId</code> values; in 1673 * previous Levels of SBML, this data type did not exist and attributes were 1674 * simply described to as 'referring to an identifier', but the effective 1675 * data type was the same as <code>SIdRef</code>in Level 3. These and 1676 * other methods of libSBML refer to the type <code>SIdRef</code> for all 1677 * Levels of SBML, even if the corresponding SBML specification did not 1678 * explicitly name the data type. 1679 <p> 1680 * This method works by looking at all attributes and (if appropriate) 1681 * mathematical formulas in MathML content, comparing the referenced 1682 * identifiers to the value of <code>oldid</code>. If any matches are found, the 1683 * matching values are replaced with <code>newid</code>. The method does <em>not</em> 1684 * descend into child elements. 1685 <p> 1686 * @param oldid the old identifier 1687 * @param newid the new identifier 1688 */ public 1689 void renameSIdRefs(String oldid, String newid) { 1690 libsbmlJNI.Species_renameSIdRefs(swigCPtr, this, oldid, newid); 1691 } 1692 1693 1694/** 1695 * <p> 1696 * Replaces all uses of a given <code>UnitSIdRef</code> type attribute value with 1697 * another value. 1698 <p> 1699 * <p> 1700 * In SBML, unit definitions have identifiers of type <code>UnitSId</code>. In 1701 * SBML Level 3, an explicit data type called <code>UnitSIdRef</code> was 1702 * introduced for attribute values that refer to <code>UnitSId</code> values; in 1703 * previous Levels of SBML, this data type did not exist and attributes were 1704 * simply described to as 'referring to a unit identifier', but the effective 1705 * data type was the same as <code>UnitSIdRef</code> in Level 3. These and 1706 * other methods of libSBML refer to the type <code>UnitSIdRef</code> for all 1707 * Levels of SBML, even if the corresponding SBML specification did not 1708 * explicitly name the data type. 1709 <p> 1710 * This method works by looking at all unit identifier attribute values 1711 * (including, if appropriate, inside mathematical formulas), comparing the 1712 * referenced unit identifiers to the value of <code>oldid</code>. If any matches 1713 * are found, the matching values are replaced with <code>newid</code>. The method 1714 * does <em>not</em> descend into child elements. 1715 <p> 1716 * @param oldid the old identifier 1717 * @param newid the new identifier 1718 */ public 1719 void renameUnitSIdRefs(String oldid, String newid) { 1720 libsbmlJNI.Species_renameUnitSIdRefs(swigCPtr, this, oldid, newid); 1721 } 1722 1723}