Jump to: navigation, search

Difference between revisions of "GMF: Synchronized Container Use Cases"

(Definitions)
(Definitions)
Line 6: Line 6:
 
== Definitions ==
 
== Definitions ==
  
''synchronized diagram element'' – element visualized on diagram containing all the child diagram nodes recognized from the domain (semantic) model.
+
''synchronized element'' – diagram node or diagram itself always representing actual domain (semantic) model contents. i.e. all the child diagram nodes recognized from the underlying domain model.
  
''canonical container'' – synchronized diagram element.
+
''canonical container'' – synchronized element.
  
''non-synchronized diagram element'' – element visualized on diagram representing only selected child diagram nodes recognized from the domain (semantic) model.
+
''non-synchronized element'' – diagram node or diagram itself representing only selected child diagram nodes recognized from the domain model.
  
''synchronized diagram'' – diagram always representing all the diagram nodes recognized from the domain model element associated with diagram and all the sub-nodes recognized from the domain model.
+
''synchronized diagram'' – diagram itself, all the diagram nodes and sub-nodes are ''synchronized elements''
  
 
''element-based link'' – diagram link associated with the element in a domain model connecting link source with link target domain model elements.
 
''element-based link'' – diagram link associated with the element in a domain model connecting link source with link target domain model elements.

Revision as of 13:18, 12 April 2007

Preface

In the current state GMF supports two modes of diagram code generation - synchronized and non-synchronised. Toolsmith is able to switch between these two modes by changing GenDiagram.synchronized property. There were a number of discussions concerning diagram behavior in different situations according to the current mode. The idea of this document is to summarize existing requirements to simplify upcoming features development. Once this document will be finalized, corresponding changes should be introduced into the code generator and the runtime part if necessary.

This document will cover common use cases for different type of synchronized/non-synchronized diagrams from the end-user point of view and highlight corresponding places in code generator/runtime to be used to in corresponding conditions.

Definitions

synchronized element – diagram node or diagram itself always representing actual domain (semantic) model contents. i.e. all the child diagram nodes recognized from the underlying domain model.

canonical container – synchronized element.

non-synchronized element – diagram node or diagram itself representing only selected child diagram nodes recognized from the domain model.

synchronized diagram – diagram itself, all the diagram nodes and sub-nodes are synchronized elements

element-based link – diagram link associated with the element in a domain model connecting link source with link target domain model elements.

reference-only link – diagram link representing reference in a domain model. This reference contained in a link source domain model element and pointing to the link target domain model element.

CanonicalEditPolicy - abstract class in GMF runtime implementing EditPolicy and encapsulating set of functionality useful for synchronizing diagram element contents with the domain model element contents.

CanonicalConnectionEditPolicy – abstract subclass of CanonicalEditPolicy supporting outgoing element-based diagram links synchronization.

Synchronized containers

Synchronized links

Non-Synchronized elements

Useing code generator to generate element synchronization

GenDiagram.synchronized property

Switching On/Off Synchronization

HREFs