Rich Reference Figures

Description

The RichReferenceFigure is used to render an EObject the same way as a reference (in other words with an ReferenceFigure).

It is helpful when your model contains Association classes. In other words, it is helpful when you want to represent a relation between two EObjects that goes through an intermediate EObject without representing that intermediate EObject as a complete node.

A RichReferenceFigure also allows to attach up to three labels on the edge (at the start, in the middle and at the end). The labels are configured through an OCL expression (in order to be flexible enough to meet your own needs).

Illustration

For example, with the school sample, it is possible to represent the Students directly in the Classroom nodes (see the right diagram) instead of representing them fully as nodes (as on the left diagram) :

Label Positions

The RichReferenceFigures accepts up to 3 labels which can be put :


(Click to enlarge)

The source and target label positions can be adjusted thanks to the Label Angle and the Distance from source/target label to the edge-node connection properties.

Here is an illustration showing how to use the Label Angle property ;


(Click to enlarge)

Here are three samples with three values (0, 4, 8) for the Label Distance property :


(Label Distance = 0 ; Click to enlarge)
(Label Distance = 4 ; Click to enlarge)
(Label Distance = 8 ; Click to enlarge)

Properties

The RichReferenceFigure accepts the following properties :

CategoryNameDescriptionDefault literal
Appearance colorThe edge color#000000
customSourceArrowThe custom source arrow (graphviz compliant arrow style, ignored if sourceArrowType is not set to 'custom') 
customTargetArrowThe custom target arrow (graphviz compliant arrow style, ignored if targetArrowType is not set to 'custom') 
labelAngleThis, along with labeldistance, determine where the headlabel (taillabel) are placed with respect to the head (tail) in polar coordinates. The origin in the coordinate system is the point where the edge touches the node. The ray of 0 degrees goes from the origin back along the edge, parallel to the edge at the origin. (same as Graphviz labelangle property)0
labelDistanceMultiplicative scaling factor adjusting the distance that the headlabel(taillabel) is from the head(tail) node (same as Graphviz labeldistance property)5.0
minimumEdgeLengthMinimum edge length (same as Graphviz minlen property)1
sourceArrowTypeThe source arrow typenone
sourceLabelExpressionThe OCL expression to use to build the source label of the edge 
sourceLabelStyleThe style of the source label 
standardLabelExpressionThe OCL expression to use to build the standard (centered) label of the edge 
standardLabelStyleThe style of the standard (centered) label 
styleThe edge stylenormal
targetArrowTypeThe target arrow typenormal
targetLabelExpressionThe OCL expression to use to build the target label of the edge 
targetLabelStyleThe style of the target label 
Model eReferenceThe EReference that this figure will represent on the graph 
targetEReferenceThe target EReference of the rich reference EClass