Hi Alex,
I am currently working on a C importer based on srcML output. I created an extension of FAMIX3 (I am working with Pharo) since FAMIX3 did not express procedural languages. Essentially, 4 classes defines this extension:
- CAFunction subclass of FAMIXBehaviouralEntity
You should use the FAMIXFunction. I know that Simon removed it, but it should be there in the Core.
- CAInclue subclass of FAMIXAssociation
Cool.
- CAModule subclass of FAMIXScopingEntity
Hmm. Isn't a CAModule the same as FAMIXPackage?
- CAVariable subclass of FAMIXGlobalVariable
What is the difference between the two?
An instance of CAModule is intended to describe a C Module, instance being generated from a C file. I think this should be the right way to do. On the other hand, there are FAMIXFolder and FAMIXFile. Ideally, a C file should be seen as a file _and_ as a module. The class FAMIXFile contains useful methods, that I would like to use on a CAModule. But having one instance of CAModule and one instance of FAMIXFile per .c file is clearly suboptimal.
FAMIXFile and Folder denote structural things, and have no semantics. CAModule has semantics in a similar way a Package has. If you want to attach a file to it, just have the sourceAnchor point to the file.
My intuitions argues for creating a trait TFAMIXFile, that will be used by both FAMIXFile and CAModule. Any comment on this trait?
Cheers, Alexandre
Cheers, Doru
-- www.tudorgirba.com
"Problem solving efficiency grows with the abstractness level of problem understanding."