Branch data Line data Source code
1 : : // Copyright (c) 2005-2014 Code Synthesis Tools CC
2 : : //
3 : : // This program was generated by CodeSynthesis XSD, an XML Schema to
4 : : // C++ data binding compiler.
5 : : //
6 : : // This program is free software; you can redistribute it and/or modify
7 : : // it under the terms of the GNU General Public License version 2 as
8 : : // published by the Free Software Foundation.
9 : : //
10 : : // This program 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 this program; if not, write to the Free Software
17 : : // Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18 : : //
19 : : // In addition, as a special exception, Code Synthesis Tools CC gives
20 : : // permission to link this program with the Xerces-C++ library (or with
21 : : // modified versions of Xerces-C++ that use the same license as Xerces-C++),
22 : : // and distribute linked combinations including the two. You must obey
23 : : // the GNU General Public License version 2 in all respects for all of
24 : : // the code used other than Xerces-C++. If you modify this copy of the
25 : : // program, you may extend this exception to your version of the program,
26 : : // but you are not obligated to do so. If you do not wish to do so, delete
27 : : // this exception statement from your version.
28 : : //
29 : : // Furthermore, Code Synthesis Tools CC makes a special exception for
30 : : // the Free/Libre and Open Source Software (FLOSS) which is described
31 : : // in the accompanying FLOSSE file.
32 : : //
33 : :
34 : : // Begin prologue.
35 : : //
36 : : //
37 : : // End prologue.
38 : :
39 : : #include <xsd/cxx/pre.hxx>
40 : :
41 : : #include "axe.hxx"
42 : :
43 : : // Axe
44 : : //
45 : :
46 : 0 : const Axe::IdOptional& Axe::
47 : : getId () const
48 : : {
49 : 0 : return this->id_;
50 : : }
51 : :
52 : 0 : Axe::IdOptional& Axe::
53 : : getId ()
54 : : {
55 : 0 : return this->id_;
56 : : }
57 : :
58 : 0 : void Axe::
59 : : setId (const IdType& x)
60 : : {
61 : 0 : this->id_.set (x);
62 : 0 : }
63 : :
64 : 0 : void Axe::
65 : : setId (const IdOptional& x)
66 : : {
67 : 0 : this->id_ = x;
68 : 0 : }
69 : :
70 : 0 : void Axe::
71 : : setId (::std::unique_ptr< IdType > x)
72 : : {
73 [ # # ]: 0 : this->id_.set (std::move (x));
74 : 0 : }
75 : :
76 : :
77 : : #include <xsd/cxx/xml/dom/parsing-source.hxx>
78 : :
79 : : // Axe
80 : : //
81 : :
82 : 0 : Axe::
83 : : Axe ()
84 : : : ::xml_schema::Type (),
85 : 0 : id_ (this)
86 : : {
87 : 0 : }
88 : :
89 : 0 : Axe::
90 : : Axe (const Axe& x,
91 : : ::xml_schema::Flags f,
92 : : ::xml_schema::Container* c)
93 : : : ::xml_schema::Type (x, f, c),
94 [ # # ]: 0 : id_ (x.id_, f, this)
95 : : {
96 : 0 : }
97 : :
98 : 2 : Axe::
99 : : Axe (const ::xercesc::DOMElement& e,
100 : : ::xml_schema::Flags f,
101 : : ::xml_schema::Container* c)
102 : : : ::xml_schema::Type (e, f | ::xml_schema::Flags::base, c),
103 : 2 : id_ (this)
104 : : {
105 [ + - ]: 2 : if ((f & ::xml_schema::Flags::base) == 0)
106 : : {
107 [ + - ]: 2 : ::xsd::cxx::xml::dom::parser< char > p (e, false, false, true);
108 [ + - ]: 2 : this->parse (p, f);
109 : : }
110 : 2 : }
111 : :
112 : 6 : void Axe::
113 : : parse (::xsd::cxx::xml::dom::parser< char >& p,
114 : : ::xml_schema::Flags f)
115 : : {
116 [ + + ]: 4 : while (p.more_attributes ())
117 : : {
118 : : const ::xercesc::DOMAttr& i (p.next_attribute ());
119 : : const ::xsd::cxx::xml::qualified_name< char > n (
120 : 2 : ::xsd::cxx::xml::dom::name< char > (i));
121 : :
122 [ + - ][ - + ]: 2 : if (n.name () == "id" && n.namespace_ ().empty ())
[ + - ]
123 : : {
124 [ + - ][ + - ]: 2 : this->id_.set (IdTraits::create (i, f, this));
125 : 2 : continue;
126 : : }
127 : : }
128 : 2 : }
129 : :
130 : 0 : Axe* Axe::
131 : : _clone (::xml_schema::Flags f,
132 : : ::xml_schema::Container* c) const
133 : : {
134 [ # # ]: 0 : return new class Axe (*this, f, c);
135 : : }
136 : :
137 : 0 : Axe& Axe::
138 : : operator= (const Axe& x)
139 : : {
140 [ # # ]: 0 : if (this != &x)
141 : : {
142 : 0 : static_cast< ::xml_schema::Type& > (*this) = x;
143 : 0 : this->id_ = x.id_;
144 : : }
145 : :
146 : 0 : return *this;
147 : : }
148 : :
149 : 4 : Axe::
150 : 2 : ~Axe ()
151 : : {
152 : 2 : }
153 : :
154 : : bool
155 : 0 : operator== (const Axe& x, const Axe& y)
156 : : {
157 [ # # ]: 0 : if (!(x.getId () == y.getId ()))
158 : : return false;
159 : :
160 : 0 : return true;
161 : : }
162 : :
163 : : bool
164 : 0 : operator!= (const Axe& x, const Axe& y)
165 : : {
166 : 0 : return !(x == y);
167 : : }
168 : :
169 : : #include <istream>
170 : : #include <xsd/cxx/xml/sax/std-input-source.hxx>
171 : : #include <xsd/cxx/tree/error-handler.hxx>
172 : :
173 : : #include <xsd/cxx/post.hxx>
174 : :
175 : : // Begin epilogue.
176 : : //
177 : : //
178 : : // End epilogue.
179 : :
|