MooseChef & "hidden dependencies"

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

MooseChef & "hidden dependencies"

Nicolas Anquetil

As all of us know, Famix recognizes 4 types of associations (reference, access, inheritance, invocation) and Moosechef was built upon these dependencies (queryAllOutgoingReferences, ...)

For convenience, it adds queryAllOutgoingDependencies
but this will miss a good deal of actual dependencies, because many of them are not expressed by associations:
- return type of a method
- type of a variable
- exceptions caught, thrown
- parameter types in parameterized classes
- use of annotations
- other?

Since we now have a nice general API to query dependencies, it would be nicer if it were complete, ...

A possible solution would to rename queryAllOutgoingDependencies into queryAllOutgoingAssociations and change queryAllOutgoingDependencies to "do the right thing"

Or maybe invent new "virtual associations" (like ofType) and create queries for these associations, ...

nicolas

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

Re: MooseChef & "hidden dependencies"

Andre Hora
Just to complement the list:

- return type of a method
- type of a variable:
     - Parameter
     - Local variable
     - Attribute
- exceptions:
   - caught
   - thrown
   - declared
- parameter types in parameterized classes
- use of annotations
- other?

On Wed, Nov 30, 2011 at 6:00 PM, Nicolas Anquetil <[hidden email]> wrote:

As all of us know, Famix recognizes 4 types of associations (reference, access, inheritance, invocation) and Moosechef was built upon these dependencies (queryAllOutgoingReferences, ...)

For convenience, it adds queryAllOutgoingDependencies
but this will miss a good deal of actual dependencies, because many of them are not expressed by associations:
- return type of a method
- type of a variable:
     - Parameter
     - Local variable
     - Attribute
- exceptions caught, thrown
     - and declared exception
- parameter types in parameterized classes
- use of annotations
- other?

Since we now have a nice general API to query dependencies, it would be nicer if it were complete, ...

A possible solution would to rename queryAllOutgoingDependencies into queryAllOutgoingAssociations and change queryAllOutgoingDependencies to "do the right thing"

Or maybe invent new "virtual associations" (like ofType) and create queries for these associations, ...

nicolas

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




--
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: MooseChef & "hidden dependencies"

abergel
In reply to this post by Nicolas Anquetil
This is an excellent point!

Alexandre


On 30 Nov 2011, at 14:00, Nicolas Anquetil wrote:

>
> As all of us know, Famix recognizes 4 types of associations (reference, access, inheritance, invocation) and Moosechef was built upon these dependencies (queryAllOutgoingReferences, ...)
>
> For convenience, it adds queryAllOutgoingDependencies
> but this will miss a good deal of actual dependencies, because many of them are not expressed by associations:
> - return type of a method
> - type of a variable
> - exceptions caught, thrown
> - parameter types in parameterized classes
> - use of annotations
> - other?
>
> Since we now have a nice general API to query dependencies, it would be nicer if it were complete, ...
>
> A possible solution would to rename queryAllOutgoingDependencies into queryAllOutgoingAssociations and change queryAllOutgoingDependencies to "do the right thing"
>
> Or maybe invent new "virtual associations" (like ofType) and create queries for these associations, ...
>
> nicolas
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.





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

Re: MooseChef & "hidden dependencies"

Tudor Girba-2
In reply to this post by Andre Hora
Hi,

Good point.

On 30 Nov 2011, at 18:17, Andre Hora wrote:

> Just to complement the list:
>
> - return type of a method
> - type of a variable:
>      - Parameter
>      - Local variable
>      - Attribute
> - exceptions:
>    - caught
>    - thrown
>    - declared
> - parameter types in parameterized classes

To be more precise, we need to check the arguments in ParameterizedTypes. I now added FAMIXType>>argumentsInParameterizedTypes that will keep a back pointer to those arguments, so, we can query it directly.

> - use of annotations
> - other?


Is anyone willing to work on that?

> On Wed, Nov 30, 2011 at 6:00 PM, Nicolas Anquetil <[hidden email]> wrote:
>
> As all of us know, Famix recognizes 4 types of associations (reference, access, inheritance, invocation) and Moosechef was built upon these dependencies (queryAllOutgoingReferences, ...)
>
> For convenience, it adds queryAllOutgoingDependencies
> but this will miss a good deal of actual dependencies, because many of them are not expressed by associations:
> - return type of a method
> - type of a variable:
>      - Parameter
>      - Local variable
>      - Attribute
> - exceptions caught, thrown
>      - and declared exception
> - parameter types in parameterized classes
> - use of annotations
> - other?
>
> Since we now have a nice general API to query dependencies, it would be nicer if it were complete, ...
>
> A possible solution would to rename queryAllOutgoingDependencies into queryAllOutgoingAssociations and change queryAllOutgoingDependencies to "do the right thing"

