1 /**
2  * @file SedDataDescription.h
3  * @brief Definition of the SedDataDescription class.
4  * @author DEVISER
5  *
6  * <!--------------------------------------------------------------------------
7  * This file is part of libSEDML. Please visit http://sed-ml.org for more
8  * information about SED-ML. The latest version of libSEDML can be found on
9  * github: https://github.com/fbergmann/libSEDML/
10  *
11 
12  * Copyright (c) 2013-2019, Frank T. Bergmann
13  * All rights reserved.
14  *
15 
16  * Redistribution and use in source and binary forms, with or without
17  * modification, are permitted provided that the following conditions are met:
18  *
19 
20  * 1. Redistributions of source code must retain the above copyright notice,
21  * this
22  * list of conditions and the following disclaimer.
23  * 2. Redistributions in binary form must reproduce the above copyright notice,
24  * this list of conditions and the following disclaimer in the documentation
25  * and/or other materials provided with the distribution.
26  *
27  * This library is free software; you can redistribute it and/or modify it
28  * under the terms of the GNU Lesser General Public License as published by the
29  * Free Software Foundation. A copy of the license agreement is provided in the
30  * file named "LICENSE.txt" included with this software distribution and also
31  * available online as http://sbml.org/software/libsbml/license.html
32  * ------------------------------------------------------------------------ -->
33  *
34  * @class SedDataDescription
35  * @sbmlbrief{sedml} TODO:Definition of the SedDataDescription class.
36  */
37 
38 
39 #ifndef SedDataDescription_H__
40 #define SedDataDescription_H__
41 
42 
43 #include <sedml/common/extern.h>
44 #include <sedml/common/sedmlfwd.h>
45 
46 
47 #ifdef __cplusplus
48 
49 
50 #include <string>
51 
52 
53 #include <sedml/SedBase.h>
54 #include <numl/DimensionDescription.h>
55 #include <sedml/SedListOfDataSources.h>
56 #include <sbml/common/libsbml-namespace.h>
57 #include <numl/common/libnuml-namespace.h>
58 
59 
60 LIBSEDML_CPP_NAMESPACE_BEGIN
61 
62 
63 class LIBSEDML_EXTERN SedDataDescription : public SedBase
64 {
65 protected:
66 
67   /** @cond doxygenLibSEDMLInternal */
68 
69   std::string mFormat;
70   std::string mSource;
71   LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription* mDimensionDescription;
72   SedListOfDataSources mDataSources;
73 
74   /** @endcond */
75 
76 public:
77 
78   /**
79    * Creates a new SedDataDescription using the given SED-ML Level and @ p
80    * version values.
81    *
82    * @param level an unsigned int, the SED-ML Level to assign to this
83    * SedDataDescription.
84    *
85    * @param version an unsigned int, the SED-ML Version to assign to this
86    * SedDataDescription.
87    *
88    * @copydetails doc_note_setting_lv_pkg
89    */
90   SedDataDescription(unsigned int level = SEDML_DEFAULT_LEVEL,
91                      unsigned int version = SEDML_DEFAULT_VERSION);
92 
93 
94   /**
95    * Creates a new SedDataDescription using the given SedNamespaces object @p
96    * sedmlns.
97    *
98    * @param sedmlns the SedNamespaces object.
99    *
100    * @copydetails doc_note_setting_lv_pkg
101    */
102   SedDataDescription(SedNamespaces *sedmlns);
103 
104 
105   /**
106    * Copy constructor for SedDataDescription.
107    *
108    * @param orig the SedDataDescription instance to copy.
109    */
110   SedDataDescription(const SedDataDescription& orig);
111 
112 
113   /**
114    * Assignment operator for SedDataDescription.
115    *
116    * @param rhs the SedDataDescription object whose values are to be used as
117    * the basis of the assignment.
118    */
119   SedDataDescription& operator=(const SedDataDescription& rhs);
120 
121 
122   /**
123    * Creates and returns a deep copy of this SedDataDescription object.
124    *
125    * @return a (deep) copy of this SedDataDescription object.
126    */
127   virtual SedDataDescription* clone() const;
128 
129 
130   /**
131    * Destructor for SedDataDescription.
132    */
133   virtual ~SedDataDescription();
134 
135 
136   /**
137    * Returns the value of the "format" attribute of this SedDataDescription.
138    *
139    * @return the value of the "format" attribute of this SedDataDescription as
140    * a string.
141    */
142   const std::string& getFormat() const;
143 
144 
145   /**
146    * Returns the value of the "source" attribute of this SedDataDescription.
147    *
148    * @return the value of the "source" attribute of this SedDataDescription as
149    * a string.
150    */
151   const std::string& getSource() const;
152 
153 
154   /**
155    * Predicate returning @c true if this SedDataDescription's "format"
156    * attribute is set.
157    *
158    * @return @c true if this SedDataDescription's "format" attribute has been
159    * set, otherwise @c false is returned.
160    */
161   bool isSetFormat() const;
162 
163 
164   /**
165    * Predicate returning @c true if this SedDataDescription's "source"
166    * attribute is set.
167    *
168    * @return @c true if this SedDataDescription's "source" attribute has been
169    * set, otherwise @c false is returned.
170    */
171   bool isSetSource() const;
172 
173 
174   /**
175    * Sets the value of the "format" attribute of this SedDataDescription.
176    *
177    * @param format std::string& value of the "format" attribute to be set.
178    *
179    * @copydetails doc_returns_one_success_code
180    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
181    *
182    * Calling this function with @p format = @c NULL or an empty string is
183    * equivalent to calling unsetFormat().
184    */
185   int setFormat(const std::string& format);
186 
187 
188   /**
189    * Sets the value of the "source" attribute of this SedDataDescription.
190    *
191    * @param source std::string& value of the "source" attribute to be set.
192    *
193    * @copydetails doc_returns_one_success_code
194    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
195    *
196    * Calling this function with @p source = @c NULL or an empty string is
197    * equivalent to calling unsetSource().
198    */
199   int setSource(const std::string& source);
200 
201 
202   /**
203    * Unsets the value of the "format" attribute of this SedDataDescription.
204    *
205    * @copydetails doc_returns_success_code
206    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
207    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
208    */
209   int unsetFormat();
210 
211 
212   /**
213    * Unsets the value of the "source" attribute of this SedDataDescription.
214    *
215    * @copydetails doc_returns_success_code
216    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
217    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
218    */
219   int unsetSource();
220 
221 
222   /**
223    * Returns the value of the "dimensionDescription" element of this
224    * SedDataDescription.
225    *
226    * @return the value of the "dimensionDescription" element of this
227    * SedDataDescription as a LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription*.
228    */
229   const LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription* getDimensionDescription() const;
230 
231 
232   /**
233    * Returns the value of the "dimensionDescription" element of this
234    * SedDataDescription.
235    *
236    * @return the value of the "dimensionDescription" element of this
237    * SedDataDescription as a LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription*.
238    */
239   LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription* getDimensionDescription();
240 
241 
242   /**
243    * Predicate returning @c true if this SedDataDescription's
244    * "dimensionDescription" element is set.
245    *
246    * @return @c true if this SedDataDescription's "dimensionDescription"
247    * element has been set, otherwise @c false is returned.
248    */
249   bool isSetDimensionDescription() const;
250 
251 
252   /**
253    * Sets the value of the "dimensionDescription" element of this
254    * SedDataDescription.
255    *
256    * @param dimensionDescription LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription* value of the
257    * "dimensionDescription" element to be set.
258    *
259    * @copydetails doc_returns_success_code
260    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
261    * @li @sedmlconstant{LIBSEDML_INVALID_ATTRIBUTE_VALUE,
262    * OperationReturnValues_t}
263    */
264   int setDimensionDescription(const LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription*
265     dimensionDescription);
266 
267 
268   /**
269    * Creates a new DimensionDescription object, adds it to this
270    * SedDataDescription object and returns the DimensionDescription object
271    * created.
272    *
273    * @return a new DimensionDescription object instance.
274    */
275   LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription* createDimensionDescription();
276 
277 
278   /**
279    * Unsets the value of the "dimensionDescription" element of this
280    * SedDataDescription.
281    *
282    * @copydetails doc_returns_success_code
283    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
284    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
285    */
286   int unsetDimensionDescription();
287 
288 
289   /**
290    * Returns the SedListOfDataSources from this SedDataDescription.
291    *
292    * @return the SedListOfDataSources from this SedDataDescription.
293    *
294    * @copydetails doc_returned_unowned_pointer
295    *
296    * @see addDataSource(const SedDataSource* object)
297    * @see createDataSource()
298    * @see getDataSource(const std::string& sid)
299    * @see getDataSource(unsigned int n)
300    * @see getNumDataSources()
301    * @see removeDataSource(const std::string& sid)
302    * @see removeDataSource(unsigned int n)
303    */
304   const SedListOfDataSources* getListOfDataSources() const;
305 
306 
307   /**
308    * Returns the SedListOfDataSources from this SedDataDescription.
309    *
310    * @return the SedListOfDataSources from this SedDataDescription.
311    *
312    * @copydetails doc_returned_unowned_pointer
313    *
314    * @see addDataSource(const SedDataSource* object)
315    * @see createDataSource()
316    * @see getDataSource(const std::string& sid)
317    * @see getDataSource(unsigned int n)
318    * @see getNumDataSources()
319    * @see removeDataSource(const std::string& sid)
320    * @see removeDataSource(unsigned int n)
321    */
322   SedListOfDataSources* getListOfDataSources();
323 
324 
325   /**
326    * Get a SedDataSource from the SedDataDescription.
327    *
328    * @param n an unsigned int representing the index of the SedDataSource to
329    * retrieve.
330    *
331    * @return the nth SedDataSource in the SedListOfDataSources within this
332    * SedDataDescription.
333    *
334    * @copydetails doc_returned_unowned_pointer
335    *
336    * @see addDataSource(const SedDataSource* object)
337    * @see createDataSource()
338    * @see getDataSource(const std::string& sid)
339    * @see getNumDataSources()
340    * @see removeDataSource(const std::string& sid)
341    * @see removeDataSource(unsigned int n)
342    */
343   SedDataSource* getDataSource(unsigned int n);
344 
345 
346   /**
347    * Get a SedDataSource from the SedDataDescription.
348    *
349    * @param n an unsigned int representing the index of the SedDataSource to
350    * retrieve.
351    *
352    * @return the nth SedDataSource in the SedListOfDataSources within this
353    * SedDataDescription.
354    *
355    * @copydetails doc_returned_unowned_pointer
356    *
357    * @see addDataSource(const SedDataSource* object)
358    * @see createDataSource()
359    * @see getDataSource(const std::string& sid)
360    * @see getNumDataSources()
361    * @see removeDataSource(const std::string& sid)
362    * @see removeDataSource(unsigned int n)
363    */
364   const SedDataSource* getDataSource(unsigned int n) const;
365 
366 
367   /**
368    * Get a SedDataSource from the SedDataDescription based on its identifier.
369    *
370    * @param sid a string representing the identifier of the SedDataSource to
371    * retrieve.
372    *
373    * @return the SedDataSource in the SedListOfDataSources within this
374    * SedDataDescription with the given @p sid or @c NULL if no such
375    * SedDataSource exists.
376    *
377    * @copydetails doc_returned_unowned_pointer
378    *
379    * @see addDataSource(const SedDataSource* object)
380    * @see createDataSource()
381    * @see getDataSource(unsigned int n)
382    * @see getNumDataSources()
383    * @see removeDataSource(const std::string& sid)
384    * @see removeDataSource(unsigned int n)
385    */
386   SedDataSource* getDataSource(const std::string& sid);
387 
388 
389   /**
390    * Get a SedDataSource from the SedDataDescription based on its identifier.
391    *
392    * @param sid a string representing the identifier of the SedDataSource to
393    * retrieve.
394    *
395    * @return the SedDataSource in the SedListOfDataSources within this
396    * SedDataDescription with the given @p sid or @c NULL if no such
397    * SedDataSource exists.
398    *
399    * @copydetails doc_returned_unowned_pointer
400    *
401    * @see addDataSource(const SedDataSource* object)
402    * @see createDataSource()
403    * @see getDataSource(unsigned int n)
404    * @see getNumDataSources()
405    * @see removeDataSource(const std::string& sid)
406    * @see removeDataSource(unsigned int n)
407    */
408   const SedDataSource* getDataSource(const std::string& sid) const;
409 
410 
411   /**
412    * Get a SedDataSource from the SedDataDescription based on the IndexSet to
413    * which it refers.
414    *
415    * @param sid a string representing the "indexSet" attribute of the
416    * SedDataSource object to retrieve.
417    *
418    * @return the first SedDataSource in this SedDataDescription based on the
419    * given indexSet attribute or NULL if no such SedDataSource exists.
420    *
421    * @copydetails doc_returned_unowned_pointer
422    */
423   const SedDataSource* getDataSourceByIndexSet(const std::string& sid) const;
424 
425 
426   /**
427    * Get a SedDataSource from the SedDataDescription based on the IndexSet to
428    * which it refers.
429    *
430    * @param sid a string representing the "indexSet" attribute of the
431    * SedDataSource object to retrieve.
432    *
433    * @return the first SedDataSource in this SedDataDescription based on the
434    * given indexSet attribute or NULL if no such SedDataSource exists.
435    *
436    * @copydetails doc_returned_unowned_pointer
437    */
438   SedDataSource* getDataSourceByIndexSet(const std::string& sid);
439 
440 
441   /**
442    * Adds a copy of the given SedDataSource to this SedDataDescription.
443    *
444    * @param sds the SedDataSource object to add.
445    *
446    * @copydetails doc_returns_success_code
447    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
448    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
449    * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
450    * @li @sedmlconstant{LIBSEDML_LEVEL_MISMATCH, OperationReturnValues_t}
451    * @li @sedmlconstant{LIBSEDML_VERSION_MISMATCH, OperationReturnValues_t}
452    * @li @sedmlconstant{LIBSEDML_PKG_VERSION_MISMATCH, OperationReturnValues_t}
453    * @li @sedmlconstant{LIBSEDML_DUPLICATE_OBJECT_ID, OperationReturnValues_t}
454    *
455    * @copydetails doc_note_object_is_copied
456    *
457    * @see createDataSource()
458    * @see getDataSource(const std::string& sid)
459    * @see getDataSource(unsigned int n)
460    * @see getNumDataSources()
461    * @see removeDataSource(const std::string& sid)
462    * @see removeDataSource(unsigned int n)
463    */
464   int addDataSource(const SedDataSource* sds);
465 
466 
467   /**
468    * Get the number of SedDataSource objects in this SedDataDescription.
469    *
470    * @return the number of SedDataSource objects in this SedDataDescription.
471    *
472    * @see addDataSource(const SedDataSource* object)
473    * @see createDataSource()
474    * @see getDataSource(const std::string& sid)
475    * @see getDataSource(unsigned int n)
476    * @see removeDataSource(const std::string& sid)
477    * @see removeDataSource(unsigned int n)
478    */
479   unsigned int getNumDataSources() const;
480 
481 
482   /**
483    * Creates a new SedDataSource object, adds it to this SedDataDescription
484    * object and returns the SedDataSource object created.
485    *
486    * @return a new SedDataSource object instance.
487    *
488    * @copydetails doc_returned_unowned_pointer
489    *
490    * @see addDataSource(const SedDataSource* object)
491    * @see getDataSource(const std::string& sid)
492    * @see getDataSource(unsigned int n)
493    * @see getNumDataSources()
494    * @see removeDataSource(const std::string& sid)
495    * @see removeDataSource(unsigned int n)
496    */
497   SedDataSource* createDataSource();
498 
499 
500   /**
501    * Removes the nth SedDataSource from this SedDataDescription and returns a
502    * pointer to it.
503    *
504    * @param n an unsigned int representing the index of the SedDataSource to
505    * remove.
506    *
507    * @return a pointer to the nth SedDataSource in this SedDataDescription.
508    *
509    * @copydetails doc_returned_owned_pointer
510    *
511    * @see addDataSource(const SedDataSource* object)
512    * @see createDataSource()
513    * @see getDataSource(const std::string& sid)
514    * @see getDataSource(unsigned int n)
515    * @see getNumDataSources()
516    * @see removeDataSource(const std::string& sid)
517    */
518   SedDataSource* removeDataSource(unsigned int n);
519 
520 
521   /**
522    * Removes the SedDataSource from this SedDataDescription based on its
523    * identifier and returns a pointer to it.
524    *
525    * @param sid a string representing the identifier of the SedDataSource to
526    * remove.
527    *
528    * @return the SedDataSource in this SedDataDescription based on the
529    * identifier or NULL if no such SedDataSource exists.
530    *
531    * @copydetails doc_returned_owned_pointer
532    *
533    * @see addSedDataSource(const SedDataSource* object)
534    * @see createDataSource()
535    * @see getSedDataSource(const std::string& sid)
536    * @see getSedDataSource(unsigned int n)
537    * @see getNumDataSources()
538    * @see removeSedDataSource(unsigned int n)
539    */
540   SedDataSource* removeDataSource(const std::string& sid);
541 
542 
543   /**
544    * Returns the XML element name of this SedDataDescription object.
545    *
546    * For SedDataDescription, the XML element name is always
547    * @c "dataDescription".
548    *
549    * @return the name of this element, i.e. @c "dataDescription".
550    */
551   virtual const std::string& getElementName() const;
552 
553 
554   /**
555    * Returns the libSEDML type code for this SedDataDescription object.
556    *
557    * @copydetails doc_what_are_typecodes
558    *
559    * @return the SED-ML type code for this object:
560    * @sedmlconstant{SEDML_DATA_DESCRIPTION, SedmlmlTypeCode_t}.
561    *
562    * @copydetails doc_warning_typecodes_not_unique
563    *
564    * @see getElementName()
565    */
566   virtual int getTypeCode() const;
567 
568 
569   /**
570    * Predicate returning @c true if all the required attributes for this
571    * SedDataDescription object have been set.
572    *
573    * @return @c true to indicate that all the required attributes of this
574    * SedDataDescription have been set, otherwise @c false is returned.
575    *
576    *
577    * @note The required attributes for the SedDataDescription object are:
578    * @li "id"
579    */
580   virtual bool hasRequiredAttributes() const;
581 
582 
583 
584   /** @cond doxygenLibSEDMLInternal */
585 
586   /**
587    * Write any contained elements
588    */
589   virtual void writeElements(LIBSBML_CPP_NAMESPACE_QUALIFIER XMLOutputStream&
590     stream) const;
591 
592   /** @endcond */
593 
594 
595 
596   /** @cond doxygenLibSEDMLInternal */
597 
598   /**
599    * Accepts the given SedVisitor
600    */
601   virtual bool accept(SedVisitor& v) const;
602 
603   /** @endcond */
604 
605 
606 
607   /** @cond doxygenLibSEDMLInternal */
608 
609   /**
610    * Sets the parent SedDocument
611    */
612   virtual void setSedDocument(SedDocument* d);
613 
614   /** @endcond */
615 
616 
617 
618   /** @cond doxygenLibSEDMLInternal */
619 
620   /**
621    * Connects to child elements
622    */
623   virtual void connectToChild();
624 
625   /** @endcond */
626 
627 
628 
629 
630   #ifndef SWIG
631 
632 
633 
634   /** @cond doxygenLibSEDMLInternal */
635 
636   /**
637    * Gets the value of the "attributeName" attribute of this
638    * SedDataDescription.
639    *
640    * @param attributeName, the name of the attribute to retrieve.
641    *
642    * @param value, the address of the value to record.
643    *
644    * @copydetails doc_returns_success_code
645    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
646    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
647    */
648   virtual int getAttribute(const std::string& attributeName, bool& value)
649     const;
650 
651   /** @endcond */
652 
653 
654 
655   /** @cond doxygenLibSEDMLInternal */
656 
657   /**
658    * Gets the value of the "attributeName" attribute of this
659    * SedDataDescription.
660    *
661    * @param attributeName, the name of the attribute to retrieve.
662    *
663    * @param value, the address of the value to record.
664    *
665    * @copydetails doc_returns_success_code
666    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
667    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
668    */
669   virtual int getAttribute(const std::string& attributeName, int& value) const;
670 
671   /** @endcond */
672 
673 
674 
675   /** @cond doxygenLibSEDMLInternal */
676 
677   /**
678    * Gets the value of the "attributeName" attribute of this
679    * SedDataDescription.
680    *
681    * @param attributeName, the name of the attribute to retrieve.
682    *
683    * @param value, the address of the value to record.
684    *
685    * @copydetails doc_returns_success_code
686    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
687    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
688    */
689   virtual int getAttribute(const std::string& attributeName,
690                            double& value) const;
691 
692   /** @endcond */
693 
694 
695 
696   /** @cond doxygenLibSEDMLInternal */
697 
698   /**
699    * Gets the value of the "attributeName" attribute of this
700    * SedDataDescription.
701    *
702    * @param attributeName, the name of the attribute to retrieve.
703    *
704    * @param value, the address of the value to record.
705    *
706    * @copydetails doc_returns_success_code
707    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
708    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
709    */
710   virtual int getAttribute(const std::string& attributeName,
711                            unsigned int& value) const;
712 
713   /** @endcond */
714 
715 
716 
717   /** @cond doxygenLibSEDMLInternal */
718 
719   /**
720    * Gets the value of the "attributeName" attribute of this
721    * SedDataDescription.
722    *
723    * @param attributeName, the name of the attribute to retrieve.
724    *
725    * @param value, the address of the value to record.
726    *
727    * @copydetails doc_returns_success_code
728    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
729    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
730    */
731   virtual int getAttribute(const std::string& attributeName,
732                            std::string& value) const;
733 
734   /** @endcond */
735 
736 
737 
738   /** @cond doxygenLibSEDMLInternal */
739 
740   /**
741    * Predicate returning @c true if this SedDataDescription's attribute
742    * "attributeName" is set.
743    *
744    * @param attributeName, the name of the attribute to query.
745    *
746    * @return @c true if this SedDataDescription's attribute "attributeName" has
747    * been set, otherwise @c false is returned.
748    */
749   virtual bool isSetAttribute(const std::string& attributeName) const;
750 
751   /** @endcond */
752 
753 
754 
755   /** @cond doxygenLibSEDMLInternal */
756 
757   /**
758    * Sets the value of the "attributeName" attribute of this
759    * SedDataDescription.
760    *
761    * @param attributeName, the name of the attribute to set.
762    *
763    * @param value, the value of the attribute to set.
764    *
765    * @copydetails doc_returns_success_code
766    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
767    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
768    */
769   virtual int setAttribute(const std::string& attributeName, bool value);
770 
771   /** @endcond */
772 
773 
774 
775   /** @cond doxygenLibSEDMLInternal */
776 
777   /**
778    * Sets the value of the "attributeName" attribute of this
779    * SedDataDescription.
780    *
781    * @param attributeName, the name of the attribute to set.
782    *
783    * @param value, the value of the attribute to set.
784    *
785    * @copydetails doc_returns_success_code
786    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
787    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
788    */
789   virtual int setAttribute(const std::string& attributeName, int value);
790 
791   /** @endcond */
792 
793 
794 
795   /** @cond doxygenLibSEDMLInternal */
796 
797   /**
798    * Sets the value of the "attributeName" attribute of this
799    * SedDataDescription.
800    *
801    * @param attributeName, the name of the attribute to set.
802    *
803    * @param value, the value of the attribute to set.
804    *
805    * @copydetails doc_returns_success_code
806    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
807    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
808    */
809   virtual int setAttribute(const std::string& attributeName, double value);
810 
811   /** @endcond */
812 
813 
814 
815   /** @cond doxygenLibSEDMLInternal */
816 
817   /**
818    * Sets the value of the "attributeName" attribute of this
819    * SedDataDescription.
820    *
821    * @param attributeName, the name of the attribute to set.
822    *
823    * @param value, the value of the attribute to set.
824    *
825    * @copydetails doc_returns_success_code
826    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
827    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
828    */
829   virtual int setAttribute(const std::string& attributeName,
830                            unsigned int value);
831 
832   /** @endcond */
833 
834 
835 
836   /** @cond doxygenLibSEDMLInternal */
837 
838   /**
839    * Sets the value of the "attributeName" attribute of this
840    * SedDataDescription.
841    *
842    * @param attributeName, the name of the attribute to set.
843    *
844    * @param value, the value of the attribute to set.
845    *
846    * @copydetails doc_returns_success_code
847    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
848    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
849    */
850   virtual int setAttribute(const std::string& attributeName,
851                            const std::string& value);
852 
853   /** @endcond */
854 
855 
856 
857   /** @cond doxygenLibSEDMLInternal */
858 
859   /**
860    * Unsets the value of the "attributeName" attribute of this
861    * SedDataDescription.
862    *
863    * @param attributeName, the name of the attribute to query.
864    *
865    * @copydetails doc_returns_success_code
866    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
867    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
868    */
869   virtual int unsetAttribute(const std::string& attributeName);
870 
871   /** @endcond */
872 
873 
874 
875   /** @cond doxygenLibSEDMLInternal */
876 
877   /**
878    * Creates and returns an new "elementName" object in this
879    * SedDataDescription.
880    *
881    * @param elementName, the name of the element to create.
882    *
883    * @return pointer to the element created.
884    */
885   virtual SedBase* createChildObject(const std::string& elementName);
886 
887   /** @endcond */
888 
889 
890 
891   /** @cond doxygenLibSEDMLInternal */
892 
893   /**
894    * Adds a new "elementName" object to this SedDataDescription.
895    *
896    * @param elementName, the name of the element to create.
897    *
898    * @param element, pointer to the element to be added.
899    *
900    * @copydetails doc_returns_success_code
901    * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
902    * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
903    */
904   virtual int addChildObject(const std::string& elementName,
905                              const SedBase* element);
906 
907   /** @endcond */
908 
909 
910 
911   /** @cond doxygenLibSEDMLInternal */
912 
913   /**
914    * Removes and returns the new "elementName" object with the given id in this
915    * SedDataDescription.
916    *
917    * @param elementName, the name of the element to remove.
918    *
919    * @param id, the id of the element to remove.
920    *
921    * @return pointer to the element removed.
922    */
923   virtual SedBase* removeChildObject(const std::string& elementName,
924                                      const std::string& id);
925 
926   /** @endcond */
927 
928 
929 
930   /** @cond doxygenLibSEDMLInternal */
931 
932   /**
933    * Returns the number of "elementName" in this SedDataDescription.
934    *
935    * @param elementName, the name of the element to get number of.
936    *
937    * @return unsigned int number of elements.
938    */
939   virtual unsigned int getNumObjects(const std::string& elementName);
940 
941   /** @endcond */
942 
943 
944 
945   /** @cond doxygenLibSEDMLInternal */
946 
947   /**
948    * Returns the nth object of "objectName" in this SedDataDescription.
949    *
950    * @param elementName, the name of the element to get number of.
951    *
952    * @param index, unsigned int the index of the object to retrieve.
953    *
954    * @return pointer to the object.
955    */
956   virtual SedBase* getObject(const std::string& elementName,
957                              unsigned int index);
958 
959   /** @endcond */
960 
961 
962 
963 
964   #endif /* !SWIG */
965 
966 
967   /**
968    * Returns the first child element that has the given @p id in the model-wide
969    * SId namespace, or @c NULL if no such object is found.
970    *
971    * @param id a string representing the id attribute of the object to
972    * retrieve.
973    *
974    * @return a pointer to the SedBase element with the given @p id. If no such
975    * object is found, this method returns @c NULL.
976    */
977   virtual SedBase* getElementBySId(const std::string& id);
978 
979 
980   /**
981    * Returns a List of all child SedBase objects, including those nested to an
982    * arbitrary depth.
983    *
984    * @param filter an ElementFilter that may impose restrictions on the objects
985    * to be retrieved.
986    *
987    * @return a List pointer of pointers to all SedBase child objects with any
988    * restriction imposed.
989    */
990   virtual List* getAllElements(SedElementFilter * filter = NULL);
991 
992 
993 protected:
994 
995 
996   /** @cond doxygenLibSEDMLInternal */
997 
998   /**
999    * Creates a new object from the next XMLToken on the XMLInputStream
1000    */
1001   virtual SedBase* createObject(LIBSBML_CPP_NAMESPACE_QUALIFIER XMLInputStream&
1002     stream);
1003 
1004   /** @endcond */
1005 
1006 
1007 
1008   /** @cond doxygenLibSEDMLInternal */
1009 
1010   /**
1011    * Adds the expected attributes for this element
1012    */
1013   virtual void addExpectedAttributes(LIBSBML_CPP_NAMESPACE_QUALIFIER
1014     ExpectedAttributes& attributes);
1015 
1016   /** @endcond */
1017 
1018 
1019 
1020   /** @cond doxygenLibSEDMLInternal */
1021 
1022   /**
1023    * Reads the expected attributes into the member data variables
1024    */
1025   virtual void readAttributes(
1026                               const LIBSBML_CPP_NAMESPACE_QUALIFIER
1027                                 XMLAttributes& attributes,
1028                               const LIBSBML_CPP_NAMESPACE_QUALIFIER
1029                                 ExpectedAttributes& expectedAttributes);
1030 
1031   /** @endcond */
1032 
1033 
1034   /** @cond doxygen-libsedml-internal */
1035 
1036   /**
1037    * Subclasses should override this method ro read other XML.
1038    *
1039    * return true if read from stream, false otherwise.
1040    */
1041   virtual bool readOtherXML(LIBSBML_CPP_NAMESPACE_QUALIFIER XMLInputStream& stream);
1042 
1043 
1044   /** @endcond doxygen-libsedml-internal */
1045 
1046   /** @cond doxygenLibSEDMLInternal */
1047 
1048   /**
1049    * Writes the attributes to the stream
1050    */
1051   virtual void writeAttributes(LIBSBML_CPP_NAMESPACE_QUALIFIER XMLOutputStream&
1052     stream) const;
1053 
1054   /** @endcond */
1055 
1056 
1057 };
1058 
1059 
1060 
1061 LIBSEDML_CPP_NAMESPACE_END
1062 
1063 
1064 
1065 
1066 #endif /* __cplusplus */
1067 
1068 
1069 
1070 
1071 #ifndef SWIG
1072 
1073 
1074 
1075 
1076 LIBSEDML_CPP_NAMESPACE_BEGIN
1077 
1078 
1079 
1080 
1081 BEGIN_C_DECLS
1082 
1083 
1084 /**
1085  * Creates a new SedDataDescription_t using the given SED-ML Level and @ p
1086  * version values.
1087  *
1088  * @param level an unsigned int, the SED-ML Level to assign to this
1089  * SedDataDescription_t.
1090  *
1091  * @param version an unsigned int, the SED-ML Version to assign to this
1092  * SedDataDescription_t.
1093  *
1094  * @copydetails doc_note_setting_lv_pkg
1095  *
1096  * @copydetails doc_returned_owned_pointer
1097  *
1098  * @memberof SedDataDescription_t
1099  */
1100 LIBSEDML_EXTERN
1101 SedDataDescription_t *
1102 SedDataDescription_create(unsigned int level, unsigned int version);
1103 
1104 
1105 /**
1106  * Creates and returns a deep copy of this SedDataDescription_t object.
1107  *
1108  * @param sdd the SedDataDescription_t structure.
1109  *
1110  * @return a (deep) copy of this SedDataDescription_t object.
1111  *
1112  * @copydetails doc_returned_owned_pointer
1113  *
1114  * @memberof SedDataDescription_t
1115  */
1116 LIBSEDML_EXTERN
1117 SedDataDescription_t*
1118 SedDataDescription_clone(const SedDataDescription_t* sdd);
1119 
1120 
1121 /**
1122  * Frees this SedDataDescription_t object.
1123  *
1124  * @param sdd the SedDataDescription_t structure.
1125  *
1126  * @memberof SedDataDescription_t
1127  */
1128 LIBSEDML_EXTERN
1129 void
1130 SedDataDescription_free(SedDataDescription_t* sdd);
1131 
1132 
1133 /**
1134  * Returns the value of the "id" attribute of this SedDataDescription_t.
1135  *
1136  * @param sdd the SedDataDescription_t structure whose id is sought.
1137  *
1138  * @return the value of the "id" attribute of this SedDataDescription_t as a
1139  * pointer to a string.
1140  *
1141  * @copydetails doc_returned_owned_char
1142  *
1143  * @memberof SedDataDescription_t
1144  */
1145 LIBSEDML_EXTERN
1146 char *
1147 SedDataDescription_getId(const SedDataDescription_t * sdd);
1148 
1149 
1150 /**
1151  * Returns the value of the "name" attribute of this SedDataDescription_t.
1152  *
1153  * @param sdd the SedDataDescription_t structure whose name is sought.
1154  *
1155  * @return the value of the "name" attribute of this SedDataDescription_t as a
1156  * pointer to a string.
1157  *
1158  * @copydetails doc_returned_owned_char
1159  *
1160  * @memberof SedDataDescription_t
1161  */
1162 LIBSEDML_EXTERN
1163 char *
1164 SedDataDescription_getName(const SedDataDescription_t * sdd);
1165 
1166 
1167 /**
1168  * Returns the value of the "format" attribute of this SedDataDescription_t.
1169  *
1170  * @param sdd the SedDataDescription_t structure whose format is sought.
1171  *
1172  * @return the value of the "format" attribute of this SedDataDescription_t as
1173  * a pointer to a string.
1174  *
1175  * @copydetails doc_returned_owned_char
1176  *
1177  * @memberof SedDataDescription_t
1178  */
1179 LIBSEDML_EXTERN
1180 char *
1181 SedDataDescription_getFormat(const SedDataDescription_t * sdd);
1182 
1183 
1184 /**
1185  * Returns the value of the "source" attribute of this SedDataDescription_t.
1186  *
1187  * @param sdd the SedDataDescription_t structure whose source is sought.
1188  *
1189  * @return the value of the "source" attribute of this SedDataDescription_t as
1190  * a pointer to a string.
1191  *
1192  * @copydetails doc_returned_owned_char
1193  *
1194  * @memberof SedDataDescription_t
1195  */
1196 LIBSEDML_EXTERN
1197 char *
1198 SedDataDescription_getSource(const SedDataDescription_t * sdd);
1199 
1200 
1201 /**
1202  * Predicate returning @c 1 (true) if this SedDataDescription_t's "id"
1203  * attribute is set.
1204  *
1205  * @param sdd the SedDataDescription_t structure.
1206  *
1207  * @return @c 1 (true) if this SedDataDescription_t's "id" attribute has been
1208  * set, otherwise @c 0 (false) is returned.
1209  *
1210  * @memberof SedDataDescription_t
1211  */
1212 LIBSEDML_EXTERN
1213 int
1214 SedDataDescription_isSetId(const SedDataDescription_t * sdd);
1215 
1216 
1217 /**
1218  * Predicate returning @c 1 (true) if this SedDataDescription_t's "name"
1219  * attribute is set.
1220  *
1221  * @param sdd the SedDataDescription_t structure.
1222  *
1223  * @return @c 1 (true) if this SedDataDescription_t's "name" attribute has been
1224  * set, otherwise @c 0 (false) is returned.
1225  *
1226  * @memberof SedDataDescription_t
1227  */
1228 LIBSEDML_EXTERN
1229 int
1230 SedDataDescription_isSetName(const SedDataDescription_t * sdd);
1231 
1232 
1233 /**
1234  * Predicate returning @c 1 (true) if this SedDataDescription_t's "format"
1235  * attribute is set.
1236  *
1237  * @param sdd the SedDataDescription_t structure.
1238  *
1239  * @return @c 1 (true) if this SedDataDescription_t's "format" attribute has
1240  * been set, otherwise @c 0 (false) is returned.
1241  *
1242  * @memberof SedDataDescription_t
1243  */
1244 LIBSEDML_EXTERN
1245 int
1246 SedDataDescription_isSetFormat(const SedDataDescription_t * sdd);
1247 
1248 
1249 /**
1250  * Predicate returning @c 1 (true) if this SedDataDescription_t's "source"
1251  * attribute is set.
1252  *
1253  * @param sdd the SedDataDescription_t structure.
1254  *
1255  * @return @c 1 (true) if this SedDataDescription_t's "source" attribute has
1256  * been set, otherwise @c 0 (false) is returned.
1257  *
1258  * @memberof SedDataDescription_t
1259  */
1260 LIBSEDML_EXTERN
1261 int
1262 SedDataDescription_isSetSource(const SedDataDescription_t * sdd);
1263 
1264 
1265 /**
1266  * Sets the value of the "id" attribute of this SedDataDescription_t.
1267  *
1268  * @param sdd the SedDataDescription_t structure.
1269  *
1270  * @param id const char * value of the "id" attribute to be set.
1271  *
1272  * @copydetails doc_returns_success_code
1273  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1274  * @li @sedmlconstant{LIBSEDML_INVALID_ATTRIBUTE_VALUE,
1275  * OperationReturnValues_t}
1276  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1277  *
1278  * Calling this function with @p id = @c NULL or an empty string is equivalent
1279  * to calling SedDataDescription_unsetId().
1280  *
1281  * @memberof SedDataDescription_t
1282  */
1283 LIBSEDML_EXTERN
1284 int
1285 SedDataDescription_setId(SedDataDescription_t * sdd, const char * id);
1286 
1287 
1288 /**
1289  * Sets the value of the "name" attribute of this SedDataDescription_t.
1290  *
1291  * @param sdd the SedDataDescription_t structure.
1292  *
1293  * @param name const char * value of the "name" attribute to be set.
1294  *
1295  * @copydetails doc_returns_success_code
1296  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1297  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1298  *
1299  * Calling this function with @p name = @c NULL or an empty string is
1300  * equivalent to calling SedDataDescription_unsetName().
1301  *
1302  * @memberof SedDataDescription_t
1303  */
1304 LIBSEDML_EXTERN
1305 int
1306 SedDataDescription_setName(SedDataDescription_t * sdd, const char * name);
1307 
1308 
1309 /**
1310  * Sets the value of the "format" attribute of this SedDataDescription_t.
1311  *
1312  * @param sdd the SedDataDescription_t structure.
1313  *
1314  * @param format const char * value of the "format" attribute to be set.
1315  *
1316  * @copydetails doc_returns_success_code
1317  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1318  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1319  *
1320  * Calling this function with @p format = @c NULL or an empty string is
1321  * equivalent to calling SedDataDescription_unsetFormat().
1322  *
1323  * @memberof SedDataDescription_t
1324  */
1325 LIBSEDML_EXTERN
1326 int
1327 SedDataDescription_setFormat(SedDataDescription_t * sdd, const char * format);
1328 
1329 
1330 /**
1331  * Sets the value of the "source" attribute of this SedDataDescription_t.
1332  *
1333  * @param sdd the SedDataDescription_t structure.
1334  *
1335  * @param source const char * value of the "source" attribute to be set.
1336  *
1337  * @copydetails doc_returns_success_code
1338  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1339  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1340  *
1341  * Calling this function with @p source = @c NULL or an empty string is
1342  * equivalent to calling SedDataDescription_unsetSource().
1343  *
1344  * @memberof SedDataDescription_t
1345  */
1346 LIBSEDML_EXTERN
1347 int
1348 SedDataDescription_setSource(SedDataDescription_t * sdd, const char * source);
1349 
1350 
1351 /**
1352  * Unsets the value of the "id" attribute of this SedDataDescription_t.
1353  *
1354  * @param sdd the SedDataDescription_t structure.
1355  *
1356  * @copydetails doc_returns_success_code
1357  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1358  * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
1359  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1360  *
1361  * @memberof SedDataDescription_t
1362  */
1363 LIBSEDML_EXTERN
1364 int
1365 SedDataDescription_unsetId(SedDataDescription_t * sdd);
1366 
1367 
1368 /**
1369  * Unsets the value of the "name" attribute of this SedDataDescription_t.
1370  *
1371  * @param sdd the SedDataDescription_t structure.
1372  *
1373  * @copydetails doc_returns_success_code
1374  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1375  * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
1376  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1377  *
1378  * @memberof SedDataDescription_t
1379  */
1380 LIBSEDML_EXTERN
1381 int
1382 SedDataDescription_unsetName(SedDataDescription_t * sdd);
1383 
1384 
1385 /**
1386  * Unsets the value of the "format" attribute of this SedDataDescription_t.
1387  *
1388  * @param sdd the SedDataDescription_t structure.
1389  *
1390  * @copydetails doc_returns_success_code
1391  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1392  * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
1393  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1394  *
1395  * @memberof SedDataDescription_t
1396  */
1397 LIBSEDML_EXTERN
1398 int
1399 SedDataDescription_unsetFormat(SedDataDescription_t * sdd);
1400 
1401 
1402 /**
1403  * Unsets the value of the "source" attribute of this SedDataDescription_t.
1404  *
1405  * @param sdd the SedDataDescription_t structure.
1406  *
1407  * @copydetails doc_returns_success_code
1408  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1409  * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
1410  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1411  *
1412  * @memberof SedDataDescription_t
1413  */
1414 LIBSEDML_EXTERN
1415 int
1416 SedDataDescription_unsetSource(SedDataDescription_t * sdd);
1417 
1418 
1419 /**
1420  * Returns the value of the "dimensionDescription" element of this
1421  * SedDataDescription_t.
1422  *
1423  * @param sdd the SedDataDescription_t structure whose dimensionDescription is
1424  * sought.
1425  *
1426  * @return the value of the "dimensionDescription" element of this
1427  * SedDataDescription_t as a LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription*.
1428  *
1429  * @memberof SedDataDescription_t
1430  */
1431 LIBSEDML_EXTERN
1432 const LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription_t*
1433 SedDataDescription_getDimensionDescription(const SedDataDescription_t * sdd);
1434 
1435 
1436 /**
1437  * Predicate returning @c 1 (true) if this SedDataDescription_t's
1438  * "dimensionDescription" element is set.
1439  *
1440  * @param sdd the SedDataDescription_t structure.
1441  *
1442  * @return @c 1 (true) if this SedDataDescription_t's "dimensionDescription"
1443  * element has been set, otherwise @c 0 (false) is returned.
1444  *
1445  * @memberof SedDataDescription_t
1446  */
1447 LIBSEDML_EXTERN
1448 int
1449 SedDataDescription_isSetDimensionDescription(const SedDataDescription_t * sdd);
1450 
1451 
1452 /**
1453  * Sets the value of the "dimensionDescription" element of this
1454  * SedDataDescription_t.
1455  *
1456  * @param sdd the SedDataDescription_t structure.
1457  *
1458  * @param dimensionDescription DimensionDescription_t* value of the
1459  * "dimensionDescription" element to be set.
1460  *
1461  * @copydetails doc_returns_success_code
1462  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1463  * @li @sedmlconstant{LIBSEDML_INVALID_ATTRIBUTE_VALUE,
1464  * OperationReturnValues_t}
1465  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1466  *
1467  * @memberof SedDataDescription_t
1468  */
1469 LIBSEDML_EXTERN
1470 int
1471 SedDataDescription_setDimensionDescription(SedDataDescription_t * sdd,
1472                                            const LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription_t*
1473                                              dimensionDescription);
1474 
1475 
1476 /**
1477  * Creates a new DimensionDescription_t object, adds it to this
1478  * SedDataDescription_t object and returns the DimensionDescription_t object
1479  * created.
1480  *
1481  * @param sdd the SedDataDescription_t structure to which the
1482  * DimensionDescription_t should be added.
1483  *
1484  * @return a new DimensionDescription_t object instance.
1485  *
1486  * @memberof SedDataDescription_t
1487  */
1488 LIBSEDML_EXTERN
1489 LIBNUML_CPP_NAMESPACE_QUALIFIER DimensionDescription_t*
1490 SedDataDescription_createDimensionDescription(SedDataDescription_t* sdd);
1491 
1492 
1493 /**
1494  * Unsets the value of the "dimensionDescription" element of this
1495  * SedDataDescription_t.
1496  *
1497  * @param sdd the SedDataDescription_t structure.
1498  *
1499  * @copydetails doc_returns_success_code
1500  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1501  * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
1502  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1503  *
1504  * @memberof SedDataDescription_t
1505  */
1506 LIBSEDML_EXTERN
1507 int
1508 SedDataDescription_unsetDimensionDescription(SedDataDescription_t * sdd);
1509 
1510 
1511 /**
1512  * Returns a ListOf_t * containing SedDataSource_t objects from this
1513  * SedDataDescription_t.
1514  *
1515  * @param sdd the SedDataDescription_t structure whose SedListOfDataSources is
1516  * sought.
1517  *
1518  * @return the SedListOfDataSources from this SedDataDescription_t as a
1519  * ListOf_t *.
1520  *
1521  * @copydetails doc_returned_unowned_pointer
1522  *
1523  * @see SedDataDescription_addDataSource()
1524  * @see SedDataDescription_createDataSource()
1525  * @see SedDataDescription_getDataSourceById()
1526  * @see SedDataDescription_getDataSource()
1527  * @see SedDataDescription_getNumDataSources()
1528  * @see SedDataDescription_removeDataSourceById()
1529  * @see SedDataDescription_removeDataSource()
1530  *
1531  * @memberof SedDataDescription_t
1532  */
1533 LIBSEDML_EXTERN
1534 SedListOf_t*
1535 SedDataDescription_getListOfDataSources(SedDataDescription_t* sdd);
1536 
1537 
1538 /**
1539  * Get a SedDataSource_t from the SedDataDescription_t.
1540  *
1541  * @param sdd the SedDataDescription_t structure to search.
1542  *
1543  * @param n an unsigned int representing the index of the SedDataSource_t to
1544  * retrieve.
1545  *
1546  * @return the nth SedDataSource_t in the SedListOfDataSources within this
1547  * SedDataDescription.
1548  *
1549  * @copydetails doc_returned_unowned_pointer
1550  *
1551  * @memberof SedDataDescription_t
1552  */
1553 LIBSEDML_EXTERN
1554 SedDataSource_t*
1555 SedDataDescription_getDataSource(SedDataDescription_t* sdd, unsigned int n);
1556 
1557 
1558 /**
1559  * Get a SedDataSource_t from the SedDataDescription_t based on its identifier.
1560  *
1561  * @param sdd the SedDataDescription_t structure to search.
1562  *
1563  * @param sid a string representing the identifier of the SedDataSource_t to
1564  * retrieve.
1565  *
1566  * @return the SedDataSource_t in the SedListOfDataSources within this
1567  * SedDataDescription with the given @p sid or @c NULL if no such
1568  * SedDataSource_t exists.
1569  *
1570  * @copydetails doc_returned_unowned_pointer
1571  *
1572  * @memberof SedDataDescription_t
1573  */
1574 LIBSEDML_EXTERN
1575 SedDataSource_t*
1576 SedDataDescription_getDataSourceById(SedDataDescription_t* sdd,
1577                                      const char *sid);
1578 
1579 
1580 /**
1581  * Get a SedDataSource_t from the SedDataDescription_t based on the IndexSet to
1582  * which it refers.
1583  *
1584  * @param sdd the SedDataDescription_t structure to search.
1585  *
1586  * @param sid a string representing the "indexSet" attribute of the
1587  * SedDataSource_t object to retrieve.
1588  *
1589  * @return the first SedDataSource_t in this SedDataDescription_t based on the
1590  * given indexSet attribute or NULL if no such SedDataSource_t exists.
1591  *
1592  * @copydetails doc_returned_unowned_pointer
1593  *
1594  * @memberof SedDataDescription_t
1595  */
1596 LIBSEDML_EXTERN
1597 SedDataSource_t*
1598 SedDataDescription_getDataSourceByIndexSet(SedDataDescription_t* sdd,
1599                                            const char *sid);
1600 
1601 
1602 /**
1603  * Adds a copy of the given SedDataSource_t to this SedDataDescription_t.
1604  *
1605  * @param sdd the SedDataDescription_t structure to which the SedDataSource_t
1606  * should be added.
1607  *
1608  * @param sds the SedDataSource_t object to add.
1609  *
1610  * @copydetails doc_returns_success_code
1611  * @li @sedmlconstant{LIBSEDML_OPERATION_SUCCESS, OperationReturnValues_t}
1612  * @li @sedmlconstant{LIBSEDML_OPERATION_FAILED, OperationReturnValues_t}
1613  * @li @sedmlconstant{LIBSEDML_INVALID_OBJECT, OperationReturnValues_t}
1614  * @li @sedmlconstant{LIBSEDML_LEVEL_MISMATCH, OperationReturnValues_t}
1615  * @li @sedmlconstant{LIBSEDML_VERSION_MISMATCH, OperationReturnValues_t}
1616  * @li @sedmlconstant{LIBSEDML_PKG_VERSION_MISMATCH, OperationReturnValues_t}
1617  * @li @sedmlconstant{LIBSEDML_DUPLICATE_OBJECT_ID, OperationReturnValues_t}
1618  *
1619  * @memberof SedDataDescription_t
1620  */
1621 LIBSEDML_EXTERN
1622 int
1623 SedDataDescription_addDataSource(SedDataDescription_t* sdd,
1624                                  const SedDataSource_t* sds);
1625 
1626 
1627 /**
1628  * Get the number of SedDataSource_t objects in this SedDataDescription_t.
1629  *
1630  * @param sdd the SedDataDescription_t structure to query.
1631  *
1632  * @return the number of SedDataSource_t objects in this SedDataDescription_t.
1633  *
1634  * @memberof SedDataDescription_t
1635  */
1636 LIBSEDML_EXTERN
1637 unsigned int
1638 SedDataDescription_getNumDataSources(SedDataDescription_t* sdd);
1639 
1640 
1641 /**
1642  * Creates a new SedDataSource_t object, adds it to this SedDataDescription_t
1643  * object and returns the SedDataSource_t object created.
1644  *
1645  * @param sdd the SedDataDescription_t structure to which the SedDataSource_t
1646  * should be added.
1647  *
1648  * @return a new SedDataSource_t object instance.
1649  *
1650  * @copydetails doc_returned_unowned_pointer
1651  *
1652  * @memberof SedDataDescription_t
1653  */
1654 LIBSEDML_EXTERN
1655 SedDataSource_t*
1656 SedDataDescription_createDataSource(SedDataDescription_t* sdd);
1657 
1658 
1659 /**
1660  * Removes the nth SedDataSource_t from this SedDataDescription_t and returns a
1661  * pointer to it.
1662  *
1663  * @param sdd the SedDataDescription_t structure to search.
1664  *
1665  * @param n an unsigned int representing the index of the SedDataSource_t to
1666  * remove.
1667  *
1668  * @return a pointer to the nth SedDataSource_t in this SedDataDescription_t.
1669  *
1670  * @copydetails doc_returned_owned_pointer
1671  *
1672  * @memberof SedDataDescription_t
1673  */
1674 LIBSEDML_EXTERN
1675 SedDataSource_t*
1676 SedDataDescription_removeDataSource(SedDataDescription_t* sdd,
1677                                     unsigned int n);
1678 
1679 
1680 /**
1681  * Removes the SedDataSource_t from this SedDataDescription_t based on its
1682  * identifier and returns a pointer to it.
1683  *
1684  * @param sdd the SedDataDescription_t structure to search.
1685  *
1686  * @param sid a string representing the identifier of the SedDataSource_t to
1687  * remove.
1688  *
1689  * @return the SedDataSource_t in this SedDataDescription_t based on the
1690  * identifier or NULL if no such SedDataSource_t exists.
1691  *
1692  * @copydetails doc_returned_owned_pointer
1693  *
1694  * @memberof SedDataDescription_t
1695  */
1696 LIBSEDML_EXTERN
1697 SedDataSource_t*
1698 SedDataDescription_removeDataSourceById(SedDataDescription_t* sdd,
1699                                         const char* sid);
1700 
1701 
1702 /**
1703  * Predicate returning @c 1 (true) if all the required attributes for this
1704  * SedDataDescription_t object have been set.
1705  *
1706  * @param sdd the SedDataDescription_t structure.
1707  *
1708  * @return @c 1 (true) to indicate that all the required attributes of this
1709  * SedDataDescription_t have been set, otherwise @c 0 (false) is returned.
1710  *
1711  *
1712  * @note The required attributes for the SedDataDescription_t object are:
1713  * @li "id"
1714  *
1715  * @memberof SedDataDescription_t
1716  */
1717 LIBSEDML_EXTERN
1718 int
1719 SedDataDescription_hasRequiredAttributes(const SedDataDescription_t * sdd);
1720 
1721 
1722 
1723 
1724 END_C_DECLS
1725 
1726 
1727 
1728 
1729 LIBSEDML_CPP_NAMESPACE_END
1730 
1731 
1732 
1733 
1734 #endif /* !SWIG */
1735 
1736 
1737 
1738 
1739 #endif /* !SedDataDescription_H__ */
1740 
1741 
1742