b311480e |
1 | // Created on: 2000-07-03 |
2 | // Created by: Andrey BETENEV |
973c2be1 |
3 | // Copyright (c) 2000-2014 OPEN CASCADE SAS |
b311480e |
4 | // |
973c2be1 |
5 | // This file is part of Open CASCADE Technology software library. |
b311480e |
6 | // |
d5f74e42 |
7 | // This library is free software; you can redistribute it and/or modify it under |
8 | // the terms of the GNU Lesser General Public License version 2.1 as published |
973c2be1 |
9 | // by the Free Software Foundation, with special exception defined in the file |
10 | // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT |
11 | // distribution for complete text of the license and disclaimer of any warranty. |
b311480e |
12 | // |
973c2be1 |
13 | // Alternatively, this file may be used under the terms of Open CASCADE |
14 | // commercial license or contractual agreement. |
b311480e |
15 | |
7fd59977 |
16 | // Generator: ExpToCas (EXPRESS -> CASCADE/XSTEP Translator) V1.1 |
7fd59977 |
17 | |
42cf5bc1 |
18 | #include <Standard_Type.hxx> |
19 | #include <StepBasic_ProductDefinition.hxx> |
d658f275 |
20 | #include <StepBasic_ProductDefinitionOrReference.hxx> |
42cf5bc1 |
21 | #include <StepBasic_ProductDefinitionRelationship.hxx> |
22 | #include <TCollection_HAsciiString.hxx> |
7fd59977 |
23 | |
25e59720 |
24 | IMPLEMENT_STANDARD_RTTIEXT(StepBasic_ProductDefinitionRelationship,Standard_Transient) |
92efcf78 |
25 | |
7fd59977 |
26 | //======================================================================= |
27 | //function : StepBasic_ProductDefinitionRelationship |
28 | //purpose : |
29 | //======================================================================= |
7fd59977 |
30 | StepBasic_ProductDefinitionRelationship::StepBasic_ProductDefinitionRelationship () |
31 | { |
32 | defDescription = Standard_False; |
33 | } |
34 | |
35 | //======================================================================= |
36 | //function : Init |
37 | //purpose : |
38 | //======================================================================= |
39 | |
40 | void StepBasic_ProductDefinitionRelationship::Init (const Handle(TCollection_HAsciiString) &aId, |
41 | const Handle(TCollection_HAsciiString) &aName, |
42 | const Standard_Boolean hasDescription, |
43 | const Handle(TCollection_HAsciiString) &aDescription, |
44 | const Handle(StepBasic_ProductDefinition) &aRelatingProductDefinition, |
45 | const Handle(StepBasic_ProductDefinition) &aRelatedProductDefinition) |
46 | { |
47 | |
48 | theId = aId; |
49 | |
50 | theName = aName; |
51 | |
52 | defDescription = hasDescription; |
53 | if (defDescription) { |
54 | theDescription = aDescription; |
55 | } |
56 | else theDescription.Nullify(); |
57 | |
d658f275 |
58 | theRelatingProductDefinition.SetValue(aRelatingProductDefinition); |
59 | |
60 | theRelatedProductDefinition.SetValue(aRelatedProductDefinition); |
61 | } |
62 | |
63 | //======================================================================= |
64 | //function : Init |
65 | //purpose : |
66 | //======================================================================= |
67 | |
68 | void StepBasic_ProductDefinitionRelationship::Init (const Handle(TCollection_HAsciiString) &aId, |
69 | const Handle(TCollection_HAsciiString) &aName, |
70 | const Standard_Boolean hasDescription, |
71 | const Handle(TCollection_HAsciiString) &aDescription, |
72 | const StepBasic_ProductDefinitionOrReference &aRelatingProductDefinition, |
73 | const StepBasic_ProductDefinitionOrReference &aRelatedProductDefinition) |
74 | { |
7fd59977 |
75 | |
d658f275 |
76 | theId = aId; |
77 | theName = aName; |
78 | defDescription = hasDescription; |
79 | if (defDescription) { |
80 | theDescription = aDescription; |
81 | } |
82 | else theDescription.Nullify(); |
83 | theRelatingProductDefinition = aRelatingProductDefinition; |
7fd59977 |
84 | theRelatedProductDefinition = aRelatedProductDefinition; |
85 | } |
86 | |
87 | //======================================================================= |
88 | //function : Id |
89 | //purpose : |
90 | //======================================================================= |
91 | |
92 | Handle(TCollection_HAsciiString) StepBasic_ProductDefinitionRelationship::Id () const |
93 | { |
94 | return theId; |
95 | } |
96 | |
97 | //======================================================================= |
98 | //function : SetId |
99 | //purpose : |
100 | //======================================================================= |
101 | |
102 | void StepBasic_ProductDefinitionRelationship::SetId (const Handle(TCollection_HAsciiString) &aId) |
103 | { |
104 | theId = aId; |
105 | } |
106 | |
107 | //======================================================================= |
108 | //function : Name |
109 | //purpose : |
110 | //======================================================================= |
111 | |
112 | Handle(TCollection_HAsciiString) StepBasic_ProductDefinitionRelationship::Name () const |
113 | { |
114 | return theName; |
115 | } |
116 | |
117 | //======================================================================= |
118 | //function : SetName |
119 | //purpose : |
120 | //======================================================================= |
121 | |
122 | void StepBasic_ProductDefinitionRelationship::SetName (const Handle(TCollection_HAsciiString) &aName) |
123 | { |
124 | theName = aName; |
125 | } |
126 | |
127 | //======================================================================= |
128 | //function : Description |
129 | //purpose : |
130 | //======================================================================= |
131 | |
132 | Handle(TCollection_HAsciiString) StepBasic_ProductDefinitionRelationship::Description () const |
133 | { |
134 | return theDescription; |
135 | } |
136 | |
137 | //======================================================================= |
138 | //function : SetDescription |
139 | //purpose : |
140 | //======================================================================= |
141 | |
142 | void StepBasic_ProductDefinitionRelationship::SetDescription (const Handle(TCollection_HAsciiString) &aDescription) |
143 | { |
144 | theDescription = aDescription; |
145 | } |
146 | |
147 | //======================================================================= |
148 | //function : HasDescription |
149 | //purpose : |
150 | //======================================================================= |
151 | |
152 | Standard_Boolean StepBasic_ProductDefinitionRelationship::HasDescription () const |
153 | { |
154 | return defDescription; |
155 | } |
156 | |
157 | //======================================================================= |
158 | //function : RelatingProductDefinition |
159 | //purpose : |
160 | //======================================================================= |
161 | |
162 | Handle(StepBasic_ProductDefinition) StepBasic_ProductDefinitionRelationship::RelatingProductDefinition () const |
d658f275 |
163 | { |
164 | return theRelatingProductDefinition.ProductDefinition(); |
165 | } |
166 | |
167 | //======================================================================= |
168 | //function : RelatingProductDefinitionAP242 |
169 | //purpose : |
170 | //======================================================================= |
171 | |
172 | StepBasic_ProductDefinitionOrReference StepBasic_ProductDefinitionRelationship::RelatingProductDefinitionAP242 () const |
7fd59977 |
173 | { |
174 | return theRelatingProductDefinition; |
175 | } |
176 | |
177 | //======================================================================= |
178 | //function : SetRelatingProductDefinition |
179 | //purpose : |
180 | //======================================================================= |
181 | |
182 | void StepBasic_ProductDefinitionRelationship::SetRelatingProductDefinition (const Handle(StepBasic_ProductDefinition) &aRelatingProductDefinition) |
d658f275 |
183 | { |
184 | theRelatingProductDefinition.SetValue(aRelatingProductDefinition); |
185 | } |
186 | |
187 | //======================================================================= |
188 | //function : SetRelatingProductDefinition |
189 | //purpose : |
190 | //======================================================================= |
191 | |
192 | void StepBasic_ProductDefinitionRelationship::SetRelatingProductDefinition (const StepBasic_ProductDefinitionOrReference &aRelatingProductDefinition) |
7fd59977 |
193 | { |
194 | theRelatingProductDefinition = aRelatingProductDefinition; |
195 | } |
196 | |
197 | //======================================================================= |
198 | //function : RelatedProductDefinition |
199 | //purpose : |
200 | //======================================================================= |
201 | |
202 | Handle(StepBasic_ProductDefinition) StepBasic_ProductDefinitionRelationship::RelatedProductDefinition () const |
d658f275 |
203 | { |
204 | return theRelatedProductDefinition.ProductDefinition(); |
205 | } |
206 | |
207 | //======================================================================= |
208 | //function : RelatedProductDefinitionAP242 |
209 | //purpose : |
210 | //======================================================================= |
211 | |
212 | StepBasic_ProductDefinitionOrReference StepBasic_ProductDefinitionRelationship::RelatedProductDefinitionAP242 () const |
7fd59977 |
213 | { |
214 | return theRelatedProductDefinition; |
215 | } |
216 | |
217 | //======================================================================= |
218 | //function : SetRelatedProductDefinition |
219 | //purpose : |
220 | //======================================================================= |
221 | |
222 | void StepBasic_ProductDefinitionRelationship::SetRelatedProductDefinition (const Handle(StepBasic_ProductDefinition) &aRelatedProductDefinition) |
223 | { |
d658f275 |
224 | theRelatedProductDefinition.SetValue(aRelatedProductDefinition); |
225 | } |
226 | |
227 | //======================================================================= |
228 | //function : SetRelatedProductDefinition |
229 | //purpose : |
230 | //======================================================================= |
231 | |
232 | void StepBasic_ProductDefinitionRelationship::SetRelatedProductDefinition (const StepBasic_ProductDefinitionOrReference &aRelatedProductDefinition) |
233 | { |
234 | theRelatedProductDefinition = aRelatedProductDefinition; |
7fd59977 |
235 | } |