I like queryAllOutgoingAssociations.

> Or maybe invent new "virtual associations" (like ofType) and create queries for these associations, ...

I do not understand this part. Could you explain in more details?

Cheers,
Doru


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

--
www.tudorgirba.com

"Every successful trip needs a suitable vehicle."





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

Re: MooseChef & "hidden dependencies"

Nicolas Anquetil


----- Mail original -----

> De: "Tudor Girba" <[hidden email]>
> À: "Moose-related development" <[hidden email]>
> Envoyé: Vendredi 2 Décembre 2011 08:25:04
> Objet: [Moose-dev] Re: MooseChef & "hidden dependencies"
> Hi,
>
> Good point.
>
> On 30 Nov 2011, at 18:17, Andre Hora wrote:
>
> > Just to complement the list:
> >
> > - return type of a method
> > - type of a variable:
> >      - Parameter
> >      - Local variable
> >      - Attribute
> > - exceptions:
> >    - caught
> >    - thrown
> >    - declared
> > - parameter types in parameterized classes
>
> To be more precise, we need to check the arguments in
> ParameterizedTypes. I now added
> FAMIXType>>argumentsInParameterizedTypes that will keep a back pointer
> to those arguments, so, we can query it directly.
>
> > - use of annotations
> > - other?
>
>
> Is anyone willing to work on that?

I would like.
the question is whether I can find some time to do it.


> > On Wed, Nov 30, 2011 at 6:00 PM, Nicolas Anquetil
> > <[hidden email]> wrote:
> >
> > As all of us know, Famix recognizes 4 types of associations
> > (reference, access, inheritance, invocation) and Moosechef was built
> > upon these dependencies (queryAllOutgoingReferences, ...)
> >
> > For convenience, it adds queryAllOutgoingDependencies
> > but this will miss a good deal of actual dependencies, because many
> > of them are not expressed by associations:
> > - return type of a method
> > - type of a variable:
> >      - Parameter
> >      - Local variable
> >      - Attribute
> > - exceptions caught, thrown
> >      - and declared exception
> > - parameter types in parameterized classes
> > - use of annotations
> > - other?
> >
> > Since we now have a nice general API to query dependencies, it would
> > be nicer if it were complete, ...
> >
> > A possible solution would to rename queryAllOutgoingDependencies
> > into queryAllOutgoingAssociations and change
> > queryAllOutgoingDependencies to "do the right thing"
>
> I like queryAllOutgoingAssociations.
>
> > Or maybe invent new "virtual associations" (like ofType) and create
> > queries for these associations, ...
>
> I do not understand this part. Could you explain in more details?

We decide that the relation between a variable and its type should be an association instead of a property,
But we don't want to change (break) the meta-model
So we say taht if that association existed it would be named "ofType", or "instance"
And we create a query in MooseChef that is called queryAllOutgoingInstances and we implement it so that it goes into variables to retrieve their type
And then we change queryAllOutgoingDependencies to also call this new query

Same goes for exceptions thown, annotations "used", ...

nicolas

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

Re: MooseChef & "hidden dependencies"

Andre Hora


On Fri, Dec 2, 2011 at 1:56 PM, Nicolas Anquetil <[hidden email]> wrote:


----- Mail original -----
> De: "Tudor Girba" <[hidden email]>
> À: "Moose-related development" <[hidden email]>
> Envoyé: Vendredi 2 Décembre 2011 08:25:04
> Objet: [Moose-dev] Re: MooseChef & "hidden dependencies"
> Hi,
>
> Good point.
>
> On 30 Nov 2011, at 18:17, Andre Hora wrote:
>
> > Just to complement the list:
> >
> > - return type of a method
> > - type of a variable:
> >      - Parameter
> >      - Local variable
> >      - Attribute
> > - exceptions:
> >    - caught
> >    - thrown
> >    - declared
> > - parameter types in parameterized classes
>
> To be more precise, we need to check the arguments in
> ParameterizedTypes. I now added
> FAMIXType>>argumentsInParameterizedTypes that will keep a back pointer
> to those arguments, so, we can query it directly.
Did you commit that?
>
> > - use of annotations
> > - other?
>
>
> Is anyone willing to work on that?

I would like.
the question is whether I can find some time to do it.


