001/* ---------------------------------------------------------------------------- 002 * This file was automatically generated by SWIG (http://www.swig.org). 003 * Version 3.0.10 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 * <span class="pkg-marker pkg-color-fbc"><a href="group__fbc.html">fbc</a></span> 013 A list of {@link Objective} objects. 014 <p> 015 * The {@link ListOfObjectives} is a container for the SBML extended {@link Model} 016 * that lists all the possible {@link Objective} elements in the model. 017 <p> 018 * Unlike most other {@link ListOf} subclasses in SBML, SBML Level 3 <a href='../../../extensions-summary.html#fbc'>Flux Balance Constraints</a> 019 * Version 2 defines an additional required attribute on 020 * ListOfObjectives: the 'activeObjective' attribute. This attribute is of 021 * type <code>SIdRef</code> and can only refer to the id of an existing 022 * {@link Objective}. This required attribute exists so that when multiple 023 * {@link Objective}'s are included in a single model, the model will always be well 024 * described; i.e., there will be a single, primary objective function which 025 * defines a single optimum and its associated solution space. 026 <p> 027 * <p> 028 * The various ListOf___ classes in SBML 029 * are merely containers used for organizing the main components of an SBML 030 * model. In libSBML's implementation, ListOf___ 031 * classes are derived from the 032 * intermediate utility class {@link ListOf}, which 033 * is not defined by the SBML specifications but serves as a useful 034 * programmatic construct. {@link ListOf} is itself is in turn derived from {@link SBase}, 035 * which provides all of the various ListOf___ 036 * classes with common features 037 * defined by the SBML specification, such as 'metaid' attributes and 038 * annotations. 039 <p> 040 * The relationship between the lists and the rest of an SBML model is 041 * illustrated by the following (for SBML Level 2 Version 4): 042 <p> 043 * <figure> 044 <object type="image/svg+xml" data="listof-illustration.svg" class="centered"></object> 045</figure> 046 047 <p> 048 * SBML Level 3 Version 1 has essentially the same structure as 049 * Level 2 Version 4, depicted above, but SBML Level 3 050 * Version 2 allows 051 * containers to contain zero or more of the relevant object, instead of 052 * requiring at least one. As such, libsbml will write out an 053 * otherwise-empty ListOf___ element that has any optional attribute set 054 * (such as 'id' or 'metaid'), that has an optional child (such 055 * as a 'notes' or 'annotation'), or that has attributes or children set 056 * from any SBML Level 3 package, whether or not the ListOf___ has 057 * any other children. 058 <p> 059 * Readers may wonder about the motivations for using the ListOf___ 060 * containers in SBML. A simpler approach in XML might be to place the 061 * components all directly at the top level of the model definition. The 062 * choice made in SBML is to group them within XML elements named after 063 * ListOf<em>Classname</em>, in part because it helps organize the 064 * components. More importantly, the fact that the container classes are 065 * derived from {@link SBase} means that software tools can add information <em>about</em> 066 * the lists themselves into each list container's 'annotation'. 067 <p> 068 * @see ListOfFunctionDefinitions 069 * @see ListOfUnitDefinitions 070 * @see ListOfCompartmentTypes 071 * @see ListOfSpeciesTypes 072 * @see ListOfCompartments 073 * @see ListOfSpecies 074 * @see ListOfParameters 075 * @see ListOfInitialAssignments 076 * @see ListOfRules 077 * @see ListOfConstraints 078 * @see ListOfReactions 079 * @see ListOfEvents 080 <p> 081 * 082 * @warning The required attribute 'activeObjective' on {@link ListOfObjectives} is 083 * an additional attribute that is not present on typical {@link ListOf} classes. 084 * The introduction of an attribute on {@link ListOf} is perfectly legal in SBML, but 085 * uncommon, and software developers may have grown accustomed to {@link ListOf} 086 * classes all having the same attributes and no others. We are belaboring 087 * this point so that developers are more likely to notice the presence of an 088 * additional attribute on {@link ListOfObjectives}. 089 <p> 090 * @see GeneProduct 091 * @see FbcModelPlugin 092 */ 093 094public class ListOfObjectives extends ListOf { 095 private long swigCPtr; 096 097 protected ListOfObjectives(long cPtr, boolean cMemoryOwn) 098 { 099 super(libsbmlJNI.ListOfObjectives_SWIGUpcast(cPtr), cMemoryOwn); 100 swigCPtr = cPtr; 101 } 102 103 protected static long getCPtr(ListOfObjectives obj) 104 { 105 return (obj == null) ? 0 : obj.swigCPtr; 106 } 107 108 protected static long getCPtrAndDisown (ListOfObjectives obj) 109 { 110 long ptr = 0; 111 112 if (obj != null) 113 { 114 ptr = obj.swigCPtr; 115 obj.swigCMemOwn = false; 116 } 117 118 return ptr; 119 } 120 121 protected void finalize() { 122 delete(); 123 } 124 125 public synchronized void delete() { 126 if (swigCPtr != 0) { 127 if (swigCMemOwn) { 128 swigCMemOwn = false; 129 libsbmlJNI.delete_ListOfObjectives(swigCPtr); 130 } 131 swigCPtr = 0; 132 } 133 super.delete(); 134 } 135 136 137/** 138 * Creates a new {@link ListOfObjectives} with the given SBML Level, Version, and 139 * “fbc”package version. 140 <p> 141 * @param level a long integer, the SBML Level to assign to this 142 * {@link ListOfObjectives}. 143 <p> 144 * @param version a long integer, the SBML Version to assign to this 145 * {@link ListOfObjectives}. 146 <p> 147 * @param pkgVersion a long integer, the SBML Fbc Version to assign to 148 * this {@link ListOfObjectives}. 149 <p> 150 * <p> 151 * @note Attempting to add an object to an {@link SBMLDocument} having a different 152 * combination of SBML Level, Version and XML namespaces than the object 153 * itself will result in an error at the time a caller attempts to make the 154 * addition. A parent object must have compatible Level, Version and XML 155 * namespaces. (Strictly speaking, a parent may also have more XML 156 * namespaces than a child, but the reverse is not permitted.) The 157 * restriction is necessary to ensure that an SBML model has a consistent 158 * overall structure. This requires callers to manage their objects 159 * carefully, but the benefit is increased flexibility in how models can be 160 * created by permitting callers to create objects bottom-up if desired. In 161 * situations where objects are not yet attached to parents (e.g., 162 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help 163 * libSBML determine such things as whether it is valid to assign a 164 * particular value to an attribute. For packages, this means that the 165 * parent object to which this package element is being added must have 166 * been created with the package namespace, or that the package namespace 167 * was added to it, even if that parent is not a package object itself. 168 */ public 169 ListOfObjectives(long level, long version, long pkgVersion) throws org.sbml.libsbml.SBMLConstructorException { 170 this(libsbmlJNI.new_ListOfObjectives__SWIG_0(level, version, pkgVersion), true); 171 } 172 173 174/** 175 * Creates a new {@link ListOfObjectives} with the given SBML Level, Version, and 176 * “fbc”package version. 177 <p> 178 * @param level a long integer, the SBML Level to assign to this 179 * {@link ListOfObjectives}. 180 <p> 181 * @param version a long integer, the SBML Version to assign to this 182 * {@link ListOfObjectives}. 183 <p> 184 * @param pkgVersion a long integer, the SBML Fbc Version to assign to 185 * this {@link ListOfObjectives}. 186 <p> 187 * <p> 188 * @note Attempting to add an object to an {@link SBMLDocument} having a different 189 * combination of SBML Level, Version and XML namespaces than the object 190 * itself will result in an error at the time a caller attempts to make the 191 * addition. A parent object must have compatible Level, Version and XML 192 * namespaces. (Strictly speaking, a parent may also have more XML 193 * namespaces than a child, but the reverse is not permitted.) The 194 * restriction is necessary to ensure that an SBML model has a consistent 195 * overall structure. This requires callers to manage their objects 196 * carefully, but the benefit is increased flexibility in how models can be 197 * created by permitting callers to create objects bottom-up if desired. In 198 * situations where objects are not yet attached to parents (e.g., 199 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help 200 * libSBML determine such things as whether it is valid to assign a 201 * particular value to an attribute. For packages, this means that the 202 * parent object to which this package element is being added must have 203 * been created with the package namespace, or that the package namespace 204 * was added to it, even if that parent is not a package object itself. 205 */ public 206 ListOfObjectives(long level, long version) throws org.sbml.libsbml.SBMLConstructorException { 207 this(libsbmlJNI.new_ListOfObjectives__SWIG_1(level, version), true); 208 } 209 210 211/** 212 * Creates a new {@link ListOfObjectives} with the given SBML Level, Version, and 213 * “fbc”package version. 214 <p> 215 * @param level a long integer, the SBML Level to assign to this 216 * {@link ListOfObjectives}. 217 <p> 218 * @param version a long integer, the SBML Version to assign to this 219 * {@link ListOfObjectives}. 220 <p> 221 * @param pkgVersion a long integer, the SBML Fbc Version to assign to 222 * this {@link ListOfObjectives}. 223 <p> 224 * <p> 225 * @note Attempting to add an object to an {@link SBMLDocument} having a different 226 * combination of SBML Level, Version and XML namespaces than the object 227 * itself will result in an error at the time a caller attempts to make the 228 * addition. A parent object must have compatible Level, Version and XML 229 * namespaces. (Strictly speaking, a parent may also have more XML 230 * namespaces than a child, but the reverse is not permitted.) The 231 * restriction is necessary to ensure that an SBML model has a consistent 232 * overall structure. This requires callers to manage their objects 233 * carefully, but the benefit is increased flexibility in how models can be 234 * created by permitting callers to create objects bottom-up if desired. In 235 * situations where objects are not yet attached to parents (e.g., 236 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help 237 * libSBML determine such things as whether it is valid to assign a 238 * particular value to an attribute. For packages, this means that the 239 * parent object to which this package element is being added must have 240 * been created with the package namespace, or that the package namespace 241 * was added to it, even if that parent is not a package object itself. 242 */ public 243 ListOfObjectives(long level) throws org.sbml.libsbml.SBMLConstructorException { 244 this(libsbmlJNI.new_ListOfObjectives__SWIG_2(level), true); 245 } 246 247 248/** 249 * Creates a new {@link ListOfObjectives} with the given SBML Level, Version, and 250 * “fbc”package version. 251 <p> 252 * @param level a long integer, the SBML Level to assign to this 253 * {@link ListOfObjectives}. 254 <p> 255 * @param version a long integer, the SBML Version to assign to this 256 * {@link ListOfObjectives}. 257 <p> 258 * @param pkgVersion a long integer, the SBML Fbc Version to assign to 259 * this {@link ListOfObjectives}. 260 <p> 261 * <p> 262 * @note Attempting to add an object to an {@link SBMLDocument} having a different 263 * combination of SBML Level, Version and XML namespaces than the object 264 * itself will result in an error at the time a caller attempts to make the 265 * addition. A parent object must have compatible Level, Version and XML 266 * namespaces. (Strictly speaking, a parent may also have more XML 267 * namespaces than a child, but the reverse is not permitted.) The 268 * restriction is necessary to ensure that an SBML model has a consistent 269 * overall structure. This requires callers to manage their objects 270 * carefully, but the benefit is increased flexibility in how models can be 271 * created by permitting callers to create objects bottom-up if desired. In 272 * situations where objects are not yet attached to parents (e.g., 273 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help 274 * libSBML determine such things as whether it is valid to assign a 275 * particular value to an attribute. For packages, this means that the 276 * parent object to which this package element is being added must have 277 * been created with the package namespace, or that the package namespace 278 * was added to it, even if that parent is not a package object itself. 279 */ public 280 ListOfObjectives() throws org.sbml.libsbml.SBMLConstructorException { 281 this(libsbmlJNI.new_ListOfObjectives__SWIG_3(), true); 282 } 283 284 285/** 286 * Creates a new {@link ListOfObjectives} with the given {@link FbcPkgNamespaces} object. 287 <p> 288 * <p> 289 * The package namespaces object used in this constructor is derived from a 290 * {@link SBMLNamespaces} object, which encapsulates SBML Level/Version/namespaces 291 * information. It is used to communicate the SBML Level, Version, and 292 * package version and name information used in addition to SBML Level 3 Core. A 293 * common approach to using libSBML's {@link SBMLNamespaces} facilities is to create an 294 * package namespace object somewhere in a program once, then hand that object 295 * as needed to object constructors of that package that accept it as and 296 * argument, such as this one. 297 <p> 298 * @param fbcns the {@link FbcPkgNamespaces} object. 299 <p> 300 * <p> 301 * @note Attempting to add an object to an {@link SBMLDocument} having a different 302 * combination of SBML Level, Version and XML namespaces than the object 303 * itself will result in an error at the time a caller attempts to make the 304 * addition. A parent object must have compatible Level, Version and XML 305 * namespaces. (Strictly speaking, a parent may also have more XML 306 * namespaces than a child, but the reverse is not permitted.) The 307 * restriction is necessary to ensure that an SBML model has a consistent 308 * overall structure. This requires callers to manage their objects 309 * carefully, but the benefit is increased flexibility in how models can be 310 * created by permitting callers to create objects bottom-up if desired. In 311 * situations where objects are not yet attached to parents (e.g., 312 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help 313 * libSBML determine such things as whether it is valid to assign a 314 * particular value to an attribute. For packages, this means that the 315 * parent object to which this package element is being added must have 316 * been created with the package namespace, or that the package namespace 317 * was added to it, even if that parent is not a package object itself. 318 */ public 319 ListOfObjectives(FbcPkgNamespaces fbcns) throws org.sbml.libsbml.SBMLConstructorException { 320 this(libsbmlJNI.new_ListOfObjectives__SWIG_4(FbcPkgNamespaces.getCPtr(fbcns), fbcns), true); 321 } 322 323 324/** 325 * Copy Constructor. 326 <p> 327 * @param other the instance to copy. 328 */ public 329 ListOfObjectives(ListOfObjectives other) throws org.sbml.libsbml.SBMLConstructorException { 330 this(libsbmlJNI.new_ListOfObjectives__SWIG_5(ListOfObjectives.getCPtr(other), other), true); 331 } 332 333 334/** 335 * Creates and returns a deep copy of this {@link ListOfObjectives} object. 336 <p> 337 * @return a (deep) copy of this {@link ListOfObjectives} object. 338 */ public 339 ListOfObjectives cloneObject() { 340 long cPtr = libsbmlJNI.ListOfObjectives_cloneObject(swigCPtr, this); 341 return (cPtr == 0) ? null : new ListOfObjectives(cPtr, true); 342 } 343 344 345/** 346 * Get an {@link Objective} from the {@link ListOfObjectives}. 347 <p> 348 * @param n the index number of the {@link Objective} to get. 349 <p> 350 * @return the nth {@link Objective} in this {@link ListOfObjectives}. 351 <p> 352 * @see #size() 353 */ public 354 Objective get(long n) { 355 long cPtr = libsbmlJNI.ListOfObjectives_get__SWIG_0(swigCPtr, this, n); 356 return (cPtr == 0) ? null : new Objective(cPtr, false); 357 } 358 359 360/** 361 * Get an {@link Objective} from the {@link ListOfObjectives} based on its identifier. 362 <p> 363 * @param sid a string representing the identifier of the {@link Objective} to get. 364 <p> 365 * @return {@link Objective} in this {@link ListOfObjectives} with the given id or null if 366 * no such {@link Objective} exists. 367 <p> 368 * @see #get(long n) 369 * @see #size() 370 */ public 371 Objective get(String sid) { 372 long cPtr = libsbmlJNI.ListOfObjectives_get__SWIG_2(swigCPtr, this, sid); 373 return (cPtr == 0) ? null : new Objective(cPtr, false); 374 } 375 376 377/** 378 * Adds a copy the given {@link Objective} to this {@link ListOfObjectives}. 379 <p> 380 * @param o the {@link Objective} object to add. 381 <p> 382 * <p> 383 * @return integer value indicating success/failure of the 384 * function. The possible values 385 * returned by this function are: 386 * <ul> 387 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 388 * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE} 389 * </ul> 390 */ public 391 int addObjective(Objective o) { 392 return libsbmlJNI.ListOfObjectives_addObjective(swigCPtr, this, Objective.getCPtr(o), o); 393 } 394 395 396/** 397 * Get the number of {@link Objective} objects in this {@link ListOfObjectives}. 398 <p> 399 * @return the number of {@link Objective} objects in this {@link ListOfObjectives}. 400 */ public 401 long getNumObjectives() { 402 return libsbmlJNI.ListOfObjectives_getNumObjectives(swigCPtr, this); 403 } 404 405 406/** 407 * Creates a new {@link Objective} object, adds it to the 408 * {@link ListOfObjectives} and returns the {@link Objective} object created. 409 <p> 410 * @return a new {@link Objective} object instance. 411 <p> 412 * @see #addObjective(Objective o) 413 */ public 414 Objective createObjective() { 415 long cPtr = libsbmlJNI.ListOfObjectives_createObjective(swigCPtr, this); 416 return (cPtr == 0) ? null : new Objective(cPtr, false); 417 } 418 419 420/** 421 * Removes the nth {@link Objective} from this {@link ListOfObjectives} 422 * and returns a pointer to it. 423 <p> 424 * The caller owns the returned item and is responsible for deleting it. 425 <p> 426 * @param n the index of the {@link Objective} to remove. 427 <p> 428 * @see #size() 429 */ public 430 Objective remove(long n) { 431 long cPtr = libsbmlJNI.ListOfObjectives_remove__SWIG_0(swigCPtr, this, n); 432 return (cPtr == 0) ? null : new Objective(cPtr, true); 433 } 434 435 436/** 437 * Removes the {@link Objective} from this {@link ListOfObjectives} with the given identifier 438 * and returns a pointer to it. 439 <p> 440 * The caller owns the returned item and is responsible for deleting it. 441 * If none of the items in this list have the identifier <code>sid</code>, then 442 * <code>null</code> is returned. 443 <p> 444 * @param sid the identifier of the {@link Objective} to remove. 445 <p> 446 * @return the {@link Objective} removed. As mentioned above, the caller owns the 447 * returned item. 448 */ public 449 Objective remove(String sid) { 450 long cPtr = libsbmlJNI.ListOfObjectives_remove__SWIG_1(swigCPtr, this, sid); 451 return (cPtr == 0) ? null : new Objective(cPtr, true); 452 } 453 454 455/** 456 * Returns the XML element name of this object. 457 <p> 458 * For {@link ListOfObjectives}, the XML element name is always <code>'listOfObjectives'.</code> 459 <p> 460 * @return the name of this element, i.e. <code>'listOfObjectives'.</code> 461 */ public 462 String getElementName() { 463 return libsbmlJNI.ListOfObjectives_getElementName(swigCPtr, this); 464 } 465 466 467/** 468 * Predicate returning <code>true</code> if this ListOfObjective's 'activeObjective' 469 * attribute is set. 470 <p> 471 * @return <code>true</code> if this ListOfObjective's 'activeObjective' attribute has been set, 472 * otherwise <code>false</code> is returned. 473 */ public 474 boolean isSetActiveObjective() { 475 return libsbmlJNI.ListOfObjectives_isSetActiveObjective(swigCPtr, this); 476 } 477 478 479/** 480 * Sets the value of the 'activeObjective' attribute of this {@link ListOfObjectives}. 481 <p> 482 * <p> 483 * @return integer value indicating success/failure of the 484 * function. The possible values 485 * returned by this function are: 486 * <ul> 487 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 488 * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE} 489 * </ul> 490 */ public 491 int setActiveObjective(String activeObjective) { 492 return libsbmlJNI.ListOfObjectives_setActiveObjective(swigCPtr, this, activeObjective); 493 } 494 495 496/** 497 * Returns the value of the 'activeObjective' attribute of this {@link ListOfObjectives}. 498 <p> 499 * @return the value of the 'activeObjective' attribute of this {@link ListOfObjectives}. 500 */ public 501 String getActiveObjective() { 502 return libsbmlJNI.ListOfObjectives_getActiveObjective(swigCPtr, this); 503 } 504 505 506/** 507 * Unsets the value of the 'activeObjective' attribute of this {@link ListOfObjectives}. 508 <p> 509 * <p> 510 * @return integer value indicating success/failure of the 511 * function. The possible values 512 * returned by this function are: 513 * <ul> 514 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS} 515 * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED} 516 * </ul> 517 */ public 518 int unsetActiveObjective() { 519 return libsbmlJNI.ListOfObjectives_unsetActiveObjective(swigCPtr, this); 520 } 521 522 523/** 524 * Returns the libSBML type code for this SBML object. 525 <p> 526 * <p> 527 * LibSBML attaches an identifying code to every kind of SBML object. These 528 * are integer constants known as <em>SBML type codes</em>. The names of all 529 * the codes begin with the characters <code>SBML_</code>. 530 * In the Java language interface for libSBML, the 531 * type codes are defined as static integer constants in the interface class 532 * {@link libsbmlConstants}. Note that different Level 3 533 * package plug-ins may use overlapping type codes; to identify the package 534 * to which a given object belongs, call the <code>getPackageName()</code> 535 * method on the object. 536 <p> 537 * @return the SBML type code for this object: 538 * {@link libsbmlConstants#SBML_LIST_OF SBML_LIST_OF} (default). 539 <p> 540 * <p> 541 * @warning <span class='warning'>The specific integer values of the possible 542 * type codes may be reused by different libSBML plug-ins for SBML Level 3. 543 * packages, To fully identify the correct code, <strong>it is necessary to 544 * invoke both getTypeCode() and getPackageName()</strong>.</span> 545 <p> 546 * @see #getElementName() 547 * @see #getPackageName() 548 */ public 549 int getTypeCode() { 550 return libsbmlJNI.ListOfObjectives_getTypeCode(swigCPtr, this); 551 } 552 553 554/** 555 * Returns the libSBML type code for the objects contained in this {@link ListOf}. 556 <p> 557 * <p> 558 * LibSBML attaches an identifying code to every kind of SBML object. These 559 * are integer constants known as <em>SBML type codes</em>. The names of all 560 * the codes begin with the characters <code>SBML_</code>. 561 * In the Java language interface for libSBML, the 562 * type codes are defined as static integer constants in the interface class 563 * {@link libsbmlConstants}. Note that different Level 3 564 * package plug-ins may use overlapping type codes; to identify the package 565 * to which a given object belongs, call the <code>getPackageName()</code> 566 * method on the object. 567 <p> 568 * @return the SBML type code for the objects contained in this {@link ListOf} 569 * instance: {@link libsbmlConstants#SBML_FBC_OBJECTIVE SBML_FBC_OBJECTIVE} (default). 570 <p> 571 * @see #getElementName() 572 * @see #getPackageName() 573 */ public 574 int getItemTypeCode() { 575 return libsbmlJNI.ListOfObjectives_getItemTypeCode(swigCPtr, this); 576 } 577 578 579/** 580 * Adds a clone of all items in the provided {@link ListOf} to this object. 581 <p> 582 * This means that when this {@link ListOf} is destroyed, the original items will 583 * not be destroyed. In addition, copy over the input {@link ListOfObjectives}' 584 * 'activeObjective' attribute, if none is set for this element. 585 <p> 586 * @param list a list of items to be added. 587 <p> 588 * @see #append(SBase item) 589 */ public 590 int appendFrom(ListOf list) { 591 return libsbmlJNI.ListOfObjectives_appendFrom(swigCPtr, this, ListOf.getCPtr(list), list); 592 } 593 594 595/** 596 * <p> 597 * Replaces all uses of a given <code>SIdRef</code> type attribute value with another 598 * value. 599 <p> 600 * <p> 601 * In SBML, object identifiers are of a data type called <code>SId</code>. 602 * In SBML Level 3, an explicit data type called <code>SIdRef</code> was 603 * introduced for attribute values that refer to <code>SId</code> values; in 604 * previous Levels of SBML, this data type did not exist and attributes were 605 * simply described to as 'referring to an identifier', but the effective 606 * data type was the same as <code>SIdRef</code> in Level 3. These and 607 * other methods of libSBML refer to the type <code>SIdRef</code> for all 608 * Levels of SBML, even if the corresponding SBML specification did not 609 * explicitly name the data type. 610 <p> 611 * This method works by looking at all attributes and (if appropriate) 612 * mathematical formulas in MathML content, comparing the referenced 613 * identifiers to the value of <code>oldid</code>. If any matches are found, the 614 * matching values are replaced with <code>newid</code>. The method does <em>not</em> 615 * descend into child elements. 616 <p> 617 * @param oldid the old identifier. 618 * @param newid the new identifier. 619 */ public 620 void renameSIdRefs(String oldid, String newid) { 621 libsbmlJNI.ListOfObjectives_renameSIdRefs(swigCPtr, this, oldid, newid); 622 } 623 624}