Notation.h
Go to the documentation of this file.
1 /* Copyright (C) 2008 National Institute For Space Research (INPE) - Brazil.
2 
3  This file is part of the TerraLib - a Framework for building GIS enabled applications.
4 
5  TerraLib is free software: you can redistribute it and/or modify
6  it under the terms of the GNU General Public License as published by
7  the Free Software Foundation, either version 3 of the License,
8  or (at your option) any later version.
9 
10  TerraLib is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  GNU General Public License for more details.
14 
15  You should have received a copy of the GNU General Public License
16  along with TerraLib. See COPYING. If not, write to
17  TerraLib Team at <terralib-team@terralib.org>.
18  */
19 
20 /*!
21  \file Notation.h
22 
23  \brief This class models a notation element from a XML Schema.
24 */
25 
26 #ifndef __TERRALIB_XSD_INTERNAL_NOTATION_H
27 #define __TERRALIB_XSD_INTERNAL_NOTATION_H
28 
29 // TerraLib
30 #include "Annotated.h"
31 #include "Identifiable.h"
32 
33 namespace te
34 {
35  namespace xsd
36  {
37  /*!
38  \class Notation
39 
40  \brief This class models a notation element from a XML Schema.
41 
42  \note Parent elements: schema.
43  */
44  class TEXSDEXPORT Notation : public Identifiable, public Annotated
45  {
46  public:
47 
48  /*!
49  \brief Constructor.
50 
51  \param id It specifies a unique ID for the element. It can be a NULL value.
52  \param name It specifies a name for the element. It can not be a NULL value.
53  \param pub It specifies a URI corresponding to the public identifier. It can not be a NULL value.
54 
55  \note The Notation object will take the ownership of the pointers id, name and pub.
56  */
57  Notation(std::string* name, std::string* pub, Annotation* ann = 0, std::string* id = 0);
58 
59  /*!
60  \brief Copy constructor.
61 
62  \param rhs Right-hand-side object.
63 
64  \todo Implement!
65  */
66  Notation(const Notation& rhs);
67 
68  /*! \brief Destructor. */
69  ~Notation();
70 
71  /*!
72  \brief Assignment operator.
73 
74  \param rhs Right-hand-side object.
75 
76  \return A reference to this object.
77 
78  \todo Implement!
79  */
80  Notation& operator=(const Notation& rhs);
81 
82  /*!
83  \brief It returns the name of this element.
84 
85  \return The name of this element.
86  */
87  std::string* getName() const;
88 
89  /*!
90  \brief It returns the URI corresponding to the public identifier.
91 
92  \return The URI corresponding to the public identifier.
93  */
94  std::string* getPublic() const;
95 
96  /*!
97  \brief It returns the URI corresponding to the system identifier.
98 
99  \return The URI corresponding to the system identifier.
100  */
101  std::string* getSystem() const;
102 
103  /*!
104  \brief It sets the name of this element.
105 
106  \param name The name of this element.
107 
108  \note The Notation object will take the ownership of the given pointer.
109  */
110  void setName(std::string* name);
111 
112  /*!
113  \brief It sets the URI corresponding to the public identifier.
114 
115  \param pub The URI corresponding to the public identifier.
116 
117  \note The Notation object will take the ownership of the given pointer.
118  */
119  void setPublic(std::string* pub);
120 
121  /*!
122  \brief It sets the URI corresponding to the system identifier.
123 
124  \param sys The URI corresponding to the system identifier.
125 
126  \note The Notation object will take the ownership of the given pointer.
127  */
128  void setSystem(std::string* sys);
129 
130  private:
131 
132  std::string* m_name; //!< It specifies a name for the element. (Required)
133  std::string* m_public; //!< It specifies a URI corresponding to the public identifier. (Required)
134  std::string* m_system; //!< It specifies a URI corresponding to the system identifier. (Optional)
135  };
136 
137  } // end namespace xsd
138 } // end namespace te
139 
140 #endif // __TERRALIB_XSD_INTERNAL_NOTATION_H
A base class for XSD classes that may allow annotation.
Definition: Annotated.h:49
std::string * m_system
It specifies a URI corresponding to the system identifier. (Optional)
Definition: Notation.h:134
A base class for XSD classes that may allow annotation.
A base class for XSD classes that must provide a unique ID property.
Definition: Identifiable.h:46
URI C++ Library.
A base class for XSD classes that must provide a unique ID property.
#define TEXSDEXPORT
You can use this macro in order to export/import classes and functions from this module.
Definition: Config.h:57
std::string * m_public
It specifies a URI corresponding to the public identifier. (Required)
Definition: Notation.h:133
A class that models a XSD annotation element.
Definition: Annotation.h:55
This class models a notation element from a XML Schema.
Definition: Notation.h:44
std::string * m_name
It specifies a name for the element. (Required)
Definition: Notation.h:132