001/* ----------------------------------------------------------------------------
002 * This file was automatically generated by SWIG (http://www.swig.org).
003 * Version 3.0.7
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 Extension of {@link Model}.
014 */
015
016public class FbcModelPlugin extends SBasePlugin {
017   private long swigCPtr;
018
019   protected FbcModelPlugin(long cPtr, boolean cMemoryOwn)
020   {
021     super(libsbmlJNI.FbcModelPlugin_SWIGUpcast(cPtr), cMemoryOwn);
022     swigCPtr = cPtr;
023   }
024
025   protected static long getCPtr(FbcModelPlugin obj)
026   {
027     return (obj == null) ? 0 : obj.swigCPtr;
028   }
029
030   protected static long getCPtrAndDisown (FbcModelPlugin obj)
031   {
032     long ptr = 0;
033
034     if (obj != null)
035     {
036       ptr             = obj.swigCPtr;
037       obj.swigCMemOwn = false;
038     }
039
040     return ptr;
041   }
042
043  protected void finalize() {
044    delete();
045  }
046
047  public synchronized void delete() {
048    if (swigCPtr != 0) {
049      if (swigCMemOwn) {
050        swigCMemOwn = false;
051        libsbmlJNI.delete_FbcModelPlugin(swigCPtr);
052      }
053      swigCPtr = 0;
054    }
055    super.delete();
056  }
057
058  
059/**
060   * Creates a new {@link FbcModelPlugin}
061   */ public
062 FbcModelPlugin(String uri, String prefix, FbcPkgNamespaces fbcns) {
063    this(libsbmlJNI.new_FbcModelPlugin__SWIG_0(uri, prefix, FbcPkgNamespaces.getCPtr(fbcns), fbcns), true);
064  }
065
066  
067/**
068   * Copy constructor for {@link FbcModelPlugin}.
069   <p>
070   * @param orig; the {@link FbcModelPlugin} instance to copy.
071   */ public
072 FbcModelPlugin(FbcModelPlugin orig) {
073    this(libsbmlJNI.new_FbcModelPlugin__SWIG_1(FbcModelPlugin.getCPtr(orig), orig), true);
074  }
075
076  
077/**
078   * Creates and returns a deep copy of this {@link FbcModelPlugin} object.
079   <p>
080   * @return a (deep) copy of this {@link FbcModelPlugin} object.
081   */ public
082 SBasePlugin cloneObject() {
083    long cPtr = libsbmlJNI.FbcModelPlugin_cloneObject(swigCPtr, this);
084    return (cPtr == 0) ? null : new FbcModelPlugin(cPtr, true);
085  }
086
087  
088/** * @internal */ public
089 SBase createObject(XMLInputStream stream) {
090  return libsbml.DowncastSBase(libsbmlJNI.FbcModelPlugin_createObject(swigCPtr, this, XMLInputStream.getCPtr(stream), stream), false);
091}
092
093  
094/** * @internal */ public
095 int appendFrom(Model model) {
096    return libsbmlJNI.FbcModelPlugin_appendFrom(swigCPtr, this, Model.getCPtr(model), model);
097  }
098
099  
100/**
101   * Checks if this plugin object has all the required elements.
102   <p>
103   * Subclasses must override this method 
104   * if they have their specific elements.
105   <p>
106   * @return true if this plugin object has all the required elements
107   * otherwise false will be returned.
108   */ public
109 boolean hasRequiredElements() {
110    return libsbmlJNI.FbcModelPlugin_hasRequiredElements(swigCPtr, this);
111  }
112
113  
114/** * @internal */ public
115 boolean readOtherXML(SBase parentObject, XMLInputStream stream) {
116    return libsbmlJNI.FbcModelPlugin_readOtherXML(swigCPtr, this, SBase.getCPtr(parentObject), parentObject, XMLInputStream.getCPtr(stream), stream);
117  }
118
119  
120/** * @internal */ public
121 void addExpectedAttributes(SWIGTYPE_p_ExpectedAttributes attributes) {
122    libsbmlJNI.FbcModelPlugin_addExpectedAttributes(swigCPtr, this, SWIGTYPE_p_ExpectedAttributes.getCPtr(attributes));
123  }
124
125  
126/** * @internal */ public
127 void readAttributes(XMLAttributes attributes, SWIGTYPE_p_ExpectedAttributes expectedAttributes) {
128    libsbmlJNI.FbcModelPlugin_readAttributes(swigCPtr, this, XMLAttributes.getCPtr(attributes), attributes, SWIGTYPE_p_ExpectedAttributes.getCPtr(expectedAttributes));
129  }
130
131  
132/** * @internal */ public
133 void writeAttributes(XMLOutputStream stream) {
134    libsbmlJNI.FbcModelPlugin_writeAttributes(swigCPtr, this, XMLOutputStream.getCPtr(stream), stream);
135  }
136
137  
138/**
139   * Returns the value of the 'strict' attribute of this {@link FbcModelPlugin}.
140   <p>
141   * @return the value of the 'strict' attribute of this {@link FbcModelPlugin} as a boolean.
142   */ public
143 boolean getStrict() {
144    return libsbmlJNI.FbcModelPlugin_getStrict(swigCPtr, this);
145  }
146
147  
148/**
149   * Predicate returning <code>true</code> if this {@link FbcModelPlugin}'s 'strict' attribute
150   * is set.
151   <p>
152   * @return <code>true</code> if this {@link FbcModelPlugin}'s 'strict' attribute has been set,
153   * otherwise <code>false</code> is returned.
154   */ public
155 boolean isSetStrict() {
156    return libsbmlJNI.FbcModelPlugin_isSetStrict(swigCPtr, this);
157  }
158
159  
160/**
161   * Sets the value of the 'strict' attribute of this {@link FbcModelPlugin}.
162   <p>
163   * @param strict; boolean value of the 'strict' attribute to be set
164   <p>
165   * @return integer value indicating success/failure of the
166   * function.   The possible values
167   * returned by this function are:
168   * <ul>
169   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
170   * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE}
171   * </ul>
172   */ public
173 int setStrict(boolean strict) {
174    return libsbmlJNI.FbcModelPlugin_setStrict(swigCPtr, this, strict);
175  }
176
177  
178/**
179   * Unsets the value of the 'strict' attribute of this {@link FbcModelPlugin}.
180   <p>
181   * @return integer value indicating success/failure of the
182   * function.   The possible values
183   * returned by this function are:
184   * <ul>
185   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
186   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED}
187   * </ul>
188   */ public
189 int unsetStrict() {
190    return libsbmlJNI.FbcModelPlugin_unsetStrict(swigCPtr, this);
191  }
192
193  
194/**
195   * Returns the {@link ListOfFluxBounds} in this plugin object.
196   <p>
197   * @return {@link ListOfFluxBounds} object in this plugin object.
198   */ public
199 ListOfFluxBounds getListOfFluxBounds() {
200    long cPtr = libsbmlJNI.FbcModelPlugin_getListOfFluxBounds__SWIG_0(swigCPtr, this);
201    return (cPtr == 0) ? null : new ListOfFluxBounds(cPtr, false);
202  }
203
204  
205/**
206   * Returns the {@link FluxBound} object that belongs to the given index. If the
207   * index is invalid, <code>null</code> is returned.
208   <p>
209   * @param n the index number of the {@link FluxBound} to get.
210   <p>
211   * @return the nth {@link FluxBound} in the {@link ListOfFluxBounds}.
212   */ public
213 FluxBound getFluxBound(long n) {
214    long cPtr = libsbmlJNI.FbcModelPlugin_getFluxBound__SWIG_0(swigCPtr, this, n);
215    return (cPtr == 0) ? null : new FluxBound(cPtr, false);
216  }
217
218  
219/**
220   * Returns the {@link FluxBound} object based on its identifier.
221   <p>
222   * @param sid a string representing the identifier 
223   * of the {@link FluxBound} to get.
224   <p>
225   * @return {@link FluxBound} in the {@link ListOfFluxBounds} with the given <code>sid</code>
226   * or null if no such {@link FluxBound} exists.
227   <p>
228   * @see #getFluxBound(long n)
229   * @see #getListOfFluxBounds()
230   */ public
231 FluxBound getFluxBound(String sid) {
232    long cPtr = libsbmlJNI.FbcModelPlugin_getFluxBound__SWIG_2(swigCPtr, this, sid);
233    return (cPtr == 0) ? null : new FluxBound(cPtr, false);
234  }
235
236  
237/**
238   <p>
239   * @param reaction the id of an reaction to find fluxBounds for
240   <p>
241   * @return a listOfFluxBounds for the given reaction id
242   */ public
243 ListOfFluxBounds getFluxBoundsForReaction(String reaction) {
244    long cPtr = libsbmlJNI.FbcModelPlugin_getFluxBoundsForReaction(swigCPtr, this, reaction);
245    return (cPtr == 0) ? null : new ListOfFluxBounds(cPtr, false);
246  }
247
248  
249/**
250   * Adds a copy of the given {@link FluxBound} object to the list of FluxBounds.
251   <p>
252   * @param bound the {@link FluxBound} object to be added to the list of FluxBounds.
253   <p>
254   * <p>
255 * @return integer value indicating success/failure of the
256 * function.   The possible values
257 * returned by this function are:
258   * <ul>
259   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
260   * </ul>
261   */ public
262 int addFluxBound(FluxBound bound) {
263    return libsbmlJNI.FbcModelPlugin_addFluxBound(swigCPtr, this, FluxBound.getCPtr(bound), bound);
264  }
265
266  
267/**
268   * Creates a new {@link FluxBound} object and adds it to the list of {@link FluxBound} objects
269   * and returns it.
270   <p>
271   * @return a newly created {@link FluxBound} object
272   */ public
273 FluxBound createFluxBound() {
274    long cPtr = libsbmlJNI.FbcModelPlugin_createFluxBound(swigCPtr, this);
275    return (cPtr == 0) ? null : new FluxBound(cPtr, false);
276  }
277
278  
279/**
280   * Removes the nth {@link FluxBound} object from this plugin object and
281   * returns a pointer to it.
282   <p>
283   * The caller owns the returned object and is responsible for
284   *  deleting it.
285   <p>
286   * @param n the index of the {@link FluxBound} object to remove
287   <p>
288   * @return the {@link FluxBound} object removed.  As mentioned above, the 
289   * caller owns the returned object. <code>null</code> is returned if the 
290   * given index is out of range.
291   */ public
292 FluxBound removeFluxBound(long n) {
293    long cPtr = libsbmlJNI.FbcModelPlugin_removeFluxBound__SWIG_0(swigCPtr, this, n);
294    return (cPtr == 0) ? null : new FluxBound(cPtr, false);
295  }
296
297  
298/**
299   * Removes the {@link FluxBound} object with the given <code>sid</code> attribute from 
300   * this plugin object and returns a pointer to it.
301   <p>
302   * The caller owns the returned object and is responsible for
303   * deleting it.
304   <p>
305   * @param sid the id attribute of the {@link FluxBound} object to remove
306   <p>
307   * @return the {@link FluxBound} object removed.  As mentioned above, the 
308   * caller owns the returned object. <code>null</code> is returned if the 
309   * given index is out of range.
310   */ public
311 FluxBound removeFluxBound(String sid) {
312    long cPtr = libsbmlJNI.FbcModelPlugin_removeFluxBound__SWIG_1(swigCPtr, this, sid);
313    return (cPtr == 0) ? null : new FluxBound(cPtr, false);
314  }
315
316  
317/**
318   * Returns the number of {@link FluxBound} object in this plugin object.
319   <p>
320   * @return the number of {@link FluxBound} object in this plugin object.
321   */ public
322 long getNumFluxBounds() {
323    return libsbmlJNI.FbcModelPlugin_getNumFluxBounds(swigCPtr, this);
324  }
325
326  
327/**
328   * Returns the  'ListOfObjectives' in this {@link FbcModelPlugin} object.
329   <p>
330   * @return the 'ListOfObjectives' attribute of this {@link FbcModelPlugin}.
331   */ public
332 ListOfObjectives getListOfObjectives() {
333    long cPtr = libsbmlJNI.FbcModelPlugin_getListOfObjectives__SWIG_0(swigCPtr, this);
334    return (cPtr == 0) ? null : new ListOfObjectives(cPtr, false);
335  }
336
337  
338/**
339   * Get a {@link Objective} from the {@link ListOfObjectives}.
340   <p>
341   * @param n the index number of the {@link Objective} to get.
342   <p>
343   * @return the nth {@link Objective} in the {@link ListOfObjectives} within this {@link FbcModelPlugin}.
344   <p>
345   * @see #getNumObjectives()
346   */ public
347 Objective getObjective(long n) {
348    long cPtr = libsbmlJNI.FbcModelPlugin_getObjective__SWIG_0(swigCPtr, this, n);
349    return (cPtr == 0) ? null : new Objective(cPtr, false);
350  }
351
352  
353/**
354   * Get a {@link Objective} from the {@link ListOfObjectives}
355   * based on its identifier.
356   <p>
357   * @param sid a string representing the identifier
358   * of the {@link Objective} to get.
359   <p>
360   * @return the {@link Objective} in the {@link ListOfObjectives}
361   * with the given id or null if no such
362   * {@link Objective} exists.
363   <p>
364   * 
365   * @see #getNumObjectives()
366   <p>
367   * @see #getObjective(long n)
368   */ public
369 Objective getObjective(String sid) {
370    long cPtr = libsbmlJNI.FbcModelPlugin_getObjective__SWIG_2(swigCPtr, this, sid);
371    return (cPtr == 0) ? null : new Objective(cPtr, false);
372  }
373
374  
375/**
376   * Adds a copy the given 'Objective' to this {@link FbcModelPlugin}.
377   <p>
378   * @param o; the {@link Objective} object to add
379   <p>
380   * @return integer value indicating success/failure of the
381   * function.   The possible values
382   * returned by this function are:
383   * <ul>
384   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
385   * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE}
386   * </ul>
387   */ public
388 int addObjective(Objective o) {
389    return libsbmlJNI.FbcModelPlugin_addObjective(swigCPtr, this, Objective.getCPtr(o), o);
390  }
391
392  
393/**
394   * Get the number of {@link Objective} objects in this {@link FbcModelPlugin}.
395   <p>
396   * @return the number of {@link Objective} objects in this {@link FbcModelPlugin}
397   */ public
398 long getNumObjectives() {
399    return libsbmlJNI.FbcModelPlugin_getNumObjectives(swigCPtr, this);
400  }
401
402  
403/**
404   * Creates a new {@link Objective} object, adds it to this FbcModelPlugins
405   * {@link ListOfObjectives} and returns the {@link Objective} object created. 
406   <p>
407   * @return a new {@link Objective} object instance
408   <p>
409   * @see #addObjective(Objective o)
410   */ public
411 Objective createObjective() {
412    long cPtr = libsbmlJNI.FbcModelPlugin_createObjective(swigCPtr, this);
413    return (cPtr == 0) ? null : new Objective(cPtr, false);
414  }
415
416  
417/**
418   * Removes the nth {@link Objective} from the {@link ListOfObjectives} within this {@link FbcModelPlugin}.
419   * and returns a pointer to it.
420   <p>
421   * The caller owns the returned item and is responsible for deleting it.
422   <p>
423   * @param n the index of the {@link Objective} to remove.
424   <p>
425   * @see #getNumObjectives()
426   */ public
427 Objective removeObjective(long n) {
428    long cPtr = libsbmlJNI.FbcModelPlugin_removeObjective__SWIG_0(swigCPtr, this, n);
429    return (cPtr == 0) ? null : new Objective(cPtr, true);
430  }
431
432  
433/**
434   * Removes the {@link Objective} with the given identifier from the {@link ListOfObjectives} within this {@link FbcModelPlugin}
435   * and returns a pointer to it.
436   <p>
437   * The caller owns the returned item and is responsible for deleting it.
438   * If none of the items in this list have the identifier <code>sid</code>, then
439   * <code>null</code> is returned.
440   <p>
441   * @param sid the identifier of the {@link Objective} to remove.
442   <p>
443   * @return the {@link Objective} removed. As mentioned above, the caller owns the
444   * returned item.
445   */ public
446 Objective removeObjective(String sid) {
447    long cPtr = libsbmlJNI.FbcModelPlugin_removeObjective__SWIG_1(swigCPtr, this, sid);
448    return (cPtr == 0) ? null : new Objective(cPtr, true);
449  }
450
451  
452/** 
453   * Returns the current active objective. 
454   */ public
455 Objective getActiveObjective() {
456    long cPtr = libsbmlJNI.FbcModelPlugin_getActiveObjective__SWIG_0(swigCPtr, this);
457    return (cPtr == 0) ? null : new Objective(cPtr, false);
458  }
459
460  
461/** 
462   * Sets the id of the active objective.
463   */ public
464 int setActiveObjectiveId(String objectiveId) {
465    return libsbmlJNI.FbcModelPlugin_setActiveObjectiveId(swigCPtr, this, objectiveId);
466  }
467
468  
469/** 
470   * returns the id of the current active objective.
471   */ public
472 String getActiveObjectiveId() {
473    return libsbmlJNI.FbcModelPlugin_getActiveObjectiveId(swigCPtr, this);
474  }
475
476  
477/** 
478   * Unsets the active objective.
479   */ public
480 void unsetActiveObjectiveId() {
481    libsbmlJNI.FbcModelPlugin_unsetActiveObjectiveId(swigCPtr, this);
482  }
483
484  
485/**
486   * Returns the  'ListOfGeneProducts' in this {@link FbcModelPlugin} object.
487   <p>
488   * @return the 'ListOfGeneProducts' attribute of this {@link FbcModelPlugin}.
489   */ public
490 ListOfGeneProducts getListOfGeneProducts() {
491    long cPtr = libsbmlJNI.FbcModelPlugin_getListOfGeneProducts__SWIG_0(swigCPtr, this);
492    return (cPtr == 0) ? null : new ListOfGeneProducts(cPtr, false);
493  }
494
495  
496/**
497   * Get a {@link GeneProduct} from the {@link ListOfGeneProducts}.
498   <p>
499   * @param n the index number of the {@link GeneProduct} to get.
500   <p>
501   * @return the nth {@link GeneProduct} in the {@link ListOfGeneProducts} within this {@link FbcModelPlugin}.
502   <p>
503   * @see #getNumGeneProducts()
504   */ public
505 GeneProduct getGeneProduct(long n) {
506    long cPtr = libsbmlJNI.FbcModelPlugin_getGeneProduct__SWIG_0(swigCPtr, this, n);
507    return (cPtr == 0) ? null : new GeneProduct(cPtr, false);
508  }
509
510  
511/**
512   * Get a {@link GeneProduct} from the {@link ListOfGeneProducts}
513   * based on its identifier.
514   <p>
515   * @param sid a string representing the identifier
516   * of the {@link GeneProduct} to get.
517   <p>
518   * @return the {@link GeneProduct} in the {@link ListOfGeneProducts}
519   * with the given id or null if no such
520   * {@link GeneProduct} exists.
521   <p>
522   * 
523   * @see #getNumGeneProducts()
524   <p>
525   * @see #getGeneProduct(long n)
526   */ public
527 GeneProduct getGeneProduct(String sid) {
528    long cPtr = libsbmlJNI.FbcModelPlugin_getGeneProduct__SWIG_2(swigCPtr, this, sid);
529    return (cPtr == 0) ? null : new GeneProduct(cPtr, false);
530  }
531
532  
533/**
534  * Get a {@link GeneProduct} from the {@link ListOfGeneProducts}
535  * based on its label.
536  <p>
537  * @param label a string representing the label
538  * of the {@link GeneProduct} to get.
539  <p>
540  * @return the {@link GeneProduct} in the {@link ListOfGeneProducts}
541  * with the given label or null if no such
542  * {@link GeneProduct} exists.
543  <p>
544  * 
545  * @see #getNumGeneProducts()
546  <p>
547   * @see #getGeneProduct(long n)
548  */ public
549 GeneProduct getGeneProductByLabel(String label) {
550    long cPtr = libsbmlJNI.FbcModelPlugin_getGeneProductByLabel(swigCPtr, this, label);
551    return (cPtr == 0) ? null : new GeneProduct(cPtr, false);
552  }
553
554  
555/**
556   * Adds a copy the given 'GeneProduct' to this {@link FbcModelPlugin}.
557   <p>
558   * @param gp; the {@link GeneProduct} object to add
559   <p>
560   * @return integer value indicating success/failure of the
561   * function.   The possible values
562   * returned by this function are:
563   * <ul>
564   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
565   * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE}
566   * </ul>
567   */ public
568 int addGeneProduct(GeneProduct gp) {
569    return libsbmlJNI.FbcModelPlugin_addGeneProduct(swigCPtr, this, GeneProduct.getCPtr(gp), gp);
570  }
571
572  
573/**
574   * Get the number of {@link GeneProduct} objects in this {@link FbcModelPlugin}.
575   <p>
576   * @return the number of {@link GeneProduct} objects in this {@link FbcModelPlugin}
577   */ public
578 long getNumGeneProducts() {
579    return libsbmlJNI.FbcModelPlugin_getNumGeneProducts(swigCPtr, this);
580  }
581
582  
583/**
584   * Creates a new {@link GeneProduct} object, adds it to this FbcModelPlugins
585   * {@link ListOfGeneProducts} and returns the {@link GeneProduct} object created. 
586   <p>
587   * @return a new {@link GeneProduct} object instance
588   <p>
589   * @see #addGeneProduct(GeneProduct gp)
590   */ public
591 GeneProduct createGeneProduct() {
592    long cPtr = libsbmlJNI.FbcModelPlugin_createGeneProduct(swigCPtr, this);
593    return (cPtr == 0) ? null : new GeneProduct(cPtr, false);
594  }
595
596  
597/**
598   * Removes the nth {@link GeneProduct} from the {@link ListOfGeneProducts} within this {@link FbcModelPlugin}.
599   * and returns a pointer to it.
600   <p>
601   * The caller owns the returned item and is responsible for deleting it.
602   <p>
603   * @param n the index of the {@link GeneProduct} to remove.
604   <p>
605   * @see #getNumGeneProducts()
606   */ public
607 GeneProduct removeGeneProduct(long n) {
608    long cPtr = libsbmlJNI.FbcModelPlugin_removeGeneProduct__SWIG_0(swigCPtr, this, n);
609    return (cPtr == 0) ? null : new GeneProduct(cPtr, true);
610  }
611
612  
613/**
614   * Removes the {@link GeneProduct} with the given identifier from the {@link ListOfGeneProducts} within this {@link FbcModelPlugin}
615   * and returns a pointer to it.
616   <p>
617   * The caller owns the returned item and is responsible for deleting it.
618   * If none of the items in this list have the identifier <code>sid</code>, then
619   * <code>null</code> is returned.
620   <p>
621   * @param sid the identifier of the {@link GeneProduct} to remove.
622   <p>
623   * @return the {@link GeneProduct} removed. As mentioned above, the caller owns the
624   * returned item.
625   */ public
626 GeneProduct removeGeneProduct(String sid) {
627    long cPtr = libsbmlJNI.FbcModelPlugin_removeGeneProduct__SWIG_1(swigCPtr, this, sid);
628    return (cPtr == 0) ? null : new GeneProduct(cPtr, true);
629  }
630
631  
632/**
633   * Returns the {@link ListOfGeneAssociations} annotation object for level 1 in this plugin object.
634   <p>
635   * @return {@link ListOfGeneAssociations} annotation object for level 1 in this plugin object.
636   */ public
637 ListOfGeneAssociations getListOfGeneAssociations() {
638    long cPtr = libsbmlJNI.FbcModelPlugin_getListOfGeneAssociations__SWIG_0(swigCPtr, this);
639    return (cPtr == 0) ? null : new ListOfGeneAssociations(cPtr, false);
640  }
641
642  
643/**
644   * Returns the {@link GeneAssociation} annotation object that belongs to the given index. If the
645   * index is invalid, <code>null</code> is returned.
646   <p>
647   * @param n the index number of the {@link GeneAssociation} annotation to get.
648   <p>
649   * @return the nth {@link GeneAssociation} annotation in the {@link ListOfGeneAssociations}.
650   */ public
651 GeneAssociation getGeneAssociation(long n) {
652    long cPtr = libsbmlJNI.FbcModelPlugin_getGeneAssociation__SWIG_0(swigCPtr, this, n);
653    return (cPtr == 0) ? null : new GeneAssociation(cPtr, false);
654  }
655
656  
657/**
658   * Returns the {@link GeneAssociation} annotation object based on its identifier.
659   <p>
660   * @param sid a string representing the identifier 
661   * of the {@link GeneAssociation} annotation to get.
662   <p>
663   * @return {@link GeneAssociation} annotation in the {@link ListOfGeneAssociations} with the given <code>sid</code>
664   * or null if no such {@link GeneAssociation} annotation exists.
665   <p>
666   * @see #getGeneAssociation(long n)
667   * @see #getListOfGeneAssociations()
668   */ public
669 GeneAssociation getGeneAssociation(String sid) {
670    long cPtr = libsbmlJNI.FbcModelPlugin_getGeneAssociation__SWIG_2(swigCPtr, this, sid);
671    return (cPtr == 0) ? null : new GeneAssociation(cPtr, false);
672  }
673
674  
675/**
676   * Adds a copy of the given {@link GeneAssociation} annotation object to the list of GeneAssociations.
677   <p>
678   * @param association the {@link GeneAssociation} annotation object to be added to the list of GeneAssociations.
679   <p>
680   * <p>
681 * @return integer value indicating success/failure of the
682 * function.   The possible values
683 * returned by this function are:
684   * <ul>
685   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
686   * </ul>
687   */ public
688 int addGeneAssociation(GeneAssociation association) {
689    return libsbmlJNI.FbcModelPlugin_addGeneAssociation(swigCPtr, this, GeneAssociation.getCPtr(association), association);
690  }
691
692  
693/**
694   * Creates a new {@link GeneAssociation} annotation object and adds it to the list of {@link GeneAssociation} objects
695   * and returns it.
696   <p>
697   * @return a newly created {@link GeneAssociation} annotation object
698   */ public
699 GeneAssociation createGeneAssociation() {
700    long cPtr = libsbmlJNI.FbcModelPlugin_createGeneAssociation(swigCPtr, this);
701    return (cPtr == 0) ? null : new GeneAssociation(cPtr, false);
702  }
703
704  
705/**
706   * Removes the nth {@link GeneAssociation} annotation object from this plugin object and
707   * returns a pointer to it.
708   <p>
709   * The caller owns the returned object and is responsible for
710   *  deleting it.
711   <p>
712   * @param n the index of the {@link GeneAssociation} annotation object to remove
713   <p>
714   * @return the {@link GeneAssociation} annotation object removed.  As mentioned above, the 
715   * caller owns the returned object. <code>null</code> is returned if the 
716   * given index is out of range.
717   */ public
718 GeneAssociation removeGeneAssociation(long n) {
719    long cPtr = libsbmlJNI.FbcModelPlugin_removeGeneAssociation__SWIG_0(swigCPtr, this, n);
720    return (cPtr == 0) ? null : new GeneAssociation(cPtr, false);
721  }
722
723  
724/**
725   * Removes the {@link GeneAssociation} annotation object with the given <code>sid</code> attribute from 
726   * this plugin object and returns a pointer to it.
727   <p>
728   * The caller owns the returned object and is responsible for
729   * deleting it.
730   <p>
731   * @param sid the id attribute of the {@link GeneAssociation} annotation object to remove
732   <p>
733   * @return the {@link GeneAssociation} annotation object removed.  As mentioned above, the 
734   * caller owns the returned object. <code>null</code> is returned if the 
735   * given index is out of range.
736   */ public
737 GeneAssociation removeGeneAssociation(String sid) {
738    long cPtr = libsbmlJNI.FbcModelPlugin_removeGeneAssociation__SWIG_1(swigCPtr, this, sid);
739    return (cPtr == 0) ? null : new GeneAssociation(cPtr, false);
740  }
741
742  
743/**
744   * Returns the number of {@link GeneAssociation} annotation object in this plugin object.
745   <p>
746   * @return the number of {@link GeneAssociation} annotation object in this plugin object.
747   */ public
748 int getNumGeneAssociations() {
749    return libsbmlJNI.FbcModelPlugin_getNumGeneAssociations(swigCPtr, this);
750  }
751
752  
753/** * @internal */ public
754 void connectToChild() {
755    libsbmlJNI.FbcModelPlugin_connectToChild(swigCPtr, this);
756  }
757
758  
759/** * @internal */ public
760 void connectToParent(SBase sbase) {
761    libsbmlJNI.FbcModelPlugin_connectToParent(swigCPtr, this, SBase.getCPtr(sbase), sbase);
762  }
763
764  
765/** * @internal */ public
766 void enablePackageInternal(String pkgURI, String pkgPrefix, boolean flag) {
767    libsbmlJNI.FbcModelPlugin_enablePackageInternal(swigCPtr, this, pkgURI, pkgPrefix, flag);
768  }
769
770}