I have a question: you parse the Java class until the method level,
but
you do not parse what is inside the methods (method body), don't you?
What do you mean that I do not parse inside the methods ?
I extract dependencies between classes, even contained in methods
bodies. Do you need more?
Here a summary of a dependency test
-=-=-=-=-=-=-=-=-=-=-=-=
Java4MOOSETest>>testDependencies2:
factoryClass := (importer model allClasses select: [:c| c name =
#PointFactory]) first.
pointClass := (importer model allClasses select: [:c| c name =
#Point]) first.
...
createMethod := (factoryClass allMethods select: [:m| m name ==
#createPoint]) first .
...
famixAccess := createMethod accesses first.
self assert: (famixAccess accesses == pointClass).
self assert: (famixAccess accessedIn == createMethod).
-=-=-=-=-=-=-=-=-=-=-=-=
And the class Factory is defined as follows:
-=-=-=-=-=-=-=-=-=-=-=-=
package mypackage.p;
class PointFactory { public void createPoint () { new Point();}}
-=-=-=-=-=-=-=-=-=-=-=-=
Cheers,
Alexandre
> ---------- Forwarded message ----------
> Date: Mon, 24 Mar 2008 17:23:30 -0400
> From: "Bergel, Alexandre" <bergel(a)iam.unibe.ch>
> Reply-To: Related to the development of Moose and other related tools
> <moose-dev(a)iam.unibe.ch>
> To: Related to the development of Moose and other related tools
> <moose-dev(a)iam.unibe.ch>
> Subject: [Moose-dev] Re: Importing JAva files into Moose
>
> Hola Gabriela!
>
> I recently worked on a Java importer for Moose. It works (for what I
> need it for :-)
> Look at the package JavaSupport4MOOSE on Store@SCG.
> You will have a new entry in the import button in the moose facade...
>
> Let me know, I provide free support :-)
> It does not import everything, but you should be able to have class
> inheritance and dependencies between classes. If you need other
> stuff, I can spend some time on this...
>
> Alexandre
>
>
> On 24 Mar 2008, at 17:16, Gabriela Arevalo wrote:
>
>> Hi guys,
>>
>> How do I import the Java Files into Moose?
>> I tried J2Moose, but the only info I get in the .mse file is the
>> following:
>>
>> (Moose.Model (entity
>>
>> ))
>>
>> I installed the J2Moose plugin into Eclipse and when I execute the
>> J2Moose>J2Moose, I do not get any information.
>>
>> CHeers,
>>
>> gabi
>> _______________________________________________
>> Moose-dev mailing list
>> Moose-dev(a)iam.unibe.ch
>>
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel
http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.