Error after applying the stereotype EClass to a Class [message #477219] |
Wed, 09 April 2008 10:52  |
Eclipse User |
|
|
|
Originally posted by: markus.heintz.iese.fhg.de
Hi
After applying the sterotype eClass to a UML class, I get the following
error message when I validate the UML model:
The required feature 'base_Interface' of 'EClass -> <<eClass>> <Class> X '
must be set
The required feature 'base_DataType' of 'EClass -> <<eClass>> <Class> X '
must be set
where 'X' is the name of the class.
I tried two things:
1) - I created a UML model using the UML Editor and the diagram editor
- Then I applied the UML Ecore Profile to the model using the UML
Editor
- Then I applied the sterotype EPackage to the root package element.
- Validating the model now shows no error
- When I apply the sterotype EClass to a plain UML class I get the
above mentioned
error messages after validating the model
2) - I exported a valid core ecore model to a UML model. When I validate
the UML model I get the above error messages for every UML class
Since I'm still exploring the UML2 tools and EMF I wonder if I forgot to do
something or made a mistake.
Can anybody give me a hint why I get this error messages?
Thanks a lot
Markus
|
|
|
Re: Error after applying the stereotype EClass to a Class [message #477223 is a reply to message #477219] |
Wed, 09 April 2008 11:17  |
Eclipse User |
|
|
|
Hi Markus,
What you are seeing is "OK". It came up recently in another post
concerning validation of superstructure.uml see "Package merge" from
3/30/2008.
It has to do with the EClass stereotype extending multiple metaclasses,
thereby creating several required features "base_xxx". Their lower bound
is 1, not 0 so they are required to be set from an Ecore validation
perspective. We really want to say that exactly one of those "base_xxx"
get set so we would in theory either need an OCL constraint indicating that,
or the lower bound should be changed to 0 ( which is not supported from a
UML perspective ).
I will look into addressing this problem but in the meantime, you can
double check that at most one "base_xxx" is getting set and ignore the
warning for now.
Cheers,
- James.
"Markus Heintz" <markus.heintz@iese.fhg.de> wrote in message
news:ftil7h$ar3$1@build.eclipse.org...
> Hi
>
> After applying the sterotype eClass to a UML class, I get the following
> error message when I validate the UML model:
>
> The required feature 'base_Interface' of 'EClass -> <<eClass>> <Class> X '
> must be set
> The required feature 'base_DataType' of 'EClass -> <<eClass>> <Class> X '
> must be set
>
> where 'X' is the name of the class.
>
> I tried two things:
>
> 1) - I created a UML model using the UML Editor and the diagram editor
> - Then I applied the UML Ecore Profile to the model using the UML
> Editor
> - Then I applied the sterotype EPackage to the root package element.
> - Validating the model now shows no error
> - When I apply the sterotype EClass to a plain UML class I get the
> above mentioned
> error messages after validating the model
>
> 2) - I exported a valid core ecore model to a UML model. When I
> validate the UML model I get the above error messages for every UML class
>
> Since I'm still exploring the UML2 tools and EMF I wonder if I forgot to
> do something or made a mistake.
> Can anybody give me a hint why I get this error messages?
>
> Thanks a lot
> Markus
>
>
>
|
|
|
Re: Error after applying the stereotype EClass to a Class [message #626381 is a reply to message #477219] |
Wed, 09 April 2008 11:17  |
Eclipse User |
|
|
|
Hi Markus,
What you are seeing is "OK". It came up recently in another post
concerning validation of superstructure.uml see "Package merge" from
3/30/2008.
It has to do with the EClass stereotype extending multiple metaclasses,
thereby creating several required features "base_xxx". Their lower bound
is 1, not 0 so they are required to be set from an Ecore validation
perspective. We really want to say that exactly one of those "base_xxx"
get set so we would in theory either need an OCL constraint indicating that,
or the lower bound should be changed to 0 ( which is not supported from a
UML perspective ).
I will look into addressing this problem but in the meantime, you can
double check that at most one "base_xxx" is getting set and ignore the
warning for now.
Cheers,
- James.
"Markus Heintz" <markus.heintz@iese.fhg.de> wrote in message
news:ftil7h$ar3$1@build.eclipse.org...
> Hi
>
> After applying the sterotype eClass to a UML class, I get the following
> error message when I validate the UML model:
>
> The required feature 'base_Interface' of 'EClass -> <<eClass>> <Class> X '
> must be set
> The required feature 'base_DataType' of 'EClass -> <<eClass>> <Class> X '
> must be set
>
> where 'X' is the name of the class.
>
> I tried two things:
>
> 1) - I created a UML model using the UML Editor and the diagram editor
> - Then I applied the UML Ecore Profile to the model using the UML
> Editor
> - Then I applied the sterotype EPackage to the root package element.
> - Validating the model now shows no error
> - When I apply the sterotype EClass to a plain UML class I get the
> above mentioned
> error messages after validating the model
>
> 2) - I exported a valid core ecore model to a UML model. When I
> validate the UML model I get the above error messages for every UML class
>
> Since I'm still exploring the UML2 tools and EMF I wonder if I forgot to
> do something or made a mistake.
> Can anybody give me a hint why I get this error messages?
>
> Thanks a lot
> Markus
>
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.02766 seconds