Fix reset of properties with default value
[qt:qtmodeling.git] / src / uml / qobjects / qumlelementimportobject.cpp
1 /****************************************************************************
2 **
3 ** Copyright (C) 2013 Sandro S. Andrade <sandroandrade@kde.org>
4 ** Contact: http://www.qt-project.org/legal
5 **
6 ** This file is part of the QtUml module of the Qt Toolkit.
7 **
8 ** $QT_BEGIN_LICENSE:LGPL$
9 ** Commercial License Usage
10 ** Licensees holding valid commercial Qt licenses may use this file in
11 ** accordance with the commercial license agreement provided with the
12 ** Software or, alternatively, in accordance with the terms contained in
13 ** a written agreement between you and Digia.  For licensing terms and
14 ** conditions see http://qt.digia.com/licensing.  For further information
15 ** use the contact form at http://qt.digia.com/contact-us.
16 **
17 ** GNU Lesser General Public License Usage
18 ** Alternatively, this file may be used under the terms of the GNU Lesser
19 ** General Public License version 2.1 as published by the Free Software
20 ** Foundation and appearing in the file LICENSE.LGPL included in the
21 ** packaging of this file.  Please review the following information to
22 ** ensure the GNU Lesser General Public License version 2.1 requirements
23 ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
24 **
25 ** In addition, as a special exception, Digia gives you certain additional
26 ** rights.  These rights are described in the Digia Qt LGPL Exception
27 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
28 **
29 ** GNU General Public License Usage
30 ** Alternatively, this file may be used under the terms of the GNU
31 ** General Public License version 3.0 as published by the Free Software
32 ** Foundation and appearing in the file LICENSE.GPL included in the
33 ** packaging of this file.  Please review the following information to
34 ** ensure the GNU General Public License version 3.0 requirements will be
35 ** met: http://www.gnu.org/copyleft/gpl.html.
36 **
37 **
38 ** $QT_END_LICENSE$
39 **
40 ****************************************************************************/
41 #include "qumlelementimportobject_p.h"
42 #include "private/qmodelingobject_p.h"
43
44 #include <QtUml/QUmlElementImport>
45 #include <QtUml/QUmlComment>
46 #include <QtUml/QUmlElement>
47 #include <QtUml/QUmlNamespace>
48 #include <QtUml/QUmlPackageableElement>
49
50 QT_BEGIN_NAMESPACE
51
52 QUmlElementImportObject::QUmlElementImportObject(QUmlElementImport *modelingElement)
53 {
54     setProperty("modelingElement", QVariant::fromValue(static_cast<QModelingElement *>(modelingElement)));
55     setGroupProperties();
56     setPropertyData();
57 }
58
59 // OWNED ATTRIBUTES [Element]
60
61 const QSet<QObject *> QUmlElementImportObject::ownedComments() const
62 {
63     QSet<QObject *> set;
64     foreach (QUmlComment *element, qmodelingelementproperty_cast<QUmlElementImport *>(this)->ownedComments())
65         set.insert(element->asQModelingObject());
66     return set;
67 }
68
69 const QSet<QObject *> QUmlElementImportObject::ownedElements() const
70 {
71     QSet<QObject *> set;
72     foreach (QUmlElement *element, qmodelingelementproperty_cast<QUmlElementImport *>(this)->ownedElements())
73         set.insert(element->asQModelingObject());
74     return set;
75 }
76
77 QObject *QUmlElementImportObject::owner() const
78 {
79     if (!qmodelingelementproperty_cast<QUmlElementImport *>(this)->owner())
80         return 0;
81     else
82         return qmodelingelementproperty_cast<QUmlElementImport *>(this)->owner()->asQModelingObject();
83 }
84
85 // OWNED ATTRIBUTES [Relationship]
86
87 const QSet<QObject *> QUmlElementImportObject::relatedElements() const
88 {
89     QSet<QObject *> set;
90     foreach (QUmlElement *element, qmodelingelementproperty_cast<QUmlElementImport *>(this)->relatedElements())
91         set.insert(element->asQModelingObject());
92     return set;
93 }
94
95 // OWNED ATTRIBUTES [DirectedRelationship]
96
97 const QSet<QObject *> QUmlElementImportObject::sources() const
98 {
99     QSet<QObject *> set;
100     foreach (QUmlElement *element, qmodelingelementproperty_cast<QUmlElementImport *>(this)->sources())
101         set.insert(element->asQModelingObject());
102     return set;
103 }
104
105 const QSet<QObject *> QUmlElementImportObject::targets() const
106 {
107     QSet<QObject *> set;
108     foreach (QUmlElement *element, qmodelingelementproperty_cast<QUmlElementImport *>(this)->targets())
109         set.insert(element->asQModelingObject());
110     return set;
111 }
112
113 // OWNED ATTRIBUTES [ElementImport]
114
115 QString QUmlElementImportObject::alias() const
116 {
117     return qmodelingelementproperty_cast<QUmlElementImport *>(this)->alias();
118 }
119
120 QObject *QUmlElementImportObject::importedElement() const
121 {
122     if (!qmodelingelementproperty_cast<QUmlElementImport *>(this)->importedElement())
123         return 0;
124     else
125         return qmodelingelementproperty_cast<QUmlElementImport *>(this)->importedElement()->asQModelingObject();
126 }
127
128 QObject *QUmlElementImportObject::importingNamespace() const
129 {
130     if (!qmodelingelementproperty_cast<QUmlElementImport *>(this)->importingNamespace())
131         return 0;
132     else
133         return qmodelingelementproperty_cast<QUmlElementImport *>(this)->importingNamespace()->asQModelingObject();
134 }
135
136 QtUml::VisibilityKind QUmlElementImportObject::visibility() const
137 {
138     return qmodelingelementproperty_cast<QUmlElementImport *>(this)->visibility();
139 }
140
141 // OPERATIONS [Element]
142
143 QSet<QObject *> QUmlElementImportObject::allOwnedElements() const
144 {
145     QSet<QObject *> set;
146     foreach (QUmlElement *element, qmodelingelementproperty_cast<QUmlElementImport *>(this)->allOwnedElements())
147         set.insert(element->asQModelingObject());
148     return set;
149 }
150
151 bool QUmlElementImportObject::mustBeOwned() const
152 {
153     return qmodelingelementproperty_cast<QUmlElementImport *>(this)->mustBeOwned();
154 }
155
156 // OPERATIONS [ElementImport]
157
158 QString QUmlElementImportObject::getName() const
159 {
160     return qmodelingelementproperty_cast<QUmlElementImport *>(this)->getName();
161 }
162
163 // SLOTS FOR OWNED ATTRIBUTES [Element]
164
165 void QUmlElementImportObject::addOwnedComment(QObject *ownedComment)
166 {
167     qmodelingelementproperty_cast<QUmlElementImport *>(this)->addOwnedComment(qmodelingelementproperty_cast<QUmlComment *>(ownedComment));
168 }
169
170 void QUmlElementImportObject::removeOwnedComment(QObject *ownedComment)
171 {
172     qmodelingelementproperty_cast<QUmlElementImport *>(this)->removeOwnedComment(qmodelingelementproperty_cast<QUmlComment *>(ownedComment));
173 }
174
175 void QUmlElementImportObject::addOwnedElement(QObject *ownedElement)
176 {
177     qmodelingelementproperty_cast<QUmlElementImport *>(this)->addOwnedElement(qmodelingelementproperty_cast<QUmlElement *>(ownedElement));
178 }
179
180 void QUmlElementImportObject::removeOwnedElement(QObject *ownedElement)
181 {
182     qmodelingelementproperty_cast<QUmlElementImport *>(this)->removeOwnedElement(qmodelingelementproperty_cast<QUmlElement *>(ownedElement));
183 }
184
185 void QUmlElementImportObject::setOwner(QObject *owner)
186 {
187     qmodelingelementproperty_cast<QUmlElementImport *>(this)->setOwner(qmodelingelementproperty_cast<QUmlElement *>(owner));
188 }
189
190 // SLOTS FOR OWNED ATTRIBUTES [Relationship]
191
192 void QUmlElementImportObject::addRelatedElement(QObject *relatedElement)
193 {
194     qmodelingelementproperty_cast<QUmlElementImport *>(this)->addRelatedElement(qmodelingelementproperty_cast<QUmlElement *>(relatedElement));
195 }
196
197 void QUmlElementImportObject::removeRelatedElement(QObject *relatedElement)
198 {
199     qmodelingelementproperty_cast<QUmlElementImport *>(this)->removeRelatedElement(qmodelingelementproperty_cast<QUmlElement *>(relatedElement));
200 }
201
202 // SLOTS FOR OWNED ATTRIBUTES [DirectedRelationship]
203
204 void QUmlElementImportObject::addSource(QObject *source)
205 {
206     qmodelingelementproperty_cast<QUmlElementImport *>(this)->addSource(qmodelingelementproperty_cast<QUmlElement *>(source));
207 }
208
209 void QUmlElementImportObject::removeSource(QObject *source)
210 {
211     qmodelingelementproperty_cast<QUmlElementImport *>(this)->removeSource(qmodelingelementproperty_cast<QUmlElement *>(source));
212 }
213
214 void QUmlElementImportObject::addTarget(QObject *target)
215 {
216     qmodelingelementproperty_cast<QUmlElementImport *>(this)->addTarget(qmodelingelementproperty_cast<QUmlElement *>(target));
217 }
218
219 void QUmlElementImportObject::removeTarget(QObject *target)
220 {
221     qmodelingelementproperty_cast<QUmlElementImport *>(this)->removeTarget(qmodelingelementproperty_cast<QUmlElement *>(target));
222 }
223
224 // SLOTS FOR OWNED ATTRIBUTES [ElementImport]
225
226 void QUmlElementImportObject::setAlias(QString alias)
227 {
228     qmodelingelementproperty_cast<QUmlElementImport *>(this)->setAlias(alias);
229 }
230
231 void QUmlElementImportObject::setImportedElement(QObject *importedElement)
232 {
233     qmodelingelementproperty_cast<QUmlElementImport *>(this)->setImportedElement(qmodelingelementproperty_cast<QUmlPackageableElement *>(importedElement));
234 }
235
236 void QUmlElementImportObject::setImportingNamespace(QObject *importingNamespace)
237 {
238     qmodelingelementproperty_cast<QUmlElementImport *>(this)->setImportingNamespace(qmodelingelementproperty_cast<QUmlNamespace *>(importingNamespace));
239 }
240
241 void QUmlElementImportObject::setVisibility(QtUml::VisibilityKind visibility)
242 {
243     qmodelingelementproperty_cast<QUmlElementImport *>(this)->setVisibility(visibility);
244 }
245
246 void QUmlElementImportObject::unsetVisibility()
247 {
248     Q_D(QModelingObject);
249     setVisibility(QtUml::VisibilityKindPublic);
250     d->modifiedResettableProperties.removeAll(QStringLiteral("visibility"));
251 }
252
253
254 void QUmlElementImportObject::setGroupProperties()
255 {
256     Q_D(QModelingObject);
257     const QMetaObject *metaObject = this->metaObject();
258
259     d->propertyGroups << QStringLiteral("QObject");
260     d->groupProperties.insert(QStringLiteral("QObject"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("objectName"))));
261
262     d->propertyGroups << QStringLiteral("QUmlElement");
263     d->groupProperties.insert(QStringLiteral("QUmlElement"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("ownedComments"))));
264     d->groupProperties.insert(QStringLiteral("QUmlElement"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("ownedElements"))));
265     d->groupProperties.insert(QStringLiteral("QUmlElement"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("owner"))));
266
267     d->propertyGroups << QStringLiteral("QUmlRelationship");
268     d->groupProperties.insert(QStringLiteral("QUmlRelationship"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("relatedElements"))));
269
270     d->propertyGroups << QStringLiteral("QUmlDirectedRelationship");
271     d->groupProperties.insert(QStringLiteral("QUmlDirectedRelationship"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("sources"))));
272     d->groupProperties.insert(QStringLiteral("QUmlDirectedRelationship"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("targets"))));
273
274     d->propertyGroups << QStringLiteral("QUmlElementImport");
275     d->groupProperties.insert(QStringLiteral("QUmlElementImport"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("alias"))));
276     d->groupProperties.insert(QStringLiteral("QUmlElementImport"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("importedElement"))));
277     d->groupProperties.insert(QStringLiteral("QUmlElementImport"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("importingNamespace"))));
278     d->groupProperties.insert(QStringLiteral("QUmlElementImport"), new QMetaProperty(metaObject->property(metaObject->indexOfProperty("visibility"))));
279 }
280
281 void QUmlElementImportObject::setPropertyData()
282 {
283     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedComments, AggregationRole, QStringLiteral("composite"));
284     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedComments, PropertyClassRole, QStringLiteral("QUmlElement"));
285     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedComments, IsDerivedRole, false);
286     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedComments, IsDerivedUnionRole, false);
287     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedComments, DocumentationRole, QStringLiteral("The Comments owned by this element."));
288     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedComments, RedefinedPropertiesRole, QStringLiteral(""));
289     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedComments, SubsettedPropertiesRole, QStringLiteral("Element-ownedElement"));
290     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedComments, OppositeEndRole, QStringLiteral(""));
291
292     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedElements, AggregationRole, QStringLiteral("composite"));
293     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedElements, PropertyClassRole, QStringLiteral("QUmlElement"));
294     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedElements, IsDerivedRole, true);
295     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedElements, IsDerivedUnionRole, true);
296     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedElements, DocumentationRole, QStringLiteral("The Elements owned by this element."));
297     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedElements, RedefinedPropertiesRole, QStringLiteral(""));
298     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedElements, SubsettedPropertiesRole, QStringLiteral(""));
299     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, ownedElements, OppositeEndRole, QStringLiteral("Element-owner"));
300
301     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, owner, AggregationRole, QStringLiteral("none"));
302     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, owner, PropertyClassRole, QStringLiteral("QUmlElement"));
303     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, owner, IsDerivedRole, true);
304     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, owner, IsDerivedUnionRole, true);
305     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, owner, DocumentationRole, QStringLiteral("The Element that owns this element."));
306     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, owner, RedefinedPropertiesRole, QStringLiteral(""));
307     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, owner, SubsettedPropertiesRole, QStringLiteral(""));
308     Q_DECLARE_METAPROPERTY_INFO(QUmlElement, owner, OppositeEndRole, QStringLiteral("Element-ownedElement"));
309
310     Q_DECLARE_METAPROPERTY_INFO(QUmlRelationship, relatedElements, AggregationRole, QStringLiteral("none"));
311     Q_DECLARE_METAPROPERTY_INFO(QUmlRelationship, relatedElements, PropertyClassRole, QStringLiteral("QUmlRelationship"));
312     Q_DECLARE_METAPROPERTY_INFO(QUmlRelationship, relatedElements, IsDerivedRole, true);
313     Q_DECLARE_METAPROPERTY_INFO(QUmlRelationship, relatedElements, IsDerivedUnionRole, true);
314     Q_DECLARE_METAPROPERTY_INFO(QUmlRelationship, relatedElements, DocumentationRole, QStringLiteral("Specifies the elements related by the Relationship."));
315     Q_DECLARE_METAPROPERTY_INFO(QUmlRelationship, relatedElements, RedefinedPropertiesRole, QStringLiteral(""));
316     Q_DECLARE_METAPROPERTY_INFO(QUmlRelationship, relatedElements, SubsettedPropertiesRole, QStringLiteral(""));
317     Q_DECLARE_METAPROPERTY_INFO(QUmlRelationship, relatedElements, OppositeEndRole, QStringLiteral(""));
318
319     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, sources, AggregationRole, QStringLiteral("none"));
320     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, sources, PropertyClassRole, QStringLiteral("QUmlDirectedRelationship"));
321     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, sources, IsDerivedRole, true);
322     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, sources, IsDerivedUnionRole, true);
323     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, sources, DocumentationRole, QStringLiteral("Specifies the sources of the DirectedRelationship."));
324     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, sources, RedefinedPropertiesRole, QStringLiteral(""));
325     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, sources, SubsettedPropertiesRole, QStringLiteral("Relationship-relatedElement"));
326     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, sources, OppositeEndRole, QStringLiteral(""));
327
328     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, targets, AggregationRole, QStringLiteral("none"));
329     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, targets, PropertyClassRole, QStringLiteral("QUmlDirectedRelationship"));
330     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, targets, IsDerivedRole, true);
331     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, targets, IsDerivedUnionRole, true);
332     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, targets, DocumentationRole, QStringLiteral("Specifies the targets of the DirectedRelationship."));
333     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, targets, RedefinedPropertiesRole, QStringLiteral(""));
334     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, targets, SubsettedPropertiesRole, QStringLiteral("Relationship-relatedElement"));
335     Q_DECLARE_METAPROPERTY_INFO(QUmlDirectedRelationship, targets, OppositeEndRole, QStringLiteral(""));
336
337     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, alias, AggregationRole, QStringLiteral("none"));
338     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, alias, PropertyClassRole, QStringLiteral("QUmlElementImport"));
339     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, alias, IsDerivedRole, false);
340     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, alias, IsDerivedUnionRole, false);
341     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, alias, DocumentationRole, QStringLiteral("Specifies the name that should be added to the namespace of the importing package in lieu of the name of the imported packagable element. The aliased name must not clash with any other member name in the importing package. By default, no alias is used."));
342     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, alias, RedefinedPropertiesRole, QStringLiteral(""));
343     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, alias, SubsettedPropertiesRole, QStringLiteral(""));
344     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, alias, OppositeEndRole, QStringLiteral(""));
345
346     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importedElement, AggregationRole, QStringLiteral("none"));
347     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importedElement, PropertyClassRole, QStringLiteral("QUmlElementImport"));
348     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importedElement, IsDerivedRole, false);
349     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importedElement, IsDerivedUnionRole, false);
350     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importedElement, DocumentationRole, QStringLiteral("Specifies the PackageableElement whose name is to be added to a Namespace."));
351     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importedElement, RedefinedPropertiesRole, QStringLiteral(""));
352     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importedElement, SubsettedPropertiesRole, QStringLiteral("DirectedRelationship-target"));
353     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importedElement, OppositeEndRole, QStringLiteral(""));
354
355     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importingNamespace, AggregationRole, QStringLiteral("none"));
356     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importingNamespace, PropertyClassRole, QStringLiteral("QUmlElementImport"));
357     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importingNamespace, IsDerivedRole, false);
358     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importingNamespace, IsDerivedUnionRole, false);
359     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importingNamespace, DocumentationRole, QStringLiteral("Specifies the Namespace that imports a PackageableElement from another Package."));
360     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importingNamespace, RedefinedPropertiesRole, QStringLiteral(""));
361     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importingNamespace, SubsettedPropertiesRole, QStringLiteral("Element-owner DirectedRelationship-source"));
362     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, importingNamespace, OppositeEndRole, QStringLiteral("Namespace-elementImport"));
363
364     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, visibility, AggregationRole, QStringLiteral("none"));
365     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, visibility, PropertyClassRole, QStringLiteral("QUmlElementImport"));
366     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, visibility, IsDerivedRole, false);
367     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, visibility, IsDerivedUnionRole, false);
368     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, visibility, DocumentationRole, QStringLiteral("Specifies the visibility of the imported PackageableElement within the importing Package. The default visibility is the same as that of the imported element. If the imported element does not have a visibility, it is possible to add visibility to the element import."));
369     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, visibility, RedefinedPropertiesRole, QStringLiteral(""));
370     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, visibility, SubsettedPropertiesRole, QStringLiteral(""));
371     Q_DECLARE_METAPROPERTY_INFO(QUmlElementImport, visibility, OppositeEndRole, QStringLiteral(""));
372
373 }
374
375 QT_END_NAMESPACE
376