> > On Wed, Nov 30, 2011 at 6:00 PM, Nicolas Anquetil
> > <[hidden email]> wrote:
> >
> > As all of us know, Famix recognizes 4 types of associations
> > (reference, access, inheritance, invocation) and Moosechef was built
> > upon these dependencies (queryAllOutgoingReferences, ...)
> >
> > For convenience, it adds queryAllOutgoingDependencies
> > but this will miss a good deal of actual dependencies, because many
> > of them are not expressed by associations:
> > - return type of a method
> > - type of a variable:
> >      - Parameter
> >      - Local variable
> >      - Attribute
> > - exceptions caught, thrown
> >      - and declared exception
> > - parameter types in parameterized classes
> > - use of annotations
> > - other?
> >
> > Since we now have a nice general API to query dependencies, it would
> > be nicer if it were complete, ...
> >
> > A possible solution would to rename queryAllOutgoingDependencies
> > into queryAllOutgoingAssociations and change
> > queryAllOutgoingDependencies to "do the right thing"
>
> I like queryAllOutgoingAssociations.
>
> > Or maybe invent new "virtual associations" (like ofType) and create
> > queries for these associations, ...
>
> I do not understand this part. Could you explain in more details?

We decide that the relation between a variable and its type should be an association instead of a property,
But we don't want to change (break) the meta-model
So we say taht if that association existed it would be named "ofType", or "instance"
And we create a query in MooseChef that is called queryAllOutgoingInstances and we implement it so that it goes into variables to retrieve their type
And then we change queryAllOutgoingDependencies to also call this new query

Same goes for exceptions thown, annotations "used", ...

nicolas

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



--
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: MooseChef & "hidden dependencies"

Andre Hora


On Fri, Dec 2, 2011 at 5:08 PM, Andre Hora <[hidden email]> wrote:


On Fri, Dec 2, 2011 at 1:56 PM, Nicolas Anquetil <[hidden email]> wrote:


----- Mail original -----
> De: "Tudor Girba" <[hidden email]>
> À: "Moose-related development" <[hidden email]>
> Envoyé: Vendredi 2 Décembre 2011 08:25:04
> Objet: [Moose-dev] Re: MooseChef & "hidden dependencies"
> Hi,
>
> Good point.
>
> On 30 Nov 2011, at 18:17, Andre Hora wrote:
>
> > Just to complement the list:
> >
> > - return type of a method
> > - type of a variable:
> >      - Parameter
> >      - Local variable
> >      - Attribute
> > - exceptions:
> >    - caught
> >    - thrown
> >    - declared
> > - parameter types in parameterized classes
>
> To be more precise, we need to check the arguments in
> ParameterizedTypes. I now added
> FAMIXType>>argumentsInParameterizedTypes that will keep a back pointer
> to those arguments, so, we can query it directly.
Did you commit that?
OK, I found :)
>
> > - use of annotations
> > - other?
>
>
> Is anyone willing to work on that?

I would like.
the question is whether I can find some time to do it.


> > On Wed, Nov 30, 2011 at 6:00 PM, Nicolas Anquetil
> > <[hidden email]> wrote:
> >
> > As all of us know, Famix recognizes 4 types of associations
> > (reference, access, inheritance, invocation) and Moosechef was built
> > upon these dependencies (queryAllOutgoingReferences, ...)
> >
> > For convenience, it adds queryAllOutgoingDependencies
> > but this will miss a good deal of actual dependencies, because many
> > of them are not expressed by associations:
> > - return type of a method
> > - type of a variable:
> >      - Parameter
> >      - Local variable
> >      - Attribute
> > - exceptions caught, thrown
> >      - and declared exception
> > - parameter types in parameterized classes
> > - use of annotations
> > - other?
> >
> > Since we now have a nice general API to query dependencies, it would
> > be nicer if it were complete, ...
> >
> > A possible solution would to rename queryAllOutgoingDependencies
> > into queryAllOutgoingAssociations and change
> > queryAllOutgoingDependencies to "do the right thing"
>
> I like queryAllOutgoingAssociations.
>
> > Or maybe invent new "virtual associations" (like ofType) and create
> > queries for these associations, ...
>
> I do not understand this part. Could you explain in more details?

We decide that the relation between a variable and its type should be an association instead of a property,
But we don't want to change (break) the meta-model
So we say taht if that association existed it would be named "ofType", or "instance"
And we create a query in MooseChef that is called queryAllOutgoingInstances and we implement it so that it goes into variables to retrieve their type
And then we change queryAllOutgoingDependencies to also call this new query

Same goes for exceptions thown, annotations "used", ...

nicolas

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



--
Andre Hora




--
Andre Hora


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