Difference between pages "D32 UML-B" and "Rodin Editor"

From Event-B
(Difference between pages)
Jump to navigationJump to search
imported>Colin
 
imported>Tommy
 
Line 1: Line 1:
= Overview =
+
{{TOCright}}
Progress on UML-B falls into three parallel developments.
+
Return to [[Rodin Plug-ins]]
# Enhancement and maintenance of the current and existing UML-B plug-in with new functionality and usability features.
 
# Development of a new plug-in to provide animation of UML-B state-machine diagrams.
 
# Development of a new plug-in (called iUML-B) that provides an alternative to UML-B which is more closely integrated with Event-B.
 
  
== Enhancement and Maintenance of Existing UML-B ==
+
[[Image:RodinEditor_basicView1.png|400px|left|a basic view of the Rodin Editor on a context]]
  
:The main progress on UML-B has been to implement new features, improve usability and fix bugs. As in the previous years of DEPLOY, these bugs and features are reported either by email or through dedicated SourceForge trackers. The list below gives an overwiew of the noteworthy features added in UML-B during the past year:
+
The Rodin Editor is an editor, based on the same principles as the historical structured Event-B Editor. This latter editor shown its weakness while editing large models. Moreover, it was impossible to show some information, which are needed when one edits an Event-B model (such as the inherited elements which were formerly displayed only in the pretty print view). This is to solve all these issues that the Rodin Editor was created.
  
:# Functional enhancements to modelling
+
This editor aims to be clean, in order to read easily models, but new comers may find it less easy to use. Please read the '''Principles''' section to get the necessary background to understand how this editor works. Furthermore, the text base of this editor aims to bring with it all the navigation and edition ease provided by text editor.
:#* State-machine transitions emanating from multiple states. It is often the case that a transition may occur from several (possibly all) states within a state-machine. Such models were impossible to represent in UML-B. Two pseudo-states were added to represent this. Firstly an 'ANY' pseudo-state can be used as a transition source to represent that the transition can occur from ANY state of the state-machine. Secondly a disjunctive pseudo-state can be used to combine several transitions from different source states into a single transition.
+
<br style="clear: both" />
:#* Conceptual Singleton classes - provides a conceptual grouping of associated modelling elements without generating the lifting mechanisms of a class.
 
:#* Super-type arrows to target ExtendedClassTypes and RefinedClasses - this functionality was missing in previous versions.
 
:#* Event convergence property on state-machine transitions - convergence was previously available only on events
 
:# Enhancements to improve usability
 
:#* Report to user if translation didn't proceed due to model validator - previously, it was not clear when the model had failed validation and the translation had not been executed.
 
:#* Improve refresh of diagrams - in some situations the diagram graphics did not update error marking and properties changes unless some other event caused a refresh.
 
:#* Improvements and additions to model validations - some model validations were inconsistent or incomplete.
 
:#* Preference for line routing style for each diagram type - allows the user to choose whether to use rectilinear or oblique line routing for each diagram type.
 
:# Corrections
 
:#* Correct and improve missing default labelling in diagrams.
 
:#* Corrections and improvements to automatic diagram deletion.
 
:#* Improved management of diagram files when model changes.
 
:#* Add missing comment fields in properties view.
 
  
== UML-B State-machine Animation Plug-in==
+
=== Current version ===
:The UML-B State-machine Animation Plug-in is a new feature developed by University of Southampton as a response to a request from industrial partners to support the animation of UML-B state-machine diagrams. The essence of the request was to provide a means of visualising the animation and model-checking process of Event-B machines modelled in UML-B tool, in particular state-machines, thus to simplify this process. The tool integrates the capabilities of ProB animation and UML-B State-machine notation.
+
The current version is 0.5.0 released on Wednesday 13 July 2011.<br>
 +
''<span style="color:#FF4500">IMPORTANT :  we identified a source of concurrency in the current version (0.5.0) of the plug-in.</span>''<br>
 +
<span style="color:#FF4500">'''To avoid any trouble, please do not generate files while having some Rodin Editor open, and edit only one model per project at once.'''</span>
  
== iUML-B - Integrated UML-B ==
+
=== Principles ===
: The prototype iUML-B plug-in (not yet released) is an extension to the Event-B EMF framework. It will consist of a collection of independent plug-ins that provides support for diagrammatic modelling integrated with Event-B textual modelling. At this stage a plug-in to show the project structure (in terms of machines and contexts and their relationships has been released. A plug-in to support state-machine diagrams integrated with textual Event-B is at a prototype stage and nearing release. Plug-ins to support other kinds of diagram are in the early stages of development.
+
'''The component contents are displayed as text.''' Once you component opened with the Rodin Editor, its contents are printed as text inside the Rodin Editor. However, as said, the Rodin Editor is not a text editor, and even if the component you edit is streamlined to basic text, what you edit is stored in an underlying database. That's the reason why you can not type text at any place at any moment. (i.e. there is no parsing of text file: what you see is a text component based form editor).
  
= Motivations =
+
'''There are two types of edition possible.''' Because Rodin manipulates Event-B elements and their attributes, the Rodin Editor provides two ways to modify Event-B models:
 +
* you can navigate through the model contents and do things on the Event-B elements (e.g. add/remove/move/etc.) with the right-click actions or the keyboard shortcuts, depending on where is your cursor, or what you selected,
 +
* you can edit the Event-B element's attributes by entering the "edition" mode provided by the overlay editor. This is detailed here-after.
  
== Enhancements to state diagram drawing ==
+
'''An overlay editor displays over the text to edit element's attributes''' The basic idea is: ''"when I want to edit some contents, I should open the overlay editor that will allow me to modify its value"''.
Several case studies were involving state machine diagrams which were problematic because particular transitions could be enabled from any sub-state. there was no way to represent these cases in UML-B.  
 
  
== Animation Plug-in ==
+
'''Everything happens where I click, or where my text caret is.''' The caret position, also set when the user left-clicks in the editor, is the base for component modifications:
The motivation for the Animation Plug-in was to extend already beneficial graphical notation of UML-B with animation capabilities similar to those that ProB tool provides for Event-B models. With the aid of such a plug-in animation and model checking would be possible on UML-B diagrams instead of translated and less obvious Event-B code. The resulting plug-in uses ProB tool to run the standard animation on translated models and animates UML-B state-machines at the same time.
+
* if you click an editable attribute, the overlay editor opens on it and you are able to modify the attribute. The same action is possible if you press "Backspace" if the caret is on an editable attribute,
 +
* if you click on non editable places of the editor, you just move the text caret to the pointed position.  
  
= Choices / Decisions =
+
=== A basic overview ===
== Integrated UML-B ==
+
The Rodin Editor might not be the 'preferred' editor that Rodin uses to open your Event-B models.<br>
: It was planned to develop a new version (iUML-B) of UML-B which is more integrated with Event-B. A precursor stage to this was to develop an EMF representation of Event-B. This was completed last year and is now used successfully by several plug-ins. A Records plug-in was developed in response to user requests. The Records plug-in was implemented as an extension to the Event-B EMF framework. This was seen as a 'practice run' before attempting a similar extension to support UML-B. However, the Records plug-in took longer than expected and this has delayed work on iUML-B. Some progress on iUML-B has recently been made with the release of a project level diagram tool for Event-B and some progress on representing State-Machine diagram models as an extension to the Event-B EMF models.
+
Thus, to open a component (e.g. a machine, a context, etc.), '''right-click''' on it and select '''Open with''' > '''Rodin Editor'''.<br>
 +
The context component is then opened with the Rodin Editor.<br>
  
== State-machine Animation Plug-in ==
+
[[Image:RodinEditor_basicView2.png|600px]]
: The initial design decision was to extend the UML-B metamodel with the animation components. Due to difficulties with UML-B diagram extensibility an alternative option was determined to create a separate model, derived from UML-B state-machine subset, with incorporated animation support. This design was successfully implemented together with ProB and Rodin UI extensions into Animation plug-in, which supports such UML-B concepts as classes and different state-machine translation kinds, as well as Event-B refinement.
 
  
= Available Documentation =
+
On the figure above, you see the context component.<br>
The following pages give useful information about UML-B:
+
* The user is editing the axiom ''axm8'' and we see that the text is black and the background is grayed. This is the actually the overlay editor, that is open to edit the predicate contained by the axiom ''axm8''.
* Lectures<ref name="UML-B">http://wiki.event-b.org/index.php/UML-B</ref>.
+
* There are buttons in the left ruler to fold some elements.
* Tutorials<ref name="UML-B">http://wiki.event-b.org/index.php/UML-B</ref>.
+
* The comments are preceeded by the character ' › ' to indicate where to click for edition.
* Worked Examples<ref name="UML-B">http://wiki.event-b.org/index.php/UML-B</ref>.
+
* The other attributes are inlined as grayed text.
 +
** Note that : some attributes have type boolean, thus change value on click, and some attributes are choice attributes thus display a list of clickable values (see the image below) on click.
  
UML-B State-machine Animation Plug-in:
+
[[Image:RodinEditor_basicView3.png]]
* General information<ref>http://wiki.event-b.org/index.php/UML-B_-_Statemachine_Animation</ref>
 
* Tutorial<ref>http://wiki.event-b.org/index.php/Statemachine_Animation_Tutorial</ref>
 
  
= Planning =
+
[[Category:Plugin]]
During the coming year, special efforts will be made on the following topics,
+
[[Category:User documentation]]
* Development of the Project Diagram Plugin for Event-B to make it extensible and/or to automatically cater for future component types.
 
: The current version of the Project Diagram Plugin only supports Machines and Contexts and their relationships. Already, several plug-ins are contributing new kinds of components such as theories, tasking machines and compositions. The Project Diagram plug-in will be enhanced to provide an extension mechanism that allow other plug-ins to extend the project diagram to show new kinds of components and their relationship.
 
* Development of a State-machine diagram plug-in as an integrated part of Event-B modelling
 
: The State-machine diagram plug-in will provide a diagrammatic modelling environment based on state-machines alongside the usual Event-B modelling format. The two views will contribute to the same model simultaneously.
 
 
 
In parallel with these new plug-ins, the current version of UML-B will continue to be enhanced. This may include some new modelling features such as better support for synchronisation of state-machines and support for more UML modelling details. However, usability of the current features is seen as the main objective. This will include,
 
* Support for copy, cut and paste of diagram elements so that they can be moved and/or replicated more easily,
 
* Support for re-attaching links (e.g. transitions) to different source/target elements,
 
* Facilities for refactoring/renaming elements,
 
* Support for the event extension mechanism of Event-B,
 
* Integration of Context Diagram model elements on Class diagrams,
 
* Improve facilities for navigating between state-machines and visualising multiple state-machines.
 
 
 
== References ==
 
<references/>
 
 
 
[[Category:D32 Deliverable]]
 

Revision as of 15:16, 12 July 2011

Return to Rodin Plug-ins

a basic view of the Rodin Editor on a context

The Rodin Editor is an editor, based on the same principles as the historical structured Event-B Editor. This latter editor shown its weakness while editing large models. Moreover, it was impossible to show some information, which are needed when one edits an Event-B model (such as the inherited elements which were formerly displayed only in the pretty print view). This is to solve all these issues that the Rodin Editor was created.

This editor aims to be clean, in order to read easily models, but new comers may find it less easy to use. Please read the Principles section to get the necessary background to understand how this editor works. Furthermore, the text base of this editor aims to bring with it all the navigation and edition ease provided by text editor.

Current version

The current version is 0.5.0 released on Wednesday 13 July 2011.
IMPORTANT : we identified a source of concurrency in the current version (0.5.0) of the plug-in.
To avoid any trouble, please do not generate files while having some Rodin Editor open, and edit only one model per project at once.

Principles

The component contents are displayed as text. Once you component opened with the Rodin Editor, its contents are printed as text inside the Rodin Editor. However, as said, the Rodin Editor is not a text editor, and even if the component you edit is streamlined to basic text, what you edit is stored in an underlying database. That's the reason why you can not type text at any place at any moment. (i.e. there is no parsing of text file: what you see is a text component based form editor).

There are two types of edition possible. Because Rodin manipulates Event-B elements and their attributes, the Rodin Editor provides two ways to modify Event-B models:

  • you can navigate through the model contents and do things on the Event-B elements (e.g. add/remove/move/etc.) with the right-click actions or the keyboard shortcuts, depending on where is your cursor, or what you selected,
  • you can edit the Event-B element's attributes by entering the "edition" mode provided by the overlay editor. This is detailed here-after.

An overlay editor displays over the text to edit element's attributes The basic idea is: "when I want to edit some contents, I should open the overlay editor that will allow me to modify its value".

Everything happens where I click, or where my text caret is. The caret position, also set when the user left-clicks in the editor, is the base for component modifications:

  • if you click an editable attribute, the overlay editor opens on it and you are able to modify the attribute. The same action is possible if you press "Backspace" if the caret is on an editable attribute,
  • if you click on non editable places of the editor, you just move the text caret to the pointed position.

A basic overview

The Rodin Editor might not be the 'preferred' editor that Rodin uses to open your Event-B models.
Thus, to open a component (e.g. a machine, a context, etc.), right-click on it and select Open with > Rodin Editor.
The context component is then opened with the Rodin Editor.

RodinEditor basicView2.png

On the figure above, you see the context component.

  • The user is editing the axiom axm8 and we see that the text is black and the background is grayed. This is the actually the overlay editor, that is open to edit the predicate contained by the axiom axm8.
  • There are buttons in the left ruler to fold some elements.
  • The comments are preceeded by the character ' › ' to indicate where to click for edition.
  • The other attributes are inlined as grayed text.
    • Note that : some attributes have type boolean, thus change value on click, and some attributes are choice attributes thus display a list of clickable values (see the image below) on click.

RodinEditor basicView3.png