It results in a EPackage instance that describes the UML metamodel.
Also, if I try to apply this profile to any models I build, the model is
persisted in a way that stereotype applications are lost. The reason
seems to be that the XMI for such a model refers to stereotypes coming
from 'sample_profile' as if they were coming from 'uml':

The reason for this behavior is that you have directly referenced a
primitive type (Integer) from the metamodel instead of from the primitive
types library (only metaclasses from the metamodel should be directly
referenced). With the current profile definition algorithm, metadata from
packages other than the profile being defined are copied into the definition
of the profile. This won't necessarily be the case once we fix https://bugs.eclipse.org/bugs/show_bug.cgi?id=163556. Please update that bug
or open a new one so that we'll remember to cover your use case. Thanks!

Kenn

"Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
news:epk79s$ith$1@utils.eclipse.org...
> When I define the following profile named 'sample_profile':
>
> <?xml version="1.0" encoding="UTF-8"?>
> <uml:Profile xmi:version="2.1"
> xmlns:xmi="http://schema.omg.org/spec/XMI/2.1"
> xmlns:uml="http://www.eclipse.org/uml2/2.0.0/UML"
> xmi:id="_O3cisK9mEduaoJ8VsHbaPQ" name="sample_profile">
> <packagedElement xmi:type="uml:Stereotype"
> xmi:id="_P7ic8K9mEduaoJ8VsHbaPQ" name="sample_stereotype">
> <ownedAttribute xmi:id="_Xjqr8K9mEduaoJ8VsHbaPQ" name="myProperty">
> <type xmi:type="uml:PrimitiveType"
> href="pathmap://UML_METAMODELS/UML.metamodel.uml#Integer"/>
> </ownedAttribute>
> </packagedElement>
> </uml:Profile>
>
> It results in a EPackage instance that describes the UML metamodel. Also,
> if I try to apply this profile to any models I build, the model is
> persisted in a way that stereotype applications are lost. The reason seems
> to be that the XMI for such a model refers to stereotypes coming from
> 'sample_profile' as if they were coming from 'uml':
>
> <xmi:XMI xmi:version="2.1" (...)>
> <uml:Model xmi:id="_2YHtEK9lEdu8D5FNufO7zw" name="sample_model">
> (...)
> </uml:Model>
> <uml:sample_stereotype (...) />
> </xmi:XMI>
>
> Instead, I would expect the stereotype applications to appear as:
>
> <sample_profile:sample_stereotype (...) />
>
> The trigger to this problem seems to be that I am referring to a type from
> the uml package (integer). If I remove the reference, the problem goes
> away.
>
> Am I doing anything wrong to cause this, or is this a bug?
>
> Thanks,
>
> Rafael

> The reason for this behavior is that you have directly referenced a
> primitive type (Integer) from the metamodel instead of from the
> primitive types library (only metaclasses from the metamodel
> should be directly referenced)

Is there a place where one can learn about rules like that?

In the specific case, should my profile be importing UMLPrimitiveTypes
instead (and references to uml::Integer be changed to
UMLPrimitiveTypes::Integer)?

Thanks,

Rafael

