001/* ----------------------------------------------------------------------------
002 * This file was automatically generated by SWIG (http://www.swig.org).
003 * Version 2.0.12
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 *  Implementation of SBML's KineticLaw construct.
013 <p>
014 * An object of class {@link KineticLaw} is used to describe the rate at which the
015 * process defined by a given {@link Reaction} takes place.  {@link KineticLaw} has
016 * subelements called 'math' (for MathML content) and 'listOfParameters'
017 * (of class {@link ListOfParameters}), in addition to the attributes and
018 * subelements it inherits from {@link SBase}.
019 <p>
020 * {@link KineticLaw}'s 'math' subelement for holding a MathML formula defines the
021 * rate of the reaction.  The formula may refer to other entities in a
022 * model as well as local parameter definitions within the scope of the
023 * {@link Reaction} (see below).  It is important to keep in mind, however, that
024 * the only {@link Species} identifiers that can be used in this formula are those
025 * declared in the lists of reactants, products and modifiers in the
026 * {@link Reaction} structure.  (In other words, before a species can be referenced
027 * in the {@link KineticLaw}, it must be declared in one of those lists.)
028 <p>
029 * {@link KineticLaw} provides a way to define <em>local</em> parameters whose
030 * identifiers can be used in the 'math' formula of that {@link KineticLaw}
031 * instance.  Prior to SBML Level&nbsp;3, these parameter definitions are
032 * stored inside a 'listOfParameters' subelement containing {@link Parameter}
033 * objects; in SBML Level&nbsp;3, this is achieved using a specialized
034 * object class called {@link LocalParameter} and the containing subelement is
035 * called 'listOfLocalParameters'.  In both cases, the parameters so
036 * defined are only visible within the {@link KineticLaw}; they cannot be accessed
037 * outside.  A local parameter within one reaction is not visible from
038 * within another reaction, nor is it visible to any other construct
039 * outside of the {@link KineticLaw} in which it is defined.  In addition, another
040 * important feature is that if such a {@link Parameter} (or in Level&nbsp;3,
041 * {@link LocalParameter}) object has the same identifier as another object in the
042 * scope of the enclosing {@link Model}, the definition inside the {@link KineticLaw} takes
043 * precedence.  In other words, within the {@link KineticLaw}'s 'math' formula,
044 * references to local parameter identifiers <strong>shadow any identical
045 * global identifiers</strong>.
046 <p>
047 * The values of local parameters defined within {@link KineticLaw} objects cannot
048 * change.  In SBML Level&nbsp;3, this quality is built into the
049 * {@link LocalParameter} construct.  In Level&nbsp;2, where the same kind of
050 * {@link Parameter} object class is used as for global parameters, the {@link Parameter}
051 * objects' 'constant' attribute must always have a value of <code>true</code>
052 * (either explicitly or left to its default value).
053 <p>
054 <p>
055 * <h2>A warning about identifier shadowing</h2>
056 <p>
057 * A common misconception is that different classes of objects (e.g.,
058 * species, compartments, parameters) in SBML have different identifier
059 * scopes.  They do not.  The implication is that if a {@link KineticLaw}'s local
060 * parameter definition uses an identifier identical to <em>any</em> other
061 * identifier defined in the model outside the {@link KineticLaw}, even if the
062 * other identifier does <em>not</em> belong to a parameter type of object, the
063 * local parameter's identifier takes precedence within that {@link KineticLaw}'s
064 * 'math' formula.  It is not an error in SBML for identifiers to shadow
065 * each other this way, but can lead to confusing and subtle errors.
066 <p>
067 <p>
068 * <h2>SBML Level/Version differences</h2>
069 <p>
070 * In SBML Level&nbsp;2 Version&nbsp;1, the SBML specification
071 * included two additional attributes on {@link KineticLaw} called 'substanceUnits'
072 * and 'timeUnits'.  They were removed beginning with SBML Level&nbsp;2
073 * Version&nbsp;2 because further research determined they introduced many
074 * problems.  The most significant problem was that their use could easily
075 * lead to the creation of valid models whose reactions nevertheless could
076 * not be integrated into a system of equations without outside knowledge
077 * for converting the quantities used.  Examination of real-life models
078 * revealed that a common reason for using 'substanceUnits' on {@link KineticLaw}
079 * was to set the units of all reactions to the same set of substance
080 * units, something that is better achieved by using {@link UnitDefinition} to
081 * redefine <code>'substance'</code> for the whole {@link Model}.
082 <p>
083 * As mentioned above, in SBML Level&nbsp;2 Versions 2&ndash;4, local
084 * parameters are of class {@link Parameter}.  In SBML Level&nbsp;3, the class of
085 * object is {@link LocalParameter}.
086 */
087
088public class KineticLaw extends SBase {
089   private long swigCPtr;
090
091   protected KineticLaw(long cPtr, boolean cMemoryOwn)
092   {
093     super(libsbmlJNI.KineticLaw_SWIGUpcast(cPtr), cMemoryOwn);
094     swigCPtr = cPtr;
095   }
096
097   protected static long getCPtr(KineticLaw obj)
098   {
099     return (obj == null) ? 0 : obj.swigCPtr;
100   }
101
102   protected static long getCPtrAndDisown (KineticLaw obj)
103   {
104     long ptr = 0;
105
106     if (obj != null)
107     {
108       ptr             = obj.swigCPtr;
109       obj.swigCMemOwn = false;
110     }
111
112     return ptr;
113   }
114
115  protected void finalize() {
116    delete();
117  }
118
119  public synchronized void delete() {
120    if (swigCPtr != 0) {
121      if (swigCMemOwn) {
122        swigCMemOwn = false;
123        libsbmlJNI.delete_KineticLaw(swigCPtr);
124      }
125      swigCPtr = 0;
126    }
127    super.delete();
128  }
129
130  
131/**
132   * Creates a new {@link KineticLaw} using the given SBML <code>level</code> and <code>version</code>
133   * values.
134   <p>
135   * @param level a long integer, the SBML Level to assign to this {@link KineticLaw}
136   <p>
137   * @param version a long integer, the SBML Version to assign to this
138   * {@link KineticLaw}
139   <p>
140   * @throws SBMLConstructorException 
141   * Thrown if the given <code>level</code> and <code>version</code> combination, or this kind
142   * of SBML object, are either invalid or mismatched with respect to the
143   * parent {@link SBMLDocument} object.
144   <p>
145   * <p>
146 * @note Upon the addition of a {@link KineticLaw} object to an {@link SBMLDocument} (e.g.,
147 * using {@link Reaction#setKineticLaw(KineticLaw kl)}), the SBML
148 * Level, SBML Version and XML namespace of the document <em>override</em> the
149 * values used when creating the {@link KineticLaw} object via this constructor.
150 * This is necessary to ensure that an SBML document is a consistent
151 * structure.  Nevertheless, the ability to supply the values at the time of
152 * creation of a {@link KineticLaw} is an important aid to producing valid SBML.
153 * Knowledge of the intented SBML Level and Version determine whether it is
154 * valid to assign a particular value to an attribute, or whether it is valid
155 * to add an object to an existing {@link SBMLDocument}.
156   */ public
157 KineticLaw(long level, long version) throws org.sbml.libsbml.SBMLConstructorException {
158    this(libsbmlJNI.new_KineticLaw__SWIG_0(level, version), true);
159  }
160
161  
162/**
163   * Creates a new {@link KineticLaw} using the given {@link SBMLNamespaces} object
164   * <code>sbmlns</code>.
165   <p>
166   * <p>
167 * The {@link SBMLNamespaces} object encapsulates SBML Level/Version/namespaces
168 * information.  It is used to communicate the SBML Level, Version, and (in
169 * Level&nbsp;3) packages used in addition to SBML Level&nbsp;3 Core.  A
170 * common approach to using libSBML's {@link SBMLNamespaces} facilities is to create an
171 * {@link SBMLNamespaces} object somewhere in a program once, then hand that object
172 * as needed to object constructors that accept {@link SBMLNamespaces} as arguments.
173   <p>
174   * @param sbmlns an {@link SBMLNamespaces} object.
175   <p>
176   * @throws SBMLConstructorException 
177   * Thrown if the given <code>level</code> and <code>version</code> combination, or this kind
178   * of SBML object, are either invalid or mismatched with respect to the
179   * parent {@link SBMLDocument} object.
180   <p>
181   * <p>
182 * @note Upon the addition of a {@link KineticLaw} object to an {@link SBMLDocument} (e.g.,
183 * using {@link Reaction#setKineticLaw(KineticLaw kl)}), the SBML
184 * Level, SBML Version and XML namespace of the document <em>override</em> the
185 * values used when creating the {@link KineticLaw} object via this constructor.
186 * This is necessary to ensure that an SBML document is a consistent
187 * structure.  Nevertheless, the ability to supply the values at the time of
188 * creation of a {@link KineticLaw} is an important aid to producing valid SBML.
189 * Knowledge of the intented SBML Level and Version determine whether it is
190 * valid to assign a particular value to an attribute, or whether it is valid
191 * to add an object to an existing {@link SBMLDocument}.
192   */ public
193 KineticLaw(SBMLNamespaces sbmlns) throws org.sbml.libsbml.SBMLConstructorException {
194    this(libsbmlJNI.new_KineticLaw__SWIG_1(SBMLNamespaces.getCPtr(sbmlns), sbmlns), true);
195  }
196
197  
198/**
199   * Copy constructor; creates a copy of this {@link KineticLaw}.
200   <p>
201   * @param orig the object to copy.
202   <p>
203   * @throws SBMLConstructorException 
204   * Thrown if the argument <code>orig</code> is <code>null.</code>
205   */ public
206 KineticLaw(KineticLaw orig) throws org.sbml.libsbml.SBMLConstructorException {
207    this(libsbmlJNI.new_KineticLaw__SWIG_2(KineticLaw.getCPtr(orig), orig), true);
208  }
209
210  
211/**
212   * Creates and returns a deep copy of this {@link KineticLaw} object.
213   <p>
214   * @return a (deep) copy of this {@link KineticLaw}.
215   */ public
216 KineticLaw cloneObject() {
217    long cPtr = libsbmlJNI.KineticLaw_cloneObject(swigCPtr, this);
218    return (cPtr == 0) ? null : new KineticLaw(cPtr, true);
219  }
220
221  
222/**
223   * Returns the first child element found that has the given <code>id</code> in the
224   * model-wide SId namespace, or <code>null</code> if no such object is found.
225   <p>
226   * @param id string representing the id of objects to find.
227   <p>
228   * @return pointer to the first element found with the given <code>id</code>.
229   */ public
230 SBase getElementBySId(String id) {
231  return libsbml.DowncastSBase(libsbmlJNI.KineticLaw_getElementBySId(swigCPtr, this, id), false);
232}
233
234  
235/**
236   * Returns the first child element it can find with the given <code>metaid</code>, or
237   * <code>null</code> if no such object is found.
238   <p>
239   * @param metaid string representing the metaid of objects to find
240   <p>
241   * @return pointer to the first element found with the given <code>metaid</code>.
242   */ public
243 SBase getElementByMetaId(String metaid) {
244  return libsbml.DowncastSBase(libsbmlJNI.KineticLaw_getElementByMetaId(swigCPtr, this, metaid), false);
245}
246
247  
248/**
249   * Returns the mathematical formula for this {@link KineticLaw} object and return
250   * it as as a text string.
251   <p>
252   * This is fundamentally equivalent to
253   * {@link KineticLaw#getMath()}.
254   * This variant is provided principally for compatibility compatibility
255   * with SBML Level&nbsp;1.
256   <p>
257   * @return a string representing the formula of this {@link KineticLaw}.
258   <p>
259   * @note SBML Level&nbsp;1 uses a text-string format for mathematical formulas.
260SBML Level&nbsp;2 uses MathML, an XML format for representing mathematical
261expressions.  LibSBML provides an Abstract Syntax Tree API for working with
262mathematical expressions; this API is more powerful than working with
263formulas directly in text form, and ASTs can be translated into either
264MathML or the text-string syntax.  The libSBML methods that accept
265text-string formulas directly (such as this constructor) are provided for
266SBML Level&nbsp;1 compatibility, but developers are encouraged to use the
267AST mechanisms.
268
269   <p>
270   * @see #getMath()
271   */ public
272 String getFormula() {
273    return libsbmlJNI.KineticLaw_getFormula(swigCPtr, this);
274  }
275
276  
277/**
278   * Returns the mathematical formula for this {@link KineticLaw} object and return
279   * it as as an AST.
280   <p>
281   * This is fundamentally equivalent to
282   * {@link KineticLaw#getFormula()}.
283   * The latter is provided principally for compatibility compatibility
284   * with SBML Level&nbsp;1, which represented mathematical formulas in
285   * text-string form.
286   <p>
287   * @return the {@link ASTNode} representation of the mathematical formula.
288   <p>
289   * @see #getFormula()
290   */ public
291 ASTNode getMath() {
292    long cPtr = libsbmlJNI.KineticLaw_getMath(swigCPtr, this);
293    return (cPtr == 0) ? null : new ASTNode(cPtr, false);
294  }
295
296  
297/**
298   * (SBML Level&nbsp;2 Version&nbsp;1 only) Returns the value of the
299   * 'timeUnits' attribute of this {@link KineticLaw} object.
300   <p>
301   * @return the 'timeUnits' attribute value.
302   <p>
303   * <p>
304 * @note The attributes 'timeUnits' and 'substanceUnits' are present only
305 * in SBML Level&nbsp;2 Version&nbsp;1.  In SBML Level&nbsp;2
306 * Version&nbsp;2, the 'timeUnits' and 'substanceUnits' attributes were
307 * removed.  For compatibility with new versions of SBML, users are
308 * cautioned to avoid these attributes. 
309   */ public
310 String getTimeUnits() {
311    return libsbmlJNI.KineticLaw_getTimeUnits(swigCPtr, this);
312  }
313
314  
315/**
316   * (SBML Level&nbsp;2 Version&nbsp;1 only) Returns the value of the
317   * 'substanceUnits' attribute of this {@link KineticLaw} object.
318   <p>
319   * @return the 'substanceUnits' attribute value.
320   <p>
321   * <p>
322 * @note The attributes 'timeUnits' and 'substanceUnits' are present only
323 * in SBML Level&nbsp;2 Version&nbsp;1.  In SBML Level&nbsp;2
324 * Version&nbsp;2, the 'timeUnits' and 'substanceUnits' attributes were
325 * removed.  For compatibility with new versions of SBML, users are
326 * cautioned to avoid these attributes. 
327   */ public
328 String getSubstanceUnits() {
329    return libsbmlJNI.KineticLaw_getSubstanceUnits(swigCPtr, this);
330  }
331
332  
333/**
334   * Predicate returning <code>true</code> if this {@link KineticLaw}'s 'formula' attribute is
335   * set.
336   <p>
337   * This is functionally identical to the method
338   * {@link KineticLaw#isSetMath()}.  It is
339   * provided in order to mirror the parallel between
340   * {@link KineticLaw#getFormula()} and
341   * {@link KineticLaw#getMath()}.
342   <p>
343   * @return <code>true</code> if the formula (meaning the <code>math</code> subelement) of
344   * this {@link KineticLaw} is set, <code>false</code> otherwise.
345   <p>
346   * @note SBML Level&nbsp;1 uses a text-string format for mathematical formulas.
347SBML Level&nbsp;2 uses MathML, an XML format for representing mathematical
348expressions.  LibSBML provides an Abstract Syntax Tree API for working with
349mathematical expressions; this API is more powerful than working with
350formulas directly in text form, and ASTs can be translated into either
351MathML or the text-string syntax.  The libSBML methods that accept
352text-string formulas directly (such as this constructor) are provided for
353SBML Level&nbsp;1 compatibility, but developers are encouraged to use the
354AST mechanisms.
355
356   <p>
357   * @see #isSetMath()
358   */ public
359 boolean isSetFormula() {
360    return libsbmlJNI.KineticLaw_isSetFormula(swigCPtr, this);
361  }
362
363  
364/**
365   * Predicate returning <code>true</code> if this Kinetic's 'math' subelement is set.
366   <p>
367   * This is identical to the method
368   * {@link KineticLaw#isSetFormula()}.
369   * It is provided in order to mirror the parallel between
370   * {@link KineticLaw#getFormula()} and
371   * {@link KineticLaw#getMath()}.
372   <p>
373   * @return <code>true</code> if the formula (meaning the <code>math</code> subelement) of
374   * this {@link KineticLaw} is set, <code>false</code> otherwise.
375   <p>
376   * @see #isSetFormula()
377   */ public
378 boolean isSetMath() {
379    return libsbmlJNI.KineticLaw_isSetMath(swigCPtr, this);
380  }
381
382  
383/**
384   * (SBML Level&nbsp;2 Version&nbsp;1 only) Predicate returning <code>true</code> if
385   * this {@link SpeciesReference}'s 'timeUnits' attribute is set.
386   <p>
387   * @return <code>true</code> if the 'timeUnits' attribute of this {@link KineticLaw} object
388   * is set, <code>false</code> otherwise.
389   <p>
390   * <p>
391 * @note The attributes 'timeUnits' and 'substanceUnits' are present only
392 * in SBML Level&nbsp;2 Version&nbsp;1.  In SBML Level&nbsp;2
393 * Version&nbsp;2, the 'timeUnits' and 'substanceUnits' attributes were
394 * removed.  For compatibility with new versions of SBML, users are
395 * cautioned to avoid these attributes. 
396   */ public
397 boolean isSetTimeUnits() {
398    return libsbmlJNI.KineticLaw_isSetTimeUnits(swigCPtr, this);
399  }
400
401  
402/**
403   * (SBML Level&nbsp;2 Version&nbsp;1 only) Predicate returning <code>true</code> if
404   * this {@link SpeciesReference}'s 'substanceUnits' attribute is set.
405   <p>
406   * @return <code>true</code> if the 'substanceUnits' attribute of this {@link KineticLaw}
407   * object is set, <code>false</code> otherwise.
408   <p>
409   * <p>
410 * @note The attributes 'timeUnits' and 'substanceUnits' are present only
411 * in SBML Level&nbsp;2 Version&nbsp;1.  In SBML Level&nbsp;2
412 * Version&nbsp;2, the 'timeUnits' and 'substanceUnits' attributes were
413 * removed.  For compatibility with new versions of SBML, users are
414 * cautioned to avoid these attributes. 
415   */ public
416 boolean isSetSubstanceUnits() {
417    return libsbmlJNI.KineticLaw_isSetSubstanceUnits(swigCPtr, this);
418  }
419
420  
421/**
422   * Sets the mathematical expression of this {@link KineticLaw} instance to the
423   * given <code>formula</code>.
424   <p>
425   * The given <code>formula</code> string is copied.  Internally, libSBML stores the
426   * mathematical expression as an {@link ASTNode}.
427   <p>
428   * @param formula the mathematical expression to use, represented in
429   * text-string form.
430   <p>
431   * @return integer value indicating success/failure of the
432   * function. The possible values
433   * returned by this function are:
434   * <ul>
435   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS }
436   * <li> {@link  libsbmlConstants#LIBSBML_INVALID_OBJECT LIBSBML_INVALID_OBJECT }
437   *
438   * </ul> <p>
439   * @note SBML Level&nbsp;1 uses a text-string format for mathematical formulas.
440SBML Level&nbsp;2 uses MathML, an XML format for representing mathematical
441expressions.  LibSBML provides an Abstract Syntax Tree API for working with
442mathematical expressions; this API is more powerful than working with
443formulas directly in text form, and ASTs can be translated into either
444MathML or the text-string syntax.  The libSBML methods that accept
445text-string formulas directly (such as this constructor) are provided for
446SBML Level&nbsp;1 compatibility, but developers are encouraged to use the
447AST mechanisms.
448
449   <p>
450   * @see #setMath(ASTNode math)
451   */ public
452 int setFormula(String formula) {
453    return libsbmlJNI.KineticLaw_setFormula(swigCPtr, this, formula);
454  }
455
456  
457/**
458   * Sets the mathematical expression of this {@link KineticLaw} instance to a copy
459   * of the given {@link ASTNode}.
460   <p>
461   * This is fundamentally identical to
462   * {@link KineticLaw#setFormula(String formula)}.
463   * The latter is provided principally for compatibility compatibility with
464   * SBML Level&nbsp;1, which represented mathematical formulas in text-string
465   * form.
466   <p>
467   * @param math an {@link ASTNode} representing a formula tree.
468   <p>
469   * @return integer value indicating success/failure of the
470   * function. The possible values
471   * returned by this function are:
472   * <ul>
473   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS }
474   * <li> {@link  libsbmlConstants#LIBSBML_INVALID_OBJECT LIBSBML_INVALID_OBJECT }
475   *
476   * </ul> <p>
477   * @see #setFormula(String formula)
478   */ public
479 int setMath(ASTNode math) {
480    return libsbmlJNI.KineticLaw_setMath(swigCPtr, this, ASTNode.getCPtr(math), math);
481  }
482
483  
484/**
485   * (SBML Level&nbsp;2 Version&nbsp;1 only) Sets the 'timeUnits' attribute
486   * of this {@link KineticLaw} object to a copy of the identifier in <code>sid</code>.
487   <p>
488   * @param sid the identifier of the units to use.
489   <p>
490   * @return integer value indicating success/failure of the
491   * function. The possible values
492   * returned by this function are:
493   * <ul>
494   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS }
495   * <li> {@link  libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE }
496   * <li> {@link  libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE }
497   *
498   * </ul> <p>
499   * <p>
500 * @note The attributes 'timeUnits' and 'substanceUnits' are present only
501 * in SBML Level&nbsp;2 Version&nbsp;1.  In SBML Level&nbsp;2
502 * Version&nbsp;2, the 'timeUnits' and 'substanceUnits' attributes were
503 * removed.  For compatibility with new versions of SBML, users are
504 * cautioned to avoid these attributes. 
505   */ public
506 int setTimeUnits(String sid) {
507    return libsbmlJNI.KineticLaw_setTimeUnits(swigCPtr, this, sid);
508  }
509
510  
511/**
512   * (SBML Level&nbsp;2 Version&nbsp;1 only) Sets the 'substanceUnits'
513   * attribute of this {@link KineticLaw} object to a copy of the identifier given
514   * in <code>sid</code>.
515   <p>
516   * @param sid the identifier of the units to use.
517   <p>
518   * @return integer value indicating success/failure of the
519   * function. The possible values
520   * returned by this function are:
521   * <ul>
522   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS }
523   * <li> {@link  libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE }
524   * <li> {@link  libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE }
525   *
526   * </ul> <p>
527   * <p>
528 * @note The attributes 'timeUnits' and 'substanceUnits' are present only
529 * in SBML Level&nbsp;2 Version&nbsp;1.  In SBML Level&nbsp;2
530 * Version&nbsp;2, the 'timeUnits' and 'substanceUnits' attributes were
531 * removed.  For compatibility with new versions of SBML, users are
532 * cautioned to avoid these attributes. 
533   */ public
534 int setSubstanceUnits(String sid) {
535    return libsbmlJNI.KineticLaw_setSubstanceUnits(swigCPtr, this, sid);
536  }
537
538  
539/**
540   * (SBML Level&nbsp;2 Version&nbsp;1 only) Unsets the 'timeUnits'
541   * attribugte of this {@link KineticLaw} object.
542   <p>
543   * @return integer value indicating success/failure of the
544   * function. The possible values
545   * returned by this function are:
546   * <ul>
547   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS }
548   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED }
549   * <li> {@link  libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE }
550   *
551   * </ul> <p>
552   * <p>
553 * @note The attributes 'timeUnits' and 'substanceUnits' are present only
554 * in SBML Level&nbsp;2 Version&nbsp;1.  In SBML Level&nbsp;2
555 * Version&nbsp;2, the 'timeUnits' and 'substanceUnits' attributes were
556 * removed.  For compatibility with new versions of SBML, users are
557 * cautioned to avoid these attributes. 
558   */ public
559 int unsetTimeUnits() {
560    return libsbmlJNI.KineticLaw_unsetTimeUnits(swigCPtr, this);
561  }
562
563  
564/**
565   * (SBML Level&nbsp;2 Version&nbsp;1 only) Unsets the 'substanceUnits'
566   * attribute of this {@link KineticLaw} object.
567   <p>
568   * @return integer value indicating success/failure of the
569   * function. The possible values
570   * returned by this function are:
571   * <ul>
572   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS }
573   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED }
574   * <li> {@link  libsbmlConstants#LIBSBML_UNEXPECTED_ATTRIBUTE LIBSBML_UNEXPECTED_ATTRIBUTE }
575   *
576   * </ul> <p>
577   * <p>
578 * @note The attributes 'timeUnits' and 'substanceUnits' are present only
579 * in SBML Level&nbsp;2 Version&nbsp;1.  In SBML Level&nbsp;2
580 * Version&nbsp;2, the 'timeUnits' and 'substanceUnits' attributes were
581 * removed.  For compatibility with new versions of SBML, users are
582 * cautioned to avoid these attributes. 
583   */ public
584 int unsetSubstanceUnits() {
585    return libsbmlJNI.KineticLaw_unsetSubstanceUnits(swigCPtr, this);
586  }
587
588  
589/**
590   * Adds a copy of the given {@link Parameter} object to the list of local
591   * parameters in this {@link KineticLaw}.
592   <p>
593   * @param p the {@link Parameter} to add
594   <p>
595   * @return integer value indicating success/failure of the
596   * function. The possible values
597   * returned by this function are:
598   * <ul>
599   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS }
600   * <li> {@link  libsbmlConstants#LIBSBML_LEVEL_MISMATCH LIBSBML_LEVEL_MISMATCH }
601   * <li> {@link  libsbmlConstants#LIBSBML_VERSION_MISMATCH LIBSBML_VERSION_MISMATCH }
602   * <li> {@link  libsbmlConstants#LIBSBML_DUPLICATE_OBJECT_ID LIBSBML_DUPLICATE_OBJECT_ID }
603   * <li> {@link  libsbmlConstants#LIBSBML_INVALID_OBJECT LIBSBML_INVALID_OBJECT }
604   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED }
605   *
606   * </ul> <p>
607   * <p>
608 * @note This method should be used with some caution.  The fact that this
609 * method <em>copies</em> the object passed to it means that the caller will be
610 * left holding a physically different object instance than the one contained
611 * inside this object.  Changes made to the original object instance (such as
612 * resetting attribute values) will <em>not affect the instance in this
613 * object</em>.  In addition, the caller should make sure to free the
614 * original object if it is no longer being used, or else a memory leak will
615 * result.  Please see other methods on this class (particularly a
616 * corresponding method whose name begins with the word <code>create</code>)
617 * for alternatives that do not lead to these issues. 
618   <p>
619   * @see #createParameter()
620   */ public
621 int addParameter(Parameter p) {
622    return libsbmlJNI.KineticLaw_addParameter(swigCPtr, this, Parameter.getCPtr(p), p);
623  }
624
625  
626/**
627   * Adds a copy of the given {@link LocalParameter} object to the list of local
628   * parameters in this {@link KineticLaw}.
629   <p>
630   * @param p the {@link LocalParameter} to add
631   <p>
632   * @return integer value indicating success/failure of the
633   * function. The possible values
634   * returned by this function are:
635   * <ul>
636   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS }
637   * <li> {@link  libsbmlConstants#LIBSBML_LEVEL_MISMATCH LIBSBML_LEVEL_MISMATCH }
638   * <li> {@link  libsbmlConstants#LIBSBML_VERSION_MISMATCH LIBSBML_VERSION_MISMATCH }
639   * <li> {@link  libsbmlConstants#LIBSBML_DUPLICATE_OBJECT_ID LIBSBML_DUPLICATE_OBJECT_ID }
640   * <li> {@link  libsbmlConstants#LIBSBML_INVALID_OBJECT LIBSBML_INVALID_OBJECT }
641   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED }
642   *
643   * </ul> <p>
644   * <p>
645 * @note This method should be used with some caution.  The fact that this
646 * method <em>copies</em> the object passed to it means that the caller will be
647 * left holding a physically different object instance than the one contained
648 * inside this object.  Changes made to the original object instance (such as
649 * resetting attribute values) will <em>not affect the instance in this
650 * object</em>.  In addition, the caller should make sure to free the
651 * original object if it is no longer being used, or else a memory leak will
652 * result.  Please see other methods on this class (particularly a
653 * corresponding method whose name begins with the word <code>create</code>)
654 * for alternatives that do not lead to these issues. 
655   <p>
656   * @see #createLocalParameter()
657   */ public
658 int addLocalParameter(LocalParameter p) {
659    return libsbmlJNI.KineticLaw_addLocalParameter(swigCPtr, this, LocalParameter.getCPtr(p), p);
660  }
661
662  
663/**
664   * Creates a new {@link Parameter} object, adds it to this {@link KineticLaw}'s list of
665   * local parameters, and returns the {@link Parameter} object created.
666   <p>
667   * @return a new {@link Parameter} object instance
668   <p>
669   * @see #addParameter(Parameter p)
670   */ public
671 Parameter createParameter() {
672    long cPtr = libsbmlJNI.KineticLaw_createParameter(swigCPtr, this);
673    return (cPtr == 0) ? null : new Parameter(cPtr, false);
674  }
675
676  
677/**
678   * Creates a new {@link LocalParameter} object, adds it to this {@link KineticLaw}'s list
679   * of local parameters, and returns the {@link LocalParameter} object created.
680   <p>
681   * @return a new {@link LocalParameter} object instance
682   <p>
683   * @see #addLocalParameter(LocalParameter p)
684   */ public
685 LocalParameter createLocalParameter() {
686    long cPtr = libsbmlJNI.KineticLaw_createLocalParameter(swigCPtr, this);
687    return (cPtr == 0) ? null : new LocalParameter(cPtr, false);
688  }
689
690  
691/**
692   * Returns the list of local parameters in this {@link KineticLaw} object.
693   <p>
694   * @return the list of Parameters for this {@link KineticLaw}.
695   */ public
696 ListOfParameters getListOfParameters() {
697    long cPtr = libsbmlJNI.KineticLaw_getListOfParameters__SWIG_0(swigCPtr, this);
698    return (cPtr == 0) ? null : new ListOfParameters(cPtr, false);
699  }
700
701  
702/**
703   * Returns the list of local parameters in this {@link KineticLaw} object.
704   <p>
705   * @return the list of LocalParameters for this {@link KineticLaw}.
706   */ public
707 ListOfLocalParameters getListOfLocalParameters() {
708    long cPtr = libsbmlJNI.KineticLaw_getListOfLocalParameters__SWIG_0(swigCPtr, this);
709    return (cPtr == 0) ? null : new ListOfLocalParameters(cPtr, false);
710  }
711
712  
713/**
714   * Returns the nth {@link Parameter} object in the list of local parameters in
715   * this {@link KineticLaw} instance.
716   <p>
717   * @param n the index of the {@link Parameter} object sought
718   <p>
719   * @return the nth {@link Parameter} of this {@link KineticLaw}.
720   */ public
721 Parameter getParameter(long n) {
722    long cPtr = libsbmlJNI.KineticLaw_getParameter__SWIG_0(swigCPtr, this, n);
723    return (cPtr == 0) ? null : new Parameter(cPtr, false);
724  }
725
726  
727/**
728   * Returns the nth {@link LocalParameter} object in the list of local parameters in
729   * this {@link KineticLaw} instance.
730   <p>
731   * @param n the index of the {@link LocalParameter} object sought
732   <p>
733   * @return the nth {@link LocalParameter} of this {@link KineticLaw}.
734   */ public
735 LocalParameter getLocalParameter(long n) {
736    long cPtr = libsbmlJNI.KineticLaw_getLocalParameter__SWIG_0(swigCPtr, this, n);
737    return (cPtr == 0) ? null : new LocalParameter(cPtr, false);
738  }
739
740  
741/**
742   * Returns a local parameter based on its identifier.
743   <p>
744   * @param sid the identifier of the {@link Parameter} being sought.
745   <p>
746   * @return the {@link Parameter} object in this {@link KineticLaw} instace having the
747   * given 'id', or <code>null</code> if no such {@link Parameter} exists.
748   */ public
749 Parameter getParameter(String sid) {
750    long cPtr = libsbmlJNI.KineticLaw_getParameter__SWIG_2(swigCPtr, this, sid);
751    return (cPtr == 0) ? null : new Parameter(cPtr, false);
752  }
753
754  
755/**
756   * Returns a local parameter based on its identifier.
757   <p>
758   * @param sid the identifier of the {@link LocalParameter} being sought.
759   <p>
760   * @return the {@link LocalParameter} object in this {@link KineticLaw} instace having the
761   * given 'id', or <code>null</code> if no such {@link LocalParameter} exists.
762   */ public
763 LocalParameter getLocalParameter(String sid) {
764    long cPtr = libsbmlJNI.KineticLaw_getLocalParameter__SWIG_2(swigCPtr, this, sid);
765    return (cPtr == 0) ? null : new LocalParameter(cPtr, false);
766  }
767
768  
769/**
770   * Returns the number of local parameters in this {@link KineticLaw} instance.
771   <p>
772   * @return the number of Parameters in this {@link KineticLaw}.
773   */ public
774 long getNumParameters() {
775    return libsbmlJNI.KineticLaw_getNumParameters(swigCPtr, this);
776  }
777
778  
779/**
780   * Returns the number of local parameters in this {@link KineticLaw} instance.
781   <p>
782   * @return the number of LocalParameters in this {@link KineticLaw}.
783   */ public
784 long getNumLocalParameters() {
785    return libsbmlJNI.KineticLaw_getNumLocalParameters(swigCPtr, this);
786  }
787
788  
789/**
790   * Calculates and returns a {@link UnitDefinition} that expresses the units of
791   * measurement assumed for the 'math' expression of this {@link KineticLaw}.
792   <p>
793   * <p>
794 * The units are calculated based on the mathematical expression in the
795 * {@link KineticLaw} and the model quantities referenced by <code>&lt;ci&gt;</code>
796 * elements used within that expression.  The
797 * {@link KineticLaw#getDerivedUnitDefinition()}
798 * method returns the calculated units. 
799   <p>
800   * <p>
801 * @note The functionality that facilitates unit analysis depends on the
802 * model as a whole.  Thus, in cases where the object has not been added to
803 * a model or the model itself is incomplete, unit analysis is not possible
804 * and this method will return <code>null.</code> 
805   <p>
806   * <p>
807 * @warning <span class='warning'>Note that it is possible the 'math'
808 * expression in the {@link KineticLaw} contains pure numbers or parameters with
809 * undeclared units.  In those cases, it is not possible to calculate the
810 * units of the overall expression without making assumptions.  LibSBML does
811 * not make assumptions about the units, and
812 * {@link KineticLaw#getDerivedUnitDefinition()} returns the units as far as it is
813 * able to determine them.  For example, in an expression <em>X + Y</em>, if
814 * <em>X</em> has unambiguously-defined units and <em>Y</em> does not, it
815 * will return the units of <em>X</em>.  <strong>It is important that callers
816 * also invoke the method</strong>
817 * {@link KineticLaw#containsUndeclaredUnits()}<strong>to determine whether this
818 * situation holds</strong>.  Callers may wish to take suitable actions in
819 * those scenarios.</span>
820   <p>
821   * @return a {@link UnitDefinition} that expresses the units of the math 
822   * expression of this {@link KineticLaw}, or <code>null</code> if one cannot be constructed.
823   <p>
824   * @see #containsUndeclaredUnits()
825   */ public
826 UnitDefinition getDerivedUnitDefinition() {
827    long cPtr = libsbmlJNI.KineticLaw_getDerivedUnitDefinition__SWIG_0(swigCPtr, this);
828    return (cPtr == 0) ? null : new UnitDefinition(cPtr, false);
829  }
830
831  
832/**
833   * Predicate returning <code>true</code> if the math expression of this {@link KineticLaw}
834   * contains parameters/numbers with undeclared units.
835   <p>
836   * @return <code>true</code> if the math expression of this {@link KineticLaw}
837   * includes parameters/numbers 
838   * with undeclared units, <code>false</code> otherwise.
839   <p>
840   * @note A return value of <code>true</code> indicates that the {@link UnitDefinition}
841   * returned by
842   * {@link KineticLaw#getDerivedUnitDefinition()}
843   * may not accurately represent the units of the expression.
844   <p>
845   * @see #getDerivedUnitDefinition()
846   */ public
847 boolean containsUndeclaredUnits() {
848    return libsbmlJNI.KineticLaw_containsUndeclaredUnits__SWIG_0(swigCPtr, this);
849  }
850
851  
852/**
853   * Removes the nth {@link Parameter} object in the list of local parameters 
854   * in this {@link KineticLaw} instance and returns a pointer to it.
855   <p>
856   * The caller owns the returned object and is responsible for deleting it.
857   <p>
858   * @param n the index of the {@link Parameter} object to remove
859   <p>
860   * @return the {@link Parameter} object removed.  As mentioned above, 
861   * the caller owns the returned item. <code>null</code> is returned if the given index 
862   * is out of range.
863   */ public
864 Parameter removeParameter(long n) {
865    long cPtr = libsbmlJNI.KineticLaw_removeParameter__SWIG_0(swigCPtr, this, n);
866    return (cPtr == 0) ? null : new Parameter(cPtr, true);
867  }
868
869  
870/**
871   * Removes the nth {@link LocalParameter} object in the list of local parameters 
872   * in this {@link KineticLaw} instance and returns a pointer to it.
873   <p>
874   * The caller owns the returned object and is responsible for deleting it.
875   <p>
876   * @param n the index of the {@link LocalParameter} object to remove
877   <p>
878   * @return the {@link LocalParameter} object removed.  As mentioned above, 
879   * the caller owns the returned item. <code>null</code> is returned if the given index 
880   * is out of range.
881   */ public
882 LocalParameter removeLocalParameter(long n) {
883    long cPtr = libsbmlJNI.KineticLaw_removeLocalParameter__SWIG_0(swigCPtr, this, n);
884    return (cPtr == 0) ? null : new LocalParameter(cPtr, true);
885  }
886
887  
888/**
889   * Removes a {@link Parameter} object with the given identifier in the list of
890   * local parameters in this {@link KineticLaw} instance and returns a pointer to it.
891   <p>
892   * The caller owns the returned object and is responsible for deleting it.
893   <p>
894   * @param sid the identifier of the {@link Parameter} to remove
895   <p>
896   * @return the {@link Parameter} object removed.  As mentioned above, the 
897   * caller owns the returned object. <code>null</code> is returned if no {@link Parameter}
898   * object with the identifier exists in this {@link KineticLaw} instance.
899   */ public
900 Parameter removeParameter(String sid) {
901    long cPtr = libsbmlJNI.KineticLaw_removeParameter__SWIG_1(swigCPtr, this, sid);
902    return (cPtr == 0) ? null : new Parameter(cPtr, true);
903  }
904
905  
906/**
907   * Removes a {@link LocalParameter} object with the given identifier in the list of
908   * local parameters in this {@link KineticLaw} instance and returns a pointer to it.
909   <p>
910   * The caller owns the returned object and is responsible for deleting it.
911   <p>
912   * @param sid the identifier of the {@link LocalParameter} to remove
913   <p>
914   * @return the {@link LocalParameter} object removed.  As mentioned above, the 
915   * caller owns the returned object. <code>null</code> is returned if no {@link LocalParameter}
916   * object with the identifier exists in this {@link KineticLaw} instance.
917   */ public
918 LocalParameter removeLocalParameter(String sid) {
919    long cPtr = libsbmlJNI.KineticLaw_removeLocalParameter__SWIG_1(swigCPtr, this, sid);
920    return (cPtr == 0) ? null : new LocalParameter(cPtr, true);
921  }
922
923  
924/**
925   * Sets this SBML object to child SBML objects (if any).
926   * (Creates a child-parent relationship by the parent)
927   <p>
928   * Subclasses must override this function if they define one ore more child
929   * elements.  Basically, this function needs to be called in constructor,
930   * copy constructor and assignment operator.
931   <p>
932   * @see setSBMLDocument
933   * @see enablePackageInternal
934   * @internal
935   */ public
936 void connectToChild() {
937    libsbmlJNI.KineticLaw_connectToChild(swigCPtr, this);
938  }
939
940  
941/**
942   * Enables/Disables the given package with this element and child
943   * elements (if any).
944   * (This is an internal implementation for enablePackage function)
945   <p>
946   * @note Subclasses of the SBML Core package in which one or more child
947   * elements are defined must override this function.
948   * @internal
949   */ public
950 void enablePackageInternal(String pkgURI, String pkgPrefix, boolean flag) {
951    libsbmlJNI.KineticLaw_enablePackageInternal(swigCPtr, this, pkgURI, pkgPrefix, flag);
952  }
953
954  
955/**
956   * Returns the libSBML type code for this SBML object.
957   <p>
958   * <p>
959 * LibSBML attaches an identifying code to every kind of SBML object.  These
960 * are integer constants known as <em>SBML type codes</em>.  The names of all
961 * the codes begin with the characters &ldquo;<code>SBML_</code>&rdquo;. 
962 * In the Java language interface for libSBML, the
963 * type codes are defined as static integer constants in the interface class
964 * {@link libsbmlConstants}.    Note that different Level&nbsp;3 
965 * package plug-ins may use overlapping type codes; to identify the package
966 * to which a given object belongs, call the <code>getPackageName()</code>
967 * method on the object.
968   <p>
969   * @return the SBML type code for this object:
970   * {@link  libsbmlConstants#SBML_KINETIC_LAW SBML_KINETIC_LAW} (default).
971   <p>
972   * <p>
973 * @warning <span class='warning'>The specific integer values of the possible
974 * type codes may be reused by different Level&nbsp;3 package plug-ins.
975 * Thus, to identifiy the correct code, <strong>it is necessary to invoke
976 * both getTypeCode() and getPackageName()</strong>.</span>
977   <p>
978   * @see #getElementName()
979   * @see #getPackageName()
980   */ public
981 int getTypeCode() {
982    return libsbmlJNI.KineticLaw_getTypeCode(swigCPtr, this);
983  }
984
985  
986/**
987   * Returns the XML element name of this object, which for {@link Species}, is
988   * always <code>'kineticLaw'.</code>
989   <p>
990   * @return the name of this element, i.e., <code>'kineticLaw'.</code>
991   */ public
992 String getElementName() {
993    return libsbmlJNI.KineticLaw_getElementName(swigCPtr, this);
994  }
995
996  
997/**
998   * Predicate returning <code>true</code> if all the required attributes for this
999   * {@link KineticLaw} object have been set.
1000   <p>
1001   * @note The required attributes for a {@link KineticLaw} object are:
1002   * <ul>
1003   * <li> 'formula' (SBML Level&nbsp;1 only)
1004   *
1005   * </ul> <p>
1006   * @return a boolean value indicating whether all the required
1007   * attributes for this object have been defined.
1008   */ public
1009 boolean hasRequiredAttributes() {
1010    return libsbmlJNI.KineticLaw_hasRequiredAttributes(swigCPtr, this);
1011  }
1012
1013  
1014/**
1015   * Predicate returning <code>true</code> if all the required elements for this
1016   * {@link KineticLaw} object have been set.
1017   <p>
1018   * @note The required elements for a {@link KineticLaw} object are:
1019   * <ul>
1020   * <li> 'math'
1021   *
1022   * </ul> <p>
1023   * @return a boolean value indicating whether all the required
1024   * elements for this object have been defined.
1025   */ public
1026 boolean hasRequiredElements() {
1027    return libsbmlJNI.KineticLaw_hasRequiredElements(swigCPtr, this);
1028  }
1029
1030  
1031/**
1032   * Finds this {@link KineticLaw}'s {@link Reaction} parent and calls unsetKineticLaw() on
1033   * it, indirectly deleting itself.
1034   <p>
1035   * Overridden from the {@link SBase} function since the parent is not a {@link ListOf}.
1036   <p>
1037   * @return integer value indicating success/failure of the
1038   * function.   The possible values
1039   * returned by this function are:
1040   * <ul>
1041   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS }
1042   * <li> {@link  libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED }
1043   * </ul>
1044   */ public
1045 int removeFromParentAndDelete() {
1046    return libsbmlJNI.KineticLaw_removeFromParentAndDelete(swigCPtr, this);
1047  }
1048
1049  
1050/**
1051   * Renames all the <code>SIdRef</code> attributes on this element, including any
1052   * found in MathML.
1053   <p>
1054   * <p>
1055 * In SBML, object identifiers are of a data type called <code>SId</code>.
1056 * In SBML Level&nbsp;3, an explicit data type called <code>SIdRef</code> was
1057 * introduced for attribute values that refer to <code>SId</code> values; in
1058 * previous Levels of SBML, this data type did not exist and attributes were
1059 * simply described to as 'referring to an identifier', but the effective
1060 * data type was the same as <code>SIdRef</code>in Level&nbsp;3.  These and
1061 * other methods of libSBML refer to the type <code>SIdRef</code> for all
1062 * Levels of SBML, even if the corresponding SBML specification did not
1063 * explicitly name the data type.
1064   <p>
1065   * This method works by looking at all attributes and (if appropriate)
1066   * mathematical formulas, comparing the identifiers to the value of 
1067   * <code>oldid</code>.  If any matches are found, the matching identifiers are replaced
1068   * with <code>newid</code>.  The method does <em>not</em> descend into child elements.
1069   <p>
1070   * @param oldid the old identifier
1071   * @param newid the new identifier
1072   */ public
1073 void renameSIdRefs(String oldid, String newid) {
1074    libsbmlJNI.KineticLaw_renameSIdRefs(swigCPtr, this, oldid, newid);
1075  }
1076
1077  
1078/**
1079   * Renames all the <code>UnitSIdRef</code> attributes on this element
1080   <p>
1081   * <p>
1082 * In SBML, unit definitions have identifiers of type <code>UnitSId</code>.  In
1083 * SBML Level&nbsp;3, an explicit data type called <code>UnitSIdRef</code> was
1084 * introduced for attribute values that refer to <code>UnitSId</code> values; in
1085 * previous Levels of SBML, this data type did not exist and attributes were
1086 * simply described to as 'referring to a unit identifier', but the effective
1087 * data type was the same as <code>UnitSIdRef</code> in Level&nbsp;3.  These and
1088 * other methods of libSBML refer to the type <code>UnitSIdRef</code> for all
1089 * Levels of SBML, even if the corresponding SBML specification did not
1090 * explicitly name the data type.
1091   <p>
1092   * This method works by looking at all unit identifier attribute values
1093   * (including, if appropriate, inside mathematical formulas), comparing the
1094   * unit identifiers to the value of <code>oldid</code>.  If any matches are found,
1095   * the matching identifiers are replaced with <code>newid</code>.  The method does
1096   * <em>not</em> descend into child elements.
1097   <p>
1098   * @param oldid the old identifier
1099   * @param newid the new identifier
1100   */ public
1101 void renameUnitSIdRefs(String oldid, String newid) {
1102    libsbmlJNI.KineticLaw_renameUnitSIdRefs(swigCPtr, this, oldid, newid);
1103  }
1104
1105  
1106/**
1107   * Replace all nodes with the name 'id' from the child 'math' object with the provided function. 
1108   <p>
1109   * @internal
1110   */ public
1111 void replaceSIDWithFunction(String id, ASTNode function) {
1112    libsbmlJNI.KineticLaw_replaceSIDWithFunction(swigCPtr, this, id, ASTNode.getCPtr(function), function);
1113  }
1114
1115  
1116/**
1117   * If this reaction id matches the provided 'id' string, replace the 'math' object with the function (existing/function). 
1118   * @internal 
1119   */ public
1120 void divideAssignmentsToSIdByFunction(String id, ASTNode function) {
1121    libsbmlJNI.KineticLaw_divideAssignmentsToSIdByFunction(swigCPtr, this, id, ASTNode.getCPtr(function), function);
1122  }
1123
1124  
1125/**
1126   * If this assignment assigns a value to the 'id' element, replace the 'math' object with the function (existing*function). 
1127   * @internal 
1128   */ public
1129 void multiplyAssignmentsToSIdByFunction(String id, ASTNode function) {
1130    libsbmlJNI.KineticLaw_multiplyAssignmentsToSIdByFunction(swigCPtr, this, id, ASTNode.getCPtr(function), function);
1131  }
1132
1133}