About properties

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

About properties

Andre Hora
Hi guys

we are hacking with andre some tests for the exporter.
Now we would like to compare two FAMIX entities and in particular their properties here are a bunch of questions we got

- why there is no class comment on MSEDefaultState and friends?
what is the difference between a property and an attributes

- how can I get all the properties defined on an entity?
there is allDefinedProperties

Now how can I apply a given FMDescription of a property obtained from the the allDefinedProperties to a given entity

I was thinking about

aDescription valueFor: anEntity

Stef and Andre
--
Andre Hora


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

Re: About properties

Tudor Girba-2
Hi,

On 15 Jul 2011, at 16:39, Andre Hora wrote:

> Hi guys
>
> we are hacking with andre some tests for the exporter.
> Now we would like to compare two FAMIX entities and in particular their properties here are a bunch of questions we got
>
> - why there is no class comment on MSEDefaultState and friends?

Because nobody wrote one.

> what is the difference between a property and an attributes

- attributes are meant to be used for defining meta-model extensions (like adding relations to new entities)
- properties are meant to be used for caching the value of various computations such as metrics

> - how can I get all the properties defined on an entity?
> there is allDefinedProperties

Yes, this is the one (like the model says).

MooseEntity>>allDeclaredProperties
        "All properties described in the metamodel"
         
        ^self mooseDescription allAttributes

> Now how can I apply a given FMDescription of a property obtained from the the allDefinedProperties to a given entity
>
> I was thinking about
>
> aDescription valueFor: anEntity

Look in the accessing-meta protocol from FM3PropertyDescription

Cheers,
Doru



> Stef and Andre
> --
> Andre Hora
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

--
www.tudorgirba.com

"The coherence of a trip is given by the clearness of the goal."





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

Re: About properties

Stéphane Ducasse
>
>> Hi guys
>>
>> we are hacking with andre some tests for the exporter.
>> Now we would like to compare two FAMIX entities and in particular their properties here are a bunch of questions we got
>>
>> - why there is no class comment on MSEDefaultState and friends?
>
> Because nobody wrote one.

I know because I wrote a lot of the one on FM3 when you were at my place.
Now it would be good to add some more.

>
>> what is the difference between a property and an attributes
>
> - attributes are meant to be used for defining meta-model extensions (like adding relations to new entities)
> - properties are meant to be used for caching the value of various computations such as metrics
>
>> - how can I get all the properties defined on an entity?
>> there is allDefinedProperties
>
> Yes, this is the one (like the model says).


But allDeclaredProperties also returns attributes. so this is not exactly what we want.

>
> MooseEntity>>allDeclaredProperties
> "All properties described in the metamodel"
>
> ^self mooseDescription allAttributes
>
>> Now how can I apply a given FMDescription of a property obtained from the the allDefinedProperties to a given entity
>>
>> I was thinking about
>>
>> aDescription valueFor: anEntity
>
> Look in the accessing-meta protocol from FM3PropertyDescription

We found getFrom:


>
> Cheers,
> Doru
>
>
>
>> Stef and Andre
>> --
>> Andre Hora
>>
>> _______________________________________________
>> Moose-dev mailing list
>> [hidden email]
>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
> --
> www.tudorgirba.com
>
> "The coherence of a trip is given by the clearness of the goal."
>
>
>
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev


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