Kenn Hussey wrote:
> Rafael,
>
> The reason for this behavior is that you have directly referenced a
> primitive type (Integer) from the metamodel instead of from the primitive
> types library (only metaclasses from the metamodel should be directly
> referenced). With the current profile definition algorithm, metadata from
> packages other than the profile being defined are copied into the definition
> of the profile. This won't necessarily be the case once we fix
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=163556. Please update that bug
> or open a new one so that we'll remember to cover your use case. Thanks!
>
> Kenn
>
> "Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
> news:epk79s$ith$1@utils.eclipse.org...
>> When I define the following profile named 'sample_profile':
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <uml:Profile xmi:version="2.1"
>> xmlns:xmi="http://schema.omg.org/spec/XMI/2.1"
>> xmlns:uml="http://www.eclipse.org/uml2/2.0.0/UML"
>> xmi:id="_O3cisK9mEduaoJ8VsHbaPQ" name="sample_profile">
>> <packagedElement xmi:type="uml:Stereotype"
>> xmi:id="_P7ic8K9mEduaoJ8VsHbaPQ" name="sample_stereotype">
>> <ownedAttribute xmi:id="_Xjqr8K9mEduaoJ8VsHbaPQ" name="myProperty">
>> <type xmi:type="uml:PrimitiveType"
>> href="pathmap://UML_METAMODELS/UML.metamodel.uml#Integer"/>
>> </ownedAttribute>
>> </packagedElement>
>> </uml:Profile>
>>
>> It results in a EPackage instance that describes the UML metamodel. Also,
>> if I try to apply this profile to any models I build, the model is
>> persisted in a way that stereotype applications are lost. The reason seems
>> to be that the XMI for such a model refers to stereotypes coming from
>> 'sample_profile' as if they were coming from 'uml':
>>
>> <xmi:XMI xmi:version="2.1" (...)>
>> <uml:Model xmi:id="_2YHtEK9lEdu8D5FNufO7zw" name="sample_model">
>> (...)
>> </uml:Model>
>> <uml:sample_stereotype (...) />
>> </xmi:XMI>
>>
>> Instead, I would expect the stereotype applications to appear as:
>>
>> <sample_profile:sample_stereotype (...) />
>>
>> The trigger to this problem seems to be that I am referring to a type from
>> the uml package (integer). If I remove the reference, the problem goes
>> away.
>>
>> Am I doing anything wrong to cause this, or is this a bug?
>>
>> Thanks,
>>
>> Rafael
>
>

The "expected" way to use primitive types is described in the articles
available at http://wiki.eclipse.org/index.php/MDT-UML2#Articles. Strictly
speaking, there's nothing wrong with a profile referencing a primitive type
defined in another model or profile...

Kenn

"Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
news:eplf98$bv0$1@utils.eclipse.org...
> Thanks, Kenn, I opened bug 172030:
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=172030
>
> > The reason for this behavior is that you have directly referenced a
> > primitive type (Integer) from the metamodel instead of from the
> > primitive types library (only metaclasses from the metamodel
> > should be directly referenced)
>
> Is there a place where one can learn about rules like that?
>
> In the specific case, should my profile be importing UMLPrimitiveTypes
> instead (and references to uml::Integer be changed to
> UMLPrimitiveTypes::Integer)?
>
> Thanks,
>
> Rafael
>
> Kenn Hussey wrote:
>> Rafael,
>>
>> The reason for this behavior is that you have directly referenced a
>> primitive type (Integer) from the metamodel instead of from the primitive
>> types library (only metaclasses from the metamodel should be directly
>> referenced). With the current profile definition algorithm, metadata from
>> packages other than the profile being defined are copied into the
>> definition of the profile. This won't necessarily be the case once we fix
>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=163556. Please update that
>> bug or open a new one so that we'll remember to cover your use case.
>> Thanks!
>>
>> Kenn
>>
>> "Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
>> news:epk79s$ith$1@utils.eclipse.org...
>>> When I define the following profile named 'sample_profile':
>>>
>>> <?xml version="1.0" encoding="UTF-8"?>
>>> <uml:Profile xmi:version="2.1"
>>> xmlns:xmi="http://schema.omg.org/spec/XMI/2.1"
>>> xmlns:uml="http://www.eclipse.org/uml2/2.0.0/UML"
>>> xmi:id="_O3cisK9mEduaoJ8VsHbaPQ" name="sample_profile">
>>> <packagedElement xmi:type="uml:Stereotype"
>>> xmi:id="_P7ic8K9mEduaoJ8VsHbaPQ" name="sample_stereotype">
>>> <ownedAttribute xmi:id="_Xjqr8K9mEduaoJ8VsHbaPQ" name="myProperty">
>>> <type xmi:type="uml:PrimitiveType"
>>> href="pathmap://UML_METAMODELS/UML.metamodel.uml#Integer"/>
>>> </ownedAttribute>
>>> </packagedElement>
>>> </uml:Profile>
>>>
>>> It results in a EPackage instance that describes the UML metamodel.
>>> Also, if I try to apply this profile to any models I build, the model is
>>> persisted in a way that stereotype applications are lost. The reason
>>> seems to be that the XMI for such a model refers to stereotypes coming
>>> from 'sample_profile' as if they were coming from 'uml':
>>>
>>> <xmi:XMI xmi:version="2.1" (...)>
>>> <uml:Model xmi:id="_2YHtEK9lEdu8D5FNufO7zw" name="sample_model">
>>> (...)
>>> </uml:Model>
>>> <uml:sample_stereotype (...) />
>>> </xmi:XMI>
>>>
>>> Instead, I would expect the stereotype applications to appear as:
>>>
>>> <sample_profile:sample_stereotype (...) />
>>>
>>> The trigger to this problem seems to be that I am referring to a type
>>> from the uml package (integer). If I remove the reference, the problem
>>> goes away.
>>>
>>> Am I doing anything wrong to cause this, or is this a bug?
>>>
>>> Thanks,
>>>
>>> Rafael
>>

Yes, I understand that. The problem in this specific case was that the
primitive types in "uml" were private and I hadn't noticed it.

Thanks!

Rafael

Kenn Hussey wrote:
> Rafael,
>
> The "expected" way to use primitive types is described in the articles
> available at http://wiki.eclipse.org/index.php/MDT-UML2#Articles. Strictly
> speaking, there's nothing wrong with a profile referencing a primitive type
> defined in another model or profile...
>
> Kenn
>
> "Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
> news:eplf98$bv0$1@utils.eclipse.org...
>> Thanks, Kenn, I opened bug 172030:
>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=172030
>>
>>> The reason for this behavior is that you have directly referenced a
>>> primitive type (Integer) from the metamodel instead of from the
>>> primitive types library (only metaclasses from the metamodel
>>> should be directly referenced)
>> Is there a place where one can learn about rules like that?
>>
>> In the specific case, should my profile be importing UMLPrimitiveTypes
>> instead (and references to uml::Integer be changed to
>> UMLPrimitiveTypes::Integer)?
>>
>> Thanks,
>>
>> Rafael
>>
>> Kenn Hussey wrote:
>>> Rafael,
>>>
>>> The reason for this behavior is that you have directly referenced a
>>> primitive type (Integer) from the metamodel instead of from the primitive
>>> types library (only metaclasses from the metamodel should be directly
>>> referenced). With the current profile definition algorithm, metadata from
>>> packages other than the profile being defined are copied into the
>>> definition of the profile. This won't necessarily be the case once we fix
>>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=163556. Please update that
>>> bug or open a new one so that we'll remember to cover your use case.
>>> Thanks!
>>>
>>> Kenn
>>>
>>> "Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
>>> news:epk79s$ith$1@utils.eclipse.org...
>>>> When I define the following profile named 'sample_profile':
>>>>
>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>> <uml:Profile xmi:version="2.1"
>>>> xmlns:xmi="http://schema.omg.org/spec/XMI/2.1"
>>>> xmlns:uml="http://www.eclipse.org/uml2/2.0.0/UML"
>>>> xmi:id="_O3cisK9mEduaoJ8VsHbaPQ" name="sample_profile">
>>>> <packagedElement xmi:type="uml:Stereotype"
>>>> xmi:id="_P7ic8K9mEduaoJ8VsHbaPQ" name="sample_stereotype">
>>>> <ownedAttribute xmi:id="_Xjqr8K9mEduaoJ8VsHbaPQ" name="myProperty">
>>>> <type xmi:type="uml:PrimitiveType"
>>>> href="pathmap://UML_METAMODELS/UML.metamodel.uml#Integer"/>
>>>> </ownedAttribute>
>>>> </packagedElement>
>>>> </uml:Profile>
>>>>
>>>> It results in a EPackage instance that describes the UML metamodel.
>>>> Also, if I try to apply this profile to any models I build, the model is
>>>> persisted in a way that stereotype applications are lost. The reason
>>>> seems to be that the XMI for such a model refers to stereotypes coming
>>>> from 'sample_profile' as if they were coming from 'uml':
>>>>
>>>> <xmi:XMI xmi:version="2.1" (...)>
>>>> <uml:Model xmi:id="_2YHtEK9lEdu8D5FNufO7zw" name="sample_model">
>>>> (...)
>>>> </uml:Model>
>>>> <uml:sample_stereotype (...) />
>>>> </xmi:XMI>
>>>>
>>>> Instead, I would expect the stereotype applications to appear as:
>>>>
>>>> <sample_profile:sample_stereotype (...) />
>>>>
>>>> The trigger to this problem seems to be that I am referring to a type
>>>> from the uml package (integer). If I remove the reference, the problem
>>>> goes away.
>>>>
>>>> Am I doing anything wrong to cause this, or is this a bug?
>>>>
>>>> Thanks,
>>>>
>>>> Rafael
>

The reason for this behavior is that you have directly referenced a
primitive type (Integer) from the metamodel instead of from the primitive
types library (only metaclasses from the metamodel should be directly
referenced). With the current profile definition algorithm, metadata from
packages other than the profile being defined are copied into the definition
of the profile. This won't necessarily be the case once we fix https://bugs.eclipse.org/bugs/show_bug.cgi?id=163556 Please update that bug
or open a new one so that we'll remember to cover your use case. Thanks!

Kenn

"Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
news:epk79s$ith$1@utils.eclipse.org...
> When I define the following profile named 'sample_profile':
>
> <?xml version="1.0" encoding="UTF-8"?>
> <uml:Profile xmi:version="2.1"
> xmlns:xmi="http://schema.omg.org/spec/XMI/2.1"
> xmlns:uml="http://www.eclipse.org/uml2/2.0.0/UML"
> xmi:id="_O3cisK9mEduaoJ8VsHbaPQ" name="sample_profile">
> <packagedElement xmi:type="uml:Stereotype"
> xmi:id="_P7ic8K9mEduaoJ8VsHbaPQ" name="sample_stereotype">
> <ownedAttribute xmi:id="_Xjqr8K9mEduaoJ8VsHbaPQ" name="myProperty">
> <type xmi:type="uml:PrimitiveType"
> href="pathmap://UML_METAMODELS/UML.metamodel.uml#Integer"/>
> </ownedAttribute>
> </packagedElement>
> </uml:Profile>
>
> It results in a EPackage instance that describes the UML metamodel. Also,
> if I try to apply this profile to any models I build, the model is
> persisted in a way that stereotype applications are lost. The reason seems
> to be that the XMI for such a model refers to stereotypes coming from
> 'sample_profile' as if they were coming from 'uml':
>
> <xmi:XMI xmi:version="2.1" (...)>
> <uml:Model xmi:id="_2YHtEK9lEdu8D5FNufO7zw" name="sample_model">
> (...)
> </uml:Model>
> <uml:sample_stereotype (...) />
> </xmi:XMI>
>
> Instead, I would expect the stereotype applications to appear as:
>
> <sample_profile:sample_stereotype (...) />
>
> The trigger to this problem seems to be that I am referring to a type from
> the uml package (integer). If I remove the reference, the problem goes
> away.
>
> Am I doing anything wrong to cause this, or is this a bug?
>
> Thanks,
>
> Rafael

> The reason for this behavior is that you have directly referenced a
> primitive type (Integer) from the metamodel instead of from the
> primitive types library (only metaclasses from the metamodel
> should be directly referenced)

Is there a place where one can learn about rules like that?

In the specific case, should my profile be importing UMLPrimitiveTypes
instead (and references to uml::Integer be changed to
UMLPrimitiveTypes::Integer)?

Thanks,

Rafael

Kenn Hussey wrote:
> Rafael,
>
> The reason for this behavior is that you have directly referenced a
> primitive type (Integer) from the metamodel instead of from the primitive
> types library (only metaclasses from the metamodel should be directly
> referenced). With the current profile definition algorithm, metadata from
> packages other than the profile being defined are copied into the definition
> of the profile. This won't necessarily be the case once we fix
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=163556 Please update that bug
> or open a new one so that we'll remember to cover your use case. Thanks!
>
> Kenn
>
> "Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
> news:epk79s$ith$1@utils.eclipse.org...
>> When I define the following profile named 'sample_profile':
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <uml:Profile xmi:version="2.1"
>> xmlns:xmi="http://schema.omg.org/spec/XMI/2.1"
>> xmlns:uml="http://www.eclipse.org/uml2/2.0.0/UML"
>> xmi:id="_O3cisK9mEduaoJ8VsHbaPQ" name="sample_profile">
>> <packagedElement xmi:type="uml:Stereotype"
>> xmi:id="_P7ic8K9mEduaoJ8VsHbaPQ" name="sample_stereotype">
>> <ownedAttribute xmi:id="_Xjqr8K9mEduaoJ8VsHbaPQ" name="myProperty">
>> <type xmi:type="uml:PrimitiveType"
>> href="pathmap://UML_METAMODELS/UML.metamodel.uml#Integer"/>
>> </ownedAttribute>
>> </packagedElement>
>> </uml:Profile>
>>
>> It results in a EPackage instance that describes the UML metamodel. Also,
>> if I try to apply this profile to any models I build, the model is
>> persisted in a way that stereotype applications are lost. The reason seems
>> to be that the XMI for such a model refers to stereotypes coming from
>> 'sample_profile' as if they were coming from 'uml':
>>
>> <xmi:XMI xmi:version="2.1" (...)>
>> <uml:Model xmi:id="_2YHtEK9lEdu8D5FNufO7zw" name="sample_model">
>> (...)
>> </uml:Model>
>> <uml:sample_stereotype (...) />
>> </xmi:XMI>
>>
>> Instead, I would expect the stereotype applications to appear as:
>>
>> <sample_profile:sample_stereotype (...) />
>>
>> The trigger to this problem seems to be that I am referring to a type from
>> the uml package (integer). If I remove the reference, the problem goes
>> away.
>>
>> Am I doing anything wrong to cause this, or is this a bug?
>>
>> Thanks,
>>
>> Rafael
>
>

The "expected" way to use primitive types is described in the articles
available at http://wiki.eclipse.org/index.php/MDT-UML2#Articles Strictly
speaking, there's nothing wrong with a profile referencing a primitive type
defined in another model or profile...

Kenn

"Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
news:eplf98$bv0$1@utils.eclipse.org...
> Thanks, Kenn, I opened bug 172030:
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=172030
>
> > The reason for this behavior is that you have directly referenced a
> > primitive type (Integer) from the metamodel instead of from the
> > primitive types library (only metaclasses from the metamodel
> > should be directly referenced)
>
> Is there a place where one can learn about rules like that?
>
> In the specific case, should my profile be importing UMLPrimitiveTypes
> instead (and references to uml::Integer be changed to
> UMLPrimitiveTypes::Integer)?
>
> Thanks,
>
> Rafael
>
> Kenn Hussey wrote:
>> Rafael,
>>
>> The reason for this behavior is that you have directly referenced a
>> primitive type (Integer) from the metamodel instead of from the primitive
>> types library (only metaclasses from the metamodel should be directly
>> referenced). With the current profile definition algorithm, metadata from
>> packages other than the profile being defined are copied into the
>> definition of the profile. This won't necessarily be the case once we fix
>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=163556 Please update that
>> bug or open a new one so that we'll remember to cover your use case.
>> Thanks!
>>
>> Kenn
>>
>> "Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
>> news:epk79s$ith$1@utils.eclipse.org...
>>> When I define the following profile named 'sample_profile':
>>>
>>> <?xml version="1.0" encoding="UTF-8"?>
>>> <uml:Profile xmi:version="2.1"
>>> xmlns:xmi="http://schema.omg.org/spec/XMI/2.1"
>>> xmlns:uml="http://www.eclipse.org/uml2/2.0.0/UML"
>>> xmi:id="_O3cisK9mEduaoJ8VsHbaPQ" name="sample_profile">
>>> <packagedElement xmi:type="uml:Stereotype"
>>> xmi:id="_P7ic8K9mEduaoJ8VsHbaPQ" name="sample_stereotype">
>>> <ownedAttribute xmi:id="_Xjqr8K9mEduaoJ8VsHbaPQ" name="myProperty">
>>> <type xmi:type="uml:PrimitiveType"
>>> href="pathmap://UML_METAMODELS/UML.metamodel.uml#Integer"/>
>>> </ownedAttribute>
>>> </packagedElement>
>>> </uml:Profile>
>>>
>>> It results in a EPackage instance that describes the UML metamodel.
>>> Also, if I try to apply this profile to any models I build, the model is
>>> persisted in a way that stereotype applications are lost. The reason
>>> seems to be that the XMI for such a model refers to stereotypes coming
>>> from 'sample_profile' as if they were coming from 'uml':
>>>
>>> <xmi:XMI xmi:version="2.1" (...)>
>>> <uml:Model xmi:id="_2YHtEK9lEdu8D5FNufO7zw" name="sample_model">
>>> (...)
>>> </uml:Model>
>>> <uml:sample_stereotype (...) />
>>> </xmi:XMI>
>>>
>>> Instead, I would expect the stereotype applications to appear as:
>>>
>>> <sample_profile:sample_stereotype (...) />
>>>
>>> The trigger to this problem seems to be that I am referring to a type
>>> from the uml package (integer). If I remove the reference, the problem
>>> goes away.
>>>
>>> Am I doing anything wrong to cause this, or is this a bug?
>>>
>>> Thanks,
>>>
>>> Rafael
>>

Yes, I understand that. The problem in this specific case was that the
primitive types in "uml" were private and I hadn't noticed it.

Thanks!

Rafael

Kenn Hussey wrote:
> Rafael,
>
> The "expected" way to use primitive types is described in the articles
> available at http://wiki.eclipse.org/index.php/MDT-UML2#Articles Strictly
> speaking, there's nothing wrong with a profile referencing a primitive type
> defined in another model or profile...
>
> Kenn
>
> "Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
> news:eplf98$bv0$1@utils.eclipse.org...
>> Thanks, Kenn, I opened bug 172030:
>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=172030
>>
>>> The reason for this behavior is that you have directly referenced a
>>> primitive type (Integer) from the metamodel instead of from the
>>> primitive types library (only metaclasses from the metamodel
>>> should be directly referenced)
>> Is there a place where one can learn about rules like that?
>>
>> In the specific case, should my profile be importing UMLPrimitiveTypes
>> instead (and references to uml::Integer be changed to
>> UMLPrimitiveTypes::Integer)?
>>
>> Thanks,
>>
>> Rafael
>>
>> Kenn Hussey wrote:
>>> Rafael,
>>>
>>> The reason for this behavior is that you have directly referenced a
>>> primitive type (Integer) from the metamodel instead of from the primitive
>>> types library (only metaclasses from the metamodel should be directly
>>> referenced). With the current profile definition algorithm, metadata from
>>> packages other than the profile being defined are copied into the
>>> definition of the profile. This won't necessarily be the case once we fix
>>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=163556 Please update that
>>> bug or open a new one so that we'll remember to cover your use case.
>>> Thanks!
>>>
>>> Kenn
>>>
>>> "Rafael Chaves" <chaves@inf.ufsc.nospam.br> wrote in message
>>> news:epk79s$ith$1@utils.eclipse.org...
>>>> When I define the following profile named 'sample_profile':
>>>>
>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>> <uml:Profile xmi:version="2.1"
>>>> xmlns:xmi="http://schema.omg.org/spec/XMI/2.1"
>>>> xmlns:uml="http://www.eclipse.org/uml2/2.0.0/UML"
>>>> xmi:id="_O3cisK9mEduaoJ8VsHbaPQ" name="sample_profile">
>>>> <packagedElement xmi:type="uml:Stereotype"
>>>> xmi:id="_P7ic8K9mEduaoJ8VsHbaPQ" name="sample_stereotype">
>>>> <ownedAttribute xmi:id="_Xjqr8K9mEduaoJ8VsHbaPQ" name="myProperty">
>>>> <type xmi:type="uml:PrimitiveType"
>>>> href="pathmap://UML_METAMODELS/UML.metamodel.uml#Integer"/>
>>>> </ownedAttribute>
>>>> </packagedElement>
>>>> </uml:Profile>
>>>>
>>>> It results in a EPackage instance that describes the UML metamodel.
>>>> Also, if I try to apply this profile to any models I build, the model is
>>>> persisted in a way that stereotype applications are lost. The reason
>>>> seems to be that the XMI for such a model refers to stereotypes coming
>>>> from 'sample_profile' as if they were coming from 'uml':
>>>>
>>>> <xmi:XMI xmi:version="2.1" (...)>
>>>> <uml:Model xmi:id="_2YHtEK9lEdu8D5FNufO7zw" name="sample_model">
>>>> (...)
>>>> </uml:Model>
>>>> <uml:sample_stereotype (...) />
>>>> </xmi:XMI>
>>>>
>>>> Instead, I would expect the stereotype applications to appear as:
>>>>
>>>> <sample_profile:sample_stereotype (...) />
>>>>
>>>> The trigger to this problem seems to be that I am referring to a type
>>>> from the uml package (integer). If I remove the reference, the problem
>>>> goes away.
>>>>
>>>> Am I doing anything wrong to cause this, or is this a bug?
>>>>
>>>> Thanks,
>>>>
>>>> Rafael
>