Questions concerning Property definition pragma

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Questions concerning Property definition pragma

Anne Etien
Hi,

I am currently preparing a teaching course for next week (sorry, the support will be in French) explaining to the students what is a metamodel and how to create a new one with Moose.
For this purpose, I have to explain how to create properties in Famix.
For example:
        <MSEProperty: #name type: #String>
        <MSEComment: 'Basic name of the entity, not full reference.’>

What are the accepted primitive types String and what else?
It seems that Integer is not accepted. And what about Date or DateAndTime?
In fact it seems that only String is accepted.

In my case, the svn log metamodel, a Commit has a revision number (Integer) and a date (DateAndTime).

Is there something I am missing?

Thank you in advance for your help.

Anne
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.list.inf.unibe.ch/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: Questions concerning Property definition pragma

Tudor Girba-2
Hi,

type can point to either a primitive type (in Fame, these are: Boolean, String, Number) or to another type defined in the meta-model.

For the record, take a look at:
(PragmaType all detect: [ :each | each name = #'MSEProperty:type:' ]) pragmas

And here are the different types in a Moose image:
(PragmaType all detect: [ :each | each name = #'MSEProperty:type:' ])
pragmas collectAsSet: [ :each | each arguments second ] "a Set(#FAMIXModule #FAMIXClass #FAMIXParameterType #EQEquation #FAMIXFileAnchor #FAMIXBehaviouralEntity #EQOperator #FM3Element #Number #EQIdentifier #FAMIXSourceLanguage #LIBBook #EQVariable 'FM3.Property' #LIBPerson #EQExpression #FAMIXMethod #FAMIXNamedEntity #Boolean #FAMIXType #FAMIXAnnotationType #String #FM3MetaDescription)"

Cheers,
Tudor


On Mon, Oct 26, 2015 at 5:39 PM, Anne Etien <[hidden email]> wrote:
Hi,

I am currently preparing a teaching course for next week (sorry, the support will be in French) explaining to the students what is a metamodel and how to create a new one with Moose.
For this purpose, I have to explain how to create properties in Famix.
For example:
        <MSEProperty: #name type: #String>
        <MSEComment: 'Basic name of the entity, not full reference.’>

What are the accepted primitive types String and what else?
It seems that Integer is not accepted. And what about Date or DateAndTime?
In fact it seems that only String is accepted.

In my case, the svn log metamodel, a Commit has a revision number (Integer) and a date (DateAndTime).

Is there something I am missing?

Thank you in advance for your help.

Anne
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.list.inf.unibe.ch/listinfo/moose-dev



--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.list.inf.unibe.ch/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: Questions concerning Property definition pragma

Anne Etien
Thank you.
Anne
Le 26 oct. 2015 à 17:44, Tudor Girba <[hidden email]> a écrit :

Hi,

type can point to either a primitive type (in Fame, these are: Boolean, String, Number) or to another type defined in the meta-model.

For the record, take a look at:
(PragmaType all detect: [ :each | each name = #'MSEProperty:type:' ]) pragmas

And here are the different types in a Moose image:
(PragmaType all detect: [ :each | each name = #'MSEProperty:type:' ])
pragmas collectAsSet: [ :each | each arguments second ] "a Set(#FAMIXModule #FAMIXClass #FAMIXParameterType #EQEquation #FAMIXFileAnchor #FAMIXBehaviouralEntity #EQOperator #FM3Element #Number #EQIdentifier #FAMIXSourceLanguage #LIBBook #EQVariable 'FM3.Property' #LIBPerson #EQExpression #FAMIXMethod #FAMIXNamedEntity #Boolean #FAMIXType #FAMIXAnnotationType #String #FM3MetaDescription)"

Cheers,
Tudor


On Mon, Oct 26, 2015 at 5:39 PM, Anne Etien <[hidden email]> wrote:
Hi,

I am currently preparing a teaching course for next week (sorry, the support will be in French) explaining to the students what is a metamodel and how to create a new one with Moose.
For this purpose, I have to explain how to create properties in Famix.
For example:
        <MSEProperty: #name type: #String>
        <MSEComment: 'Basic name of the entity, not full reference.’>

What are the accepted primitive types String and what else?
It seems that Integer is not accepted. And what about Date or DateAndTime?
In fact it seems that only String is accepted.

In my case, the svn log metamodel, a Commit has a revision number (Integer) and a date (DateAndTime).

Is there something I am missing?

Thank you in advance for your help.

Anne
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.list.inf.unibe.ch/listinfo/moose-dev



--

"Every thing has its own flow"
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.list.inf.unibe.ch/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.list.inf.unibe.ch/listinfo/moose-dev