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-groups"><a href="group__groups.html">groups</a></span>
013 A member of a {@link Group}.
014 <p>
015 * {@link Member} class objects are used to define what constitutes a 'group' in the
016 * SBML Level&nbsp;3 {@link Group} package.  {@link Member} objects reference other SBML
017 * components in an SBML document.  A {@link Member} has four optional attributes:
018 * 'id' and 'name', which identify the element, and 'idRef' and 'metaIdRef'
019 * which reference the identifiers of other elements.
020 <p>
021 * There must be exactly one (and only one) method used to reference another
022 * element: either 'idRef' or 'metaIdRef' may be defined, but not both.
023 * (Multiple attributes are needed to account for the different types of
024 * identifiers that a given object may have.) The referenced object
025 * (including, potentially, another {@link Group} object) is thus made a member of
026 * the {@link Group} in which the {@link Member} object is contained.
027 <p>
028 * Since {@link Member} is derived from {@link SBase}, which provides both the ability to
029 * attach {@link SBO} terms as well as MIRIAM annotations, the semantics of a given
030 * member in a model can be made more precise by reference to external
031 * controlled vocabularies and ontologies.
032 <p>
033 * <h2>Membership in a {@link Group} object</h2>
034 <p>
035 * If an SBML element is referenced by a {@link Group}'s child {@link Member} (directly or
036 * indirectly), it is considered to be a member of that {@link Group}.  If the same
037 * element is referenced by multiple {@link Member} objects, this is equivalent to
038 * including it just once.  (It is considered best practice to avoid this,
039 * but does not make for an invalid SBML document.)
040 <p>
041 * Children of referenced elements are not considered to be members of the
042 * Group: a {@link KineticLaw} of a referenced {@link Reaction} is not itself a {@link Group}
043 * member. Even the membership of so-called SBML container classes (e.g.,
044 * {@link ListOfSpecies}, {@link ListOfCompartments}, etc.) does not imply inclusion of
045 * children as members of the {@link Group}. The sole exception to this rule is the
046 * handling of {@link ListOfMembers} class.
047 <p>
048 * Please refer to the description of the {@link Group} class for more information
049 * about groups, members, and the semantics of group membership.
050 <p>
051 * @see Group
052 * @see ListOfGroups
053 * @see ListOfMembers
054 */
055
056public class Member extends SBase {
057   private long swigCPtr;
058
059   protected Member(long cPtr, boolean cMemoryOwn)
060   {
061     super(libsbmlJNI.Member_SWIGUpcast(cPtr), cMemoryOwn);
062     swigCPtr = cPtr;
063   }
064
065   protected static long getCPtr(Member obj)
066   {
067     return (obj == null) ? 0 : obj.swigCPtr;
068   }
069
070   protected static long getCPtrAndDisown (Member obj)
071   {
072     long ptr = 0;
073
074     if (obj != null)
075     {
076       ptr             = obj.swigCPtr;
077       obj.swigCMemOwn = false;
078     }
079
080     return ptr;
081   }
082
083  protected void finalize() {
084    delete();
085  }
086
087  public synchronized void delete() {
088    if (swigCPtr != 0) {
089      if (swigCMemOwn) {
090        swigCMemOwn = false;
091        libsbmlJNI.delete_Member(swigCPtr);
092      }
093      swigCPtr = 0;
094    }
095    super.delete();
096  }
097
098  
099/**
100   * Creates a new {@link Member} using the given SBML Level, Version and
101   * &ldquo;groups&rdquo; package version.
102   <p>
103   * @param level a long integer, the SBML Level to assign to this {@link Member}.
104   <p>
105   * @param version a long integer, the SBML Version to assign to this {@link Member}.
106   <p>
107   * @param pkgVersion a long integer, the SBML Groups Version to assign to
108   * this {@link Member}.
109   <p>
110   * @throws SBMLConstructorException
111   * Thrown if the given <code>level</code> and <code>version</code> combination, or this kind of
112   * SBML object, are either invalid or mismatched with respect to the parent
113   * {@link SBMLDocument} object.
114   * <p>
115 * @note Attempting to add an object to an {@link SBMLDocument} having a different
116 * combination of SBML Level, Version and XML namespaces than the object
117 * itself will result in an error at the time a caller attempts to make the
118 * addition.  A parent object must have compatible Level, Version and XML
119 * namespaces.  (Strictly speaking, a parent may also have more XML
120 * namespaces than a child, but the reverse is not permitted.)  The
121 * restriction is necessary to ensure that an SBML model has a consistent
122 * overall structure.  This requires callers to manage their objects
123 * carefully, but the benefit is increased flexibility in how models can be
124 * created by permitting callers to create objects bottom-up if desired.  In
125 * situations where objects are not yet attached to parents (e.g.,
126 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help
127 * libSBML determine such things as whether it is valid to assign a
128 * particular value to an attribute.
129   */ public
130 Member(long level, long version, long pkgVersion) throws org.sbml.libsbml.SBMLConstructorException {
131    this(libsbmlJNI.new_Member__SWIG_0(level, version, pkgVersion), true);
132  }
133
134  
135/**
136   * Creates a new {@link Member} using the given SBML Level, Version and
137   * &ldquo;groups&rdquo; package version.
138   <p>
139   * @param level a long integer, the SBML Level to assign to this {@link Member}.
140   <p>
141   * @param version a long integer, the SBML Version to assign to this {@link Member}.
142   <p>
143   * @param pkgVersion a long integer, the SBML Groups Version to assign to
144   * this {@link Member}.
145   <p>
146   * @throws SBMLConstructorException
147   * Thrown if the given <code>level</code> and <code>version</code> combination, or this kind of
148   * SBML object, are either invalid or mismatched with respect to the parent
149   * {@link SBMLDocument} object.
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.
165   */ public
166 Member(long level, long version) throws org.sbml.libsbml.SBMLConstructorException {
167    this(libsbmlJNI.new_Member__SWIG_1(level, version), true);
168  }
169
170  
171/**
172   * Creates a new {@link Member} using the given SBML Level, Version and
173   * &ldquo;groups&rdquo; package version.
174   <p>
175   * @param level a long integer, the SBML Level to assign to this {@link Member}.
176   <p>
177   * @param version a long integer, the SBML Version to assign to this {@link Member}.
178   <p>
179   * @param pkgVersion a long integer, the SBML Groups Version to assign to
180   * this {@link Member}.
181   <p>
182   * @throws SBMLConstructorException
183   * Thrown if the given <code>level</code> and <code>version</code> combination, or this kind of
184   * SBML object, are either invalid or mismatched with respect to the parent
185   * {@link SBMLDocument} object.
186   * <p>
187 * @note Attempting to add an object to an {@link SBMLDocument} having a different
188 * combination of SBML Level, Version and XML namespaces than the object
189 * itself will result in an error at the time a caller attempts to make the
190 * addition.  A parent object must have compatible Level, Version and XML
191 * namespaces.  (Strictly speaking, a parent may also have more XML
192 * namespaces than a child, but the reverse is not permitted.)  The
193 * restriction is necessary to ensure that an SBML model has a consistent
194 * overall structure.  This requires callers to manage their objects
195 * carefully, but the benefit is increased flexibility in how models can be
196 * created by permitting callers to create objects bottom-up if desired.  In
197 * situations where objects are not yet attached to parents (e.g.,
198 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help
199 * libSBML determine such things as whether it is valid to assign a
200 * particular value to an attribute.
201   */ public
202 Member(long level) throws org.sbml.libsbml.SBMLConstructorException {
203    this(libsbmlJNI.new_Member__SWIG_2(level), true);
204  }
205
206  
207/**
208   * Creates a new {@link Member} using the given SBML Level, Version and
209   * &ldquo;groups&rdquo; package version.
210   <p>
211   * @param level a long integer, the SBML Level to assign to this {@link Member}.
212   <p>
213   * @param version a long integer, the SBML Version to assign to this {@link Member}.
214   <p>
215   * @param pkgVersion a long integer, the SBML Groups Version to assign to
216   * this {@link Member}.
217   <p>
218   * @throws SBMLConstructorException
219   * Thrown if the given <code>level</code> and <code>version</code> combination, or this kind of
220   * SBML object, are either invalid or mismatched with respect to the parent
221   * {@link SBMLDocument} object.
222   * <p>
223 * @note Attempting to add an object to an {@link SBMLDocument} having a different
224 * combination of SBML Level, Version and XML namespaces than the object
225 * itself will result in an error at the time a caller attempts to make the
226 * addition.  A parent object must have compatible Level, Version and XML
227 * namespaces.  (Strictly speaking, a parent may also have more XML
228 * namespaces than a child, but the reverse is not permitted.)  The
229 * restriction is necessary to ensure that an SBML model has a consistent
230 * overall structure.  This requires callers to manage their objects
231 * carefully, but the benefit is increased flexibility in how models can be
232 * created by permitting callers to create objects bottom-up if desired.  In
233 * situations where objects are not yet attached to parents (e.g.,
234 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help
235 * libSBML determine such things as whether it is valid to assign a
236 * particular value to an attribute.
237   */ public
238 Member() throws org.sbml.libsbml.SBMLConstructorException {
239    this(libsbmlJNI.new_Member__SWIG_3(), true);
240  }
241
242  
243/**
244   * Creates a new {@link Member} using the given {@link GroupsPkgNamespaces} object.
245   <p>
246   * @param groupsns the {@link GroupsPkgNamespaces} object.
247   <p>
248   * @throws SBMLConstructorException
249   * Thrown if the given <code>level</code> and <code>version</code> combination, or this kind of
250   * SBML object, are either invalid or mismatched with respect to the parent
251   * {@link SBMLDocument} object.
252   * <p>
253 * @note Attempting to add an object to an {@link SBMLDocument} having a different
254 * combination of SBML Level, Version and XML namespaces than the object
255 * itself will result in an error at the time a caller attempts to make the
256 * addition.  A parent object must have compatible Level, Version and XML
257 * namespaces.  (Strictly speaking, a parent may also have more XML
258 * namespaces than a child, but the reverse is not permitted.)  The
259 * restriction is necessary to ensure that an SBML model has a consistent
260 * overall structure.  This requires callers to manage their objects
261 * carefully, but the benefit is increased flexibility in how models can be
262 * created by permitting callers to create objects bottom-up if desired.  In
263 * situations where objects are not yet attached to parents (e.g.,
264 * {@link SBMLDocument}), knowledge of the intented SBML Level and Version help
265 * libSBML determine such things as whether it is valid to assign a
266 * particular value to an attribute.
267   */ public
268 Member(GroupsPkgNamespaces groupsns) throws org.sbml.libsbml.SBMLConstructorException {
269    this(libsbmlJNI.new_Member__SWIG_4(GroupsPkgNamespaces.getCPtr(groupsns), groupsns), true);
270  }
271
272  
273/**
274   * Copy constructor for {@link Member}.
275   <p>
276   * @param orig the {@link Member} instance to copy.
277   */ public
278 Member(Member orig) throws org.sbml.libsbml.SBMLConstructorException {
279    this(libsbmlJNI.new_Member__SWIG_5(Member.getCPtr(orig), orig), true);
280  }
281
282  
283/**
284   * Creates and returns a deep copy of this {@link Member} object.
285   <p>
286   * @return a (deep) copy of this {@link Member} object.
287   */ public
288 Member cloneObject() {
289    long cPtr = libsbmlJNI.Member_cloneObject(swigCPtr, this);
290    return (cPtr == 0) ? null : new Member(cPtr, true);
291  }
292
293  
294/**
295   * Returns the value of the 'id' attribute of this {@link Member}.
296   <p>
297   * @return the value of the 'id' attribute of this {@link Member} as a string.
298   */ public
299 String getId() {
300    return libsbmlJNI.Member_getId(swigCPtr, this);
301  }
302
303  
304/**
305   * Returns the value of the 'name' attribute of this {@link Member}.
306   <p>
307   * @return the value of the 'name' attribute of this {@link Member} as a string.
308   */ public
309 String getName() {
310    return libsbmlJNI.Member_getName(swigCPtr, this);
311  }
312
313  
314/**
315   * Returns the value of the 'idRef' attribute of this {@link Member}.
316   <p>
317   * <p>
318 * The attributes 'idRef' and 'metaIdRef' on {@link Member} are used to reference the
319 * identifiers of other components in a model in order to include them as
320 * members of a {@link Group}.  There must be exactly one (and only one) method used
321 * to reference another element: either 'idRef' or 'metaIdRef' may be
322 * defined, but not both.  The value must be the identifier of an object
323 * elsewhere in the {@link Model}.  (Object identifiers are usually set by attributes
324 * named 'id'; thus, the 'idRef' value will usually be the 'id' value of an
325 * object in the {@link Model}.)  An example value of 'idRef' might be the identifier
326 * of a species in the model, or the identifier of a {@link Group} object.  The
327 * namespace in which the <code>SId</code> value is to be found is the
328 * <code>SId</code> namespace of the {@link Model} to which the {@link Group} belongs.
329 * Conversely, elements with 'id' values that are not part of the SId
330 * namespace may <em>not</em> be referenced by this 'idRef' attribute.  In SBML
331 * Level&nbsp;3 Version&nbsp;1, this includes the {@link Unit} and {@link LocalParameter}
332 * objects.
333   <p>
334   * @return the value of the 'idRef' attribute of this {@link Member} as a string.
335   */ public
336 String getIdRef() {
337    return libsbmlJNI.Member_getIdRef(swigCPtr, this);
338  }
339
340  
341/**
342   * Returns the value of the 'metaIdRef' attribute of this {@link Member}.
343   <p>
344   * <p>
345 * The attributes 'idRef' and 'metaIdRef' on {@link Member} are used to reference the
346 * identifiers of other components in a model in order to include them as
347 * members of a {@link Group}.  There must be exactly one (and only one) method used
348 * to reference another element: either 'idRef' or 'metaIdRef' may be
349 * defined, but not both.  The 'metaIdRef' attribute takes a value of type
350 * <code>IDREF</code>.  This attribute is used to refer to a 'metaid'
351 * attribute value on any other object in the {@link Model}, for cases where the
352 * object being referenced does not have an identifier in the {@link Model} SId
353 * namespace.  (This is the case with, for example, units and rules in SBML
354 * Level&nbsp;3 Version&nbsp;1.)  Since meta identifiers are optional
355 * attributes of {@link SBase}, all SBML objects have the potential to have a meta
356 * identifier value, including most elements from other SBML packages.
357 <p>
358 * Note that even if used in conjunction with the SBML Level&nbsp;3
359 * Hierarchical {@link Model} Composition package, this attribute is not allowed to
360 * reference elements that reside within other {@link Model} objects in the same SBML
361 * Document.  Referenced elements must be normal members of the parent {@link Model}
362 * containing the {@link Member} object, and submodel elements may be normally
363 * accessed by creating replacements.
364   <p>
365   * @return the value of the 'metaIdRef' attribute of this {@link Member} as a string.
366   */ public
367 String getMetaIdRef() {
368    return libsbmlJNI.Member_getMetaIdRef(swigCPtr, this);
369  }
370
371  
372/**
373   * Predicate returning <code>true</code> if this {@link Member}'s 'id' attribute is set.
374   <p>
375   * @return <code>true</code> if this {@link Member}'s 'id' attribute has been set, otherwise @c
376   * false is returned.
377   */ public
378 boolean isSetId() {
379    return libsbmlJNI.Member_isSetId(swigCPtr, this);
380  }
381
382  
383/**
384   * Predicate returning <code>true</code> if this {@link Member}'s 'name' attribute is set.
385   <p>
386   * @return <code>true</code> if this {@link Member}'s 'name' attribute has been set, otherwise
387   * <code>false</code> is returned.
388   */ public
389 boolean isSetName() {
390    return libsbmlJNI.Member_isSetName(swigCPtr, this);
391  }
392
393  
394/**
395   * Predicate returning <code>true</code> if this {@link Member}'s 'idRef' attribute is set.
396   <p>
397   * <p>
398 * The attributes 'idRef' and 'metaIdRef' on {@link Member} are used to reference the
399 * identifiers of other components in a model in order to include them as
400 * members of a {@link Group}.  There must be exactly one (and only one) method used
401 * to reference another element: either 'idRef' or 'metaIdRef' may be
402 * defined, but not both.  The value must be the identifier of an object
403 * elsewhere in the {@link Model}.  (Object identifiers are usually set by attributes
404 * named 'id'; thus, the 'idRef' value will usually be the 'id' value of an
405 * object in the {@link Model}.)  An example value of 'idRef' might be the identifier
406 * of a species in the model, or the identifier of a {@link Group} object.  The
407 * namespace in which the <code>SId</code> value is to be found is the
408 * <code>SId</code> namespace of the {@link Model} to which the {@link Group} belongs.
409 * Conversely, elements with 'id' values that are not part of the SId
410 * namespace may <em>not</em> be referenced by this 'idRef' attribute.  In SBML
411 * Level&nbsp;3 Version&nbsp;1, this includes the {@link Unit} and {@link LocalParameter}
412 * objects.
413   <p>
414   * @return <code>true</code> if this {@link Member}'s 'idRef' attribute has been set, otherwise
415   * <code>false</code> is returned.
416   */ public
417 boolean isSetIdRef() {
418    return libsbmlJNI.Member_isSetIdRef(swigCPtr, this);
419  }
420
421  
422/**
423   * Predicate returning <code>true</code> if this {@link Member}'s 'metaIdRef' attribute is set.
424   <p>
425   * <p>
426 * The attributes 'idRef' and 'metaIdRef' on {@link Member} are used to reference the
427 * identifiers of other components in a model in order to include them as
428 * members of a {@link Group}.  There must be exactly one (and only one) method used
429 * to reference another element: either 'idRef' or 'metaIdRef' may be
430 * defined, but not both.  The 'metaIdRef' attribute takes a value of type
431 * <code>IDREF</code>.  This attribute is used to refer to a 'metaid'
432 * attribute value on any other object in the {@link Model}, for cases where the
433 * object being referenced does not have an identifier in the {@link Model} SId
434 * namespace.  (This is the case with, for example, units and rules in SBML
435 * Level&nbsp;3 Version&nbsp;1.)  Since meta identifiers are optional
436 * attributes of {@link SBase}, all SBML objects have the potential to have a meta
437 * identifier value, including most elements from other SBML packages.
438 <p>
439 * Note that even if used in conjunction with the SBML Level&nbsp;3
440 * Hierarchical {@link Model} Composition package, this attribute is not allowed to
441 * reference elements that reside within other {@link Model} objects in the same SBML
442 * Document.  Referenced elements must be normal members of the parent {@link Model}
443 * containing the {@link Member} object, and submodel elements may be normally
444 * accessed by creating replacements.
445   <p>
446   * @return <code>true</code> if this {@link Member}'s 'metaIdRef' attribute has been set,
447   * otherwise <code>false</code> is returned.
448   */ public
449 boolean isSetMetaIdRef() {
450    return libsbmlJNI.Member_isSetMetaIdRef(swigCPtr, this);
451  }
452
453  
454/**
455   * Sets the value of the 'id' attribute of this {@link Member}.
456   <p>
457   * @param id String& value of the 'id' attribute to be set.
458   <p>
459   * <p>
460 * @return integer value indicating success/failure of the
461 * function.   The possible values
462 * returned by this function are:
463   * <ul>
464   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
465   * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE}
466   * </ul>
467   */ public
468 int setId(String id) {
469    return libsbmlJNI.Member_setId(swigCPtr, this, id);
470  }
471
472  
473/**
474   * Sets the value of the 'name' attribute of this {@link Member}.
475   <p>
476   * @param name String& value of the 'name' attribute to be set.
477   <p>
478   * <p>
479 * @return integer value indicating success/failure of the
480 * function.   The possible values
481 * returned by this function are:
482   * <ul>
483   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
484   * </ul>
485   */ public
486 int setName(String name) {
487    return libsbmlJNI.Member_setName(swigCPtr, this, name);
488  }
489
490  
491/**
492   * Sets the value of the 'idRef' attribute of this {@link Member}.
493   <p>
494   * <p>
495 * The attributes 'idRef' and 'metaIdRef' on {@link Member} are used to reference the
496 * identifiers of other components in a model in order to include them as
497 * members of a {@link Group}.  There must be exactly one (and only one) method used
498 * to reference another element: either 'idRef' or 'metaIdRef' may be
499 * defined, but not both.  The value must be the identifier of an object
500 * elsewhere in the {@link Model}.  (Object identifiers are usually set by attributes
501 * named 'id'; thus, the 'idRef' value will usually be the 'id' value of an
502 * object in the {@link Model}.)  An example value of 'idRef' might be the identifier
503 * of a species in the model, or the identifier of a {@link Group} object.  The
504 * namespace in which the <code>SId</code> value is to be found is the
505 * <code>SId</code> namespace of the {@link Model} to which the {@link Group} belongs.
506 * Conversely, elements with 'id' values that are not part of the SId
507 * namespace may <em>not</em> be referenced by this 'idRef' attribute.  In SBML
508 * Level&nbsp;3 Version&nbsp;1, this includes the {@link Unit} and {@link LocalParameter}
509 * objects.
510   <p>
511   * @param idRef String& value of the 'idRef' attribute to be set.
512   <p>
513   * <p>
514 * @return integer value indicating success/failure of the
515 * function.   The possible values
516 * returned by this function are:
517   * <ul>
518   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
519   * <li> {@link libsbmlConstants#LIBSBML_INVALID_ATTRIBUTE_VALUE LIBSBML_INVALID_ATTRIBUTE_VALUE}
520   * </ul>
521   */ public
522 int setIdRef(String idRef) {
523    return libsbmlJNI.Member_setIdRef(swigCPtr, this, idRef);
524  }
525
526  
527/**
528   * Sets the value of the 'metaIdRef' attribute of this {@link Member}.
529   <p>
530   * <p>
531 * The attributes 'idRef' and 'metaIdRef' on {@link Member} are used to reference the
532 * identifiers of other components in a model in order to include them as
533 * members of a {@link Group}.  There must be exactly one (and only one) method used
534 * to reference another element: either 'idRef' or 'metaIdRef' may be
535 * defined, but not both.  The 'metaIdRef' attribute takes a value of type
536 * <code>IDREF</code>.  This attribute is used to refer to a 'metaid'
537 * attribute value on any other object in the {@link Model}, for cases where the
538 * object being referenced does not have an identifier in the {@link Model} SId
539 * namespace.  (This is the case with, for example, units and rules in SBML
540 * Level&nbsp;3 Version&nbsp;1.)  Since meta identifiers are optional
541 * attributes of {@link SBase}, all SBML objects have the potential to have a meta
542 * identifier value, including most elements from other SBML packages.
543 <p>
544 * Note that even if used in conjunction with the SBML Level&nbsp;3
545 * Hierarchical {@link Model} Composition package, this attribute is not allowed to
546 * reference elements that reside within other {@link Model} objects in the same SBML
547 * Document.  Referenced elements must be normal members of the parent {@link Model}
548 * containing the {@link Member} object, and submodel elements may be normally
549 * accessed by creating replacements.
550   <p>
551   * @param metaIdRef String& value of the 'metaIdRef' attribute to be
552   * set.
553   <p>
554   * <p>
555 * @return integer value indicating success/failure of the
556 * function.   The possible values
557 * returned by this function are:
558   * <ul>
559   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
560   * </ul>
561   */ public
562 int setMetaIdRef(String metaIdRef) {
563    return libsbmlJNI.Member_setMetaIdRef(swigCPtr, this, metaIdRef);
564  }
565
566  
567/**
568   * Unsets the value of the 'id' attribute of this {@link Member}.
569   <p>
570   * <p>
571 * @return integer value indicating success/failure of the
572 * function.   The possible values
573 * returned by this function are:
574   * <ul>
575   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
576   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED}
577   * </ul>
578   */ public
579 int unsetId() {
580    return libsbmlJNI.Member_unsetId(swigCPtr, this);
581  }
582
583  
584/**
585   * Unsets the value of the 'name' attribute of this {@link Member}.
586   <p>
587   * <p>
588 * @return integer value indicating success/failure of the
589 * function.   The possible values
590 * returned by this function are:
591   * <ul>
592   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
593   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED}
594   * </ul>
595   */ public
596 int unsetName() {
597    return libsbmlJNI.Member_unsetName(swigCPtr, this);
598  }
599
600  
601/**
602   * Unsets the value of the 'idRef' attribute of this {@link Member}.
603   <p>
604   * <p>
605 * The attributes 'idRef' and 'metaIdRef' on {@link Member} are used to reference the
606 * identifiers of other components in a model in order to include them as
607 * members of a {@link Group}.  There must be exactly one (and only one) method used
608 * to reference another element: either 'idRef' or 'metaIdRef' may be
609 * defined, but not both.  The value must be the identifier of an object
610 * elsewhere in the {@link Model}.  (Object identifiers are usually set by attributes
611 * named 'id'; thus, the 'idRef' value will usually be the 'id' value of an
612 * object in the {@link Model}.)  An example value of 'idRef' might be the identifier
613 * of a species in the model, or the identifier of a {@link Group} object.  The
614 * namespace in which the <code>SId</code> value is to be found is the
615 * <code>SId</code> namespace of the {@link Model} to which the {@link Group} belongs.
616 * Conversely, elements with 'id' values that are not part of the SId
617 * namespace may <em>not</em> be referenced by this 'idRef' attribute.  In SBML
618 * Level&nbsp;3 Version&nbsp;1, this includes the {@link Unit} and {@link LocalParameter}
619 * objects.
620   <p>
621   * <p>
622 * @return integer value indicating success/failure of the
623 * function.   The possible values
624 * returned by this function are:
625   * <ul>
626   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
627   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED}
628   * </ul>
629   */ public
630 int unsetIdRef() {
631    return libsbmlJNI.Member_unsetIdRef(swigCPtr, this);
632  }
633
634  
635/**
636   * Unsets the value of the 'metaIdRef' attribute of this {@link Member}.
637   <p>
638   * <p>
639 * The attributes 'idRef' and 'metaIdRef' on {@link Member} are used to reference the
640 * identifiers of other components in a model in order to include them as
641 * members of a {@link Group}.  There must be exactly one (and only one) method used
642 * to reference another element: either 'idRef' or 'metaIdRef' may be
643 * defined, but not both.  The 'metaIdRef' attribute takes a value of type
644 * <code>IDREF</code>.  This attribute is used to refer to a 'metaid'
645 * attribute value on any other object in the {@link Model}, for cases where the
646 * object being referenced does not have an identifier in the {@link Model} SId
647 * namespace.  (This is the case with, for example, units and rules in SBML
648 * Level&nbsp;3 Version&nbsp;1.)  Since meta identifiers are optional
649 * attributes of {@link SBase}, all SBML objects have the potential to have a meta
650 * identifier value, including most elements from other SBML packages.
651 <p>
652 * Note that even if used in conjunction with the SBML Level&nbsp;3
653 * Hierarchical {@link Model} Composition package, this attribute is not allowed to
654 * reference elements that reside within other {@link Model} objects in the same SBML
655 * Document.  Referenced elements must be normal members of the parent {@link Model}
656 * containing the {@link Member} object, and submodel elements may be normally
657 * accessed by creating replacements.
658   <p>
659   * <p>
660 * @return integer value indicating success/failure of the
661 * function.   The possible values
662 * returned by this function are:
663   * <ul>
664   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_SUCCESS LIBSBML_OPERATION_SUCCESS}
665   * <li> {@link libsbmlConstants#LIBSBML_OPERATION_FAILED LIBSBML_OPERATION_FAILED}
666   * </ul>
667   */ public
668 int unsetMetaIdRef() {
669    return libsbmlJNI.Member_unsetMetaIdRef(swigCPtr, this);
670  }
671
672  
673/**
674   * <p>
675 * Replaces all uses of a given <code>SIdRef</code> type attribute value with another
676 * value.
677 <p>
678 * <p>
679 * In SBML, object identifiers are of a data type called <code>SId</code>.
680 * In SBML Level&nbsp;3, an explicit data type called <code>SIdRef</code> was
681 * introduced for attribute values that refer to <code>SId</code> values; in
682 * previous Levels of SBML, this data type did not exist and attributes were
683 * simply described to as 'referring to an identifier', but the effective
684 * data type was the same as <code>SIdRef</code>in Level&nbsp;3.  These and
685 * other methods of libSBML refer to the type <code>SIdRef</code> for all
686 * Levels of SBML, even if the corresponding SBML specification did not
687 * explicitly name the data type.
688 <p>
689 * This method works by looking at all attributes and (if appropriate)
690 * mathematical formulas in MathML content, comparing the referenced
691 * identifiers to the value of <code>oldid</code>.  If any matches are found, the
692 * matching values are replaced with <code>newid</code>.  The method does <em>not</em>
693 * descend into child elements.
694 <p>
695 * @param oldid the old identifier
696 * @param newid the new identifier
697   */ public
698 void renameSIdRefs(String oldid, String newid) {
699    libsbmlJNI.Member_renameSIdRefs(swigCPtr, this, oldid, newid);
700  }
701
702  
703/**
704   * Returns the XML element name of this {@link Member} object.
705   <p>
706   * For {@link Member}, the XML element name is always <code>'member'.</code>
707   <p>
708   * @return the name of this element, i.e. <code>'member'.</code>
709   */ public
710 String getElementName() {
711    return libsbmlJNI.Member_getElementName(swigCPtr, this);
712  }
713
714  
715/**
716   * Returns the libSBML type code for this {@link Member} object.
717   <p>
718   * <p>
719 * LibSBML attaches an identifying code to every kind of SBML object.  These
720 * are integer constants known as <em>SBML type codes</em>.  The names of all
721 * the codes begin with the characters <code>SBML_</code>.
722 * In the Java language interface for libSBML, the
723 * type codes are defined as static integer constants in the interface class
724 * {@link libsbmlConstants}.    Note that different Level&nbsp;3
725 * package plug-ins may use overlapping type codes; to identify the package
726 * to which a given object belongs, call the <code>getPackageName()</code>
727 * method on the object.
728   <p>
729   * @return the SBML type code for this object:
730   <p>
731   * {@link libsbmlConstants#SBML_GROUPS_MEMBER SBML_GROUPS_MEMBER}
732   <p>
733   * <p>
734 * @warning <span class='warning'>The specific integer values of the possible
735 * type codes may be reused by different libSBML plug-ins for SBML Level&nbsp;3.
736 * packages,  To fully identify the correct code, <strong>it is necessary to
737 * invoke both getTypeCode() and getPackageName()</strong>.</span>
738   <p>
739   * @see #getElementName()
740   * @see #getPackageName()
741   */ public
742 int getTypeCode() {
743    return libsbmlJNI.Member_getTypeCode(swigCPtr, this);
744  }
745
746  
747/**
748   * Predicate returning <code>true</code> if all the required attributes for this {@link Member}
749   * object have been set.
750   <p>
751   * @return <code>true</code> to indicate that all the required attributes of this
752   * {@link Member} have been set, otherwise <code>false</code> is returned.
753   <p>
754   * @note The required attributes for the {@link Member} object are:
755   */ public
756 boolean hasRequiredAttributes() {
757    return libsbmlJNI.Member_hasRequiredAttributes(swigCPtr, this);
758  }
759
760  
761/** * @internal */ public
762 void enablePackageInternal(String pkgURI, String pkgPrefix, boolean flag) {
763    libsbmlJNI.Member_enablePackageInternal(swigCPtr, this, pkgURI, pkgPrefix, flag);
764  }
765
766  
767/** * @internal */ public
768 SBase getReferencedElement() {
769  return libsbml.DowncastSBase(libsbmlJNI.Member_getReferencedElement(swigCPtr, this), false);
770}
771
772}