Papyrus Extension – Array-OL Refactoring

Papyrus Extension – Array-OL Refactoring
-
Requirements:
o Papyrus UML Editor http://www.papyrusuml.org/
o Papyrus Marte Extension http://www.papyrusuml.org/
o Archive with refactoring plug-in (fr.lifl.west.gaspard2.papyrusextension.refactoring_x.x.x.zip)
http://gforge.inria.fr/frs/?group_id=768
-
Installation:
o Unzip the archive into papyrus directory (jar file in plugins directory of Papyrus
)
-
Test installation:
o The plug-in (fr.lifl.west.gaspard2.papyrusextension.refactoring) should appear in plug-ins list (HelpAbout … - Plug-in Details
-
Utilization:
o the transformations are added to the context menu of the diagram editor (right click – Gaspard2
Refactoring - …
o the transformations will take as input the selected elements from the diagram
o in function of the selected elements, transformations will be active or not
o Important: transformations work on parts, so just parts must be selected
-
Observations:
o A Repetitive Component is a component that contains just one part, stereotyped with Shaped; it
should contain just connectors stereotyped with Tiler for now
o A Repetitive Part is a part that has as type a Repetitive Component
o A Compound Component is a component that contains just parts NOT stereotyped with Shaped; it
should contain just connectors not stereotyped for now
o IMPORTANT:
ƒ
The transformations need as input correct data
ƒ
The Tilers and Shapes must be correct and consistent through the application
ƒ
For a Tiler:
•
The origin size, paving vectors size and fitting vectors size must be the same as the
array size
•
The number of paving vectors must be the same as the repetition size
•
The number of fitting vectors must be the same as the pattern size
ƒ
If errors are found when parsing the selected elements, the transformations will not be
activated
ƒ
Such eventual errors are displayed in the console (for now)
-
Examples available to download - http://gforge.inria.fr/frs/?group_id=768 :
o STAP application
ƒ
stap.di2
o Downscaler with an additional output (from the horizontal filter)
ƒ
downscaler_aux.di2
o Downscaler with additional details (each filter is a repetition of an elementary average computation)
ƒ
downscaler_details.di2
1
-
Fusion:
o Takes as input two or more connected repetitive parts of the same component;
o A fusion order is computed depending on the connections between parts
o A series of fusion (just two parts)+collapse transformations are applied in order to fusion all the
parts
o Initial components are not modified, new ones are generated
o New repetitive components are drawn in a new diagram
o New compound component containing the inferior level of the hierarchy after the fusion is drawn in
separate diagram
o Initial parts are replaced with a single part (the superior level of hierarchy after the fusion)
Fig.1: Fusion of four parts for stap example
Fig.2: Generated compound component for the stap example (after the fusion from Fig.1)
2
Fig.3: Diagram with the generated repetitive components for the stap example (after the fusion from Fig.1)
Fig.4: Fusion part for the stap example (after the fusion from Fig.1)
3
-
Change Paving:
o Needs as input a single repetitive part that represents the superior level of a two-level hierarchy of
repetitions. The type of the part must be a repetitive component that contains:
ƒ
Either another repetitive component
ƒ
Either a compound component that contains just repetitive parts
o In the transformation input dialog the user will select the repetitions that will be passed from the
superior level to the second
o For now, no new components are generated, changes are done to the initial elements
Fig.5: Change paving (by adding dimensions) for the Downscaler example (on the
fusion part resulted after the fusion of the two filters)
-
Linear Growth:
o Similar to change paving but takes as input a two-level hierarchy of repetitions where on the
second level there are just two repetitions and they have a structure “post-fusion” (the tilers have
an identity form)
o The possible linear growth transformations are displayed in the dialog box for the user to choose,
together with de level of the transformation
-
Tilling:
o Takes a repetition part as input and generates a level of repetitive hierarchy
o Some of the repetitions (chosen by the user through the dialog box) are passed to the newly
created level of repetition
-
Collapse:
o Is the inverse of fusion an tilling
o Takes as input a two-level hierarchy of repetitions (exactly the same as change paving)
o Eliminates the superior level of hierarchy by passing its repetition to all the repetitions of the
second level and climbing them a hierarchy level
4
-
THIS IS JUST A BETA VERSION OF THE REFACTORING PLUGIN FOR PAPYRUS!!!
o Remains TO DO:
ƒ
UNDO/REDO actions
ƒ
Connect the transformations to the outline tree for eventual models that have no graphic
representation (no graphic elements will be generated in this case)
ƒ
Improve the user interface (input dialogs and error display)
ƒ
Allow the user to choose if new components will be generated or not
ƒ
Correct eventual bugs
ƒ
Extend transformations to manage Reshapes, Inter-repetition dependences,
Default Links
o Please send bugs to : [email protected]
5