EMMA Coverage Report (generated Sun Feb 05 10:43:15 CET 2012)
[all classes][de.uka.ipd.sdq.pcm.gmf.seff.edit.policies]

COVERAGE SUMMARY FOR SOURCE FILE [RecoveryActionBehaviourAlternativeBehaviourCompartmentCanonicalEditPolicy.java]

nameclass, %method, %block, %line, %
RecoveryActionBehaviourAlternativeBehaviourCompartmentCanonicalEditPolicy.java0%   (0/1)0%   (0/5)0%   (0/62)0%   (0/20)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class RecoveryActionBehaviourAlternativeBehaviourCompartmentCanonicalEditPolicy0%   (0/1)0%   (0/5)0%   (0/62)0%   (0/20)
RecoveryActionBehaviourAlternativeBehaviourCompartmentCanonicalEditPolicy ():... 0%   (0/1)0%   (0/3)0%   (0/1)
getDefaultFactoryHint (): String 0%   (0/1)0%   (0/2)0%   (0/1)
getFeaturesToSynchronize (): Set 0%   (0/1)0%   (0/17)0%   (0/5)
getSemanticChildrenList (): List 0%   (0/1)0%   (0/26)0%   (0/8)
isOrphaned (Collection, View): boolean 0%   (0/1)0%   (0/14)0%   (0/5)

1/*
2 * Copyright 2006 SDQ Research Group, University of Karlsruhe (TH)
3 */
4package de.uka.ipd.sdq.pcm.gmf.seff.edit.policies;
5 
6import java.util.Collection;
7import java.util.HashSet;
8import java.util.Iterator;
9import java.util.LinkedList;
10import java.util.List;
11import java.util.Set;
12 
13import org.eclipse.gmf.runtime.diagram.ui.editpolicies.CanonicalEditPolicy;
14import org.eclipse.gmf.runtime.notation.View;
15 
16import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.AcquireAction2EditPart;
17import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.BranchAction2EditPart;
18import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.CollectionIteratorAction2EditPart;
19import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.EmitEventAction2EditPart;
20import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.ExternalCallAction2EditPart;
21import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.ForkAction2EditPart;
22import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.InternalAction2EditPart;
23import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.LoopAction2EditPart;
24import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.RecoveryAction2EditPart;
25import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.ReleaseAction2EditPart;
26import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.SetVariableAction2EditPart;
27import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.StartAction2EditPart;
28import de.uka.ipd.sdq.pcm.gmf.seff.edit.parts.StopAction2EditPart;
29import de.uka.ipd.sdq.pcm.gmf.seff.part.PalladioComponentModelDiagramUpdater;
30import de.uka.ipd.sdq.pcm.gmf.seff.part.PalladioComponentModelNodeDescriptor;
31import de.uka.ipd.sdq.pcm.gmf.seff.part.PalladioComponentModelVisualIDRegistry;
32import de.uka.ipd.sdq.pcm.seff.SeffPackage;
33 
34/**
35 * @generated
36 */
37public class RecoveryActionBehaviourAlternativeBehaviourCompartmentCanonicalEditPolicy
38                extends CanonicalEditPolicy {
39 
40        /**
41         * @generated
42         */
43        Set myFeaturesToSynchronize;
44 
45        /**
46         * @generated
47         */
48        protected List getSemanticChildrenList() {
49                View viewObject = (View) getHost().getModel();
50                List result = new LinkedList();
51                for (Iterator it = PalladioComponentModelDiagramUpdater
52                                .getRecoveryActionBehaviourAlternativeBehaviourCompartment_7055SemanticChildren(
53                                                viewObject).iterator(); it.hasNext();) {
54                        result.add(((PalladioComponentModelNodeDescriptor) it.next())
55                                        .getModelElement());
56                }
57                return result;
58        }
59 
60        /**
61         * @generated
62         */
63        protected boolean isOrphaned(Collection semanticChildren, final View view) {
64                int visualID = PalladioComponentModelVisualIDRegistry.getVisualID(view);
65                switch (visualID) {
66                case StartAction2EditPart.VISUAL_ID:
67                case StopAction2EditPart.VISUAL_ID:
68                case LoopAction2EditPart.VISUAL_ID:
69                case InternalAction2EditPart.VISUAL_ID:
70                case BranchAction2EditPart.VISUAL_ID:
71                case ExternalCallAction2EditPart.VISUAL_ID:
72                case EmitEventAction2EditPart.VISUAL_ID:
73                case CollectionIteratorAction2EditPart.VISUAL_ID:
74                case AcquireAction2EditPart.VISUAL_ID:
75                case ReleaseAction2EditPart.VISUAL_ID:
76                case ForkAction2EditPart.VISUAL_ID:
77                case SetVariableAction2EditPart.VISUAL_ID:
78                case RecoveryAction2EditPart.VISUAL_ID:
79                        if (!semanticChildren.contains(view.getElement())) {
80                                return true;
81                        }
82                }
83                return false;
84        }
85 
86        /**
87         * @generated
88         */
89        protected String getDefaultFactoryHint() {
90                return null;
91        }
92 
93        /**
94         * @generated
95         */
96        protected Set getFeaturesToSynchronize() {
97                if (myFeaturesToSynchronize == null) {
98                        myFeaturesToSynchronize = new HashSet();
99                        myFeaturesToSynchronize.add(SeffPackage.eINSTANCE
100                                        .getResourceDemandingBehaviour_Steps_Behaviour());
101                }
102                return myFeaturesToSynchronize;
103        }
104 
105}

[all classes][de.uka.ipd.sdq.pcm.gmf.seff.edit.policies]
EMMA 2.0.9414 (unsupported private build) (C) Vladimir Roubtsov