1 | /* |
2 | *Copyright 2006 SDQ Research Group, University of Karlsruhe (TH) |
3 | */ |
4 | package de.uka.ipd.sdq.pcm.gmf.seff.edit.policies; |
5 | |
6 | import org.eclipse.gef.commands.Command; |
7 | import org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest; |
8 | |
9 | import de.uka.ipd.sdq.pcm.gmf.seff.edit.commands.GuardedBranchTransitionCreateCommand; |
10 | import de.uka.ipd.sdq.pcm.gmf.seff.edit.commands.ProbabilisticBranchTransitionCreateCommand; |
11 | import de.uka.ipd.sdq.pcm.gmf.seff.providers.PalladioComponentModelElementTypes; |
12 | |
13 | /** |
14 | * @generated |
15 | */ |
16 | public class BranchActionBranchTransitionCompartmentItemSemanticEditPolicy |
17 | extends PalladioComponentModelBaseItemSemanticEditPolicy { |
18 | |
19 | /** |
20 | * @generated |
21 | */ |
22 | public BranchActionBranchTransitionCompartmentItemSemanticEditPolicy() { |
23 | super(PalladioComponentModelElementTypes.BranchAction_3009); |
24 | } |
25 | |
26 | /** |
27 | * @generated |
28 | */ |
29 | protected Command getCreateCommand(CreateElementRequest req) { |
30 | if (PalladioComponentModelElementTypes.ProbabilisticBranchTransition_3010 == req |
31 | .getElementType()) { |
32 | return getGEFWrapper(new ProbabilisticBranchTransitionCreateCommand( |
33 | req)); |
34 | } |
35 | if (PalladioComponentModelElementTypes.GuardedBranchTransition_3017 == req |
36 | .getElementType()) { |
37 | return getGEFWrapper(new GuardedBranchTransitionCreateCommand(req)); |
38 | } |
39 | return super.getCreateCommand(req); |
40 | } |
41 | } |