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

COVERAGE SUMMARY FOR SOURCE FILE [ComposedProvidingRequiringEntityItemSemanticEditPolicy.java]

nameclass, %method, %block, %line, %
ComposedProvidingRequiringEntityItemSemanticEditPolicy.java0%   (0/2)0%   (0/4)0%   (0/42)0%   (0/15)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class ComposedProvidingRequiringEntityItemSemanticEditPolicy0%   (0/1)0%   (0/3)0%   (0/32)0%   (0/11)
ComposedProvidingRequiringEntityItemSemanticEditPolicy (): void 0%   (0/1)0%   (0/4)0%   (0/3)
getCreateCommand (CreateElementRequest): Command 0%   (0/1)0%   (0/15)0%   (0/5)
getDuplicateCommand (DuplicateElementsRequest): Command 0%   (0/1)0%   (0/13)0%   (0/3)
     
class ComposedProvidingRequiringEntityItemSemanticEditPolicy$DuplicateAnythingCommand0%   (0/1)0%   (0/1)0%   (0/10)0%   (0/4)
ComposedProvidingRequiringEntityItemSemanticEditPolicy$DuplicateAnythingComma... 0%   (0/1)0%   (0/10)0%   (0/4)

1/*
2 *Copyright 2007, SDQ, IPD, Uni Karlsruhe (TH)
3 */
4package de.uka.ipd.sdq.pcm.gmf.composite.edit.policies;
5 
6import org.eclipse.emf.transaction.TransactionalEditingDomain;
7import org.eclipse.gef.commands.Command;
8import org.eclipse.gmf.runtime.diagram.ui.editparts.IGraphicalEditPart;
9import org.eclipse.gmf.runtime.emf.commands.core.commands.DuplicateEObjectsCommand;
10import org.eclipse.gmf.runtime.emf.type.core.requests.DuplicateElementsRequest;
11import de.uka.ipd.sdq.pcm.gmf.composite.edit.commands.ComposedProvidingRequiringEntityCreateCommand;
12 
13import de.uka.ipd.sdq.pcm.gmf.composite.providers.PalladioComponentModelElementTypes;
14 
15import org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest;
16 
17/**
18 * @generated
19 */
20public class ComposedProvidingRequiringEntityItemSemanticEditPolicy extends
21                PalladioComponentModelBaseItemSemanticEditPolicy {
22 
23        /**
24         * @generated
25         */
26        public ComposedProvidingRequiringEntityItemSemanticEditPolicy() {
27                super(
28                                PalladioComponentModelElementTypes.ComposedProvidingRequiringEntity_1000);
29        }
30 
31        /**
32         * @generated
33         */
34        protected Command getCreateCommand(CreateElementRequest req) {
35                if (PalladioComponentModelElementTypes.ComposedProvidingRequiringEntity_2002 == req
36                                .getElementType()) {
37                        return getGEFWrapper(new ComposedProvidingRequiringEntityCreateCommand(
38                                        req));
39                }
40                return super.getCreateCommand(req);
41        }
42 
43        /**
44         * @generated
45         */
46        protected Command getDuplicateCommand(DuplicateElementsRequest req) {
47                TransactionalEditingDomain editingDomain = ((IGraphicalEditPart) getHost())
48                                .getEditingDomain();
49                return getGEFWrapper(new DuplicateAnythingCommand(editingDomain, req));
50        }
51 
52        /**
53         * @generated
54         */
55        private static class DuplicateAnythingCommand extends
56                        DuplicateEObjectsCommand {
57 
58                /**
59                 * @generated
60                 */
61                public DuplicateAnythingCommand(
62                                TransactionalEditingDomain editingDomain,
63                                DuplicateElementsRequest req) {
64                        super(editingDomain, req.getLabel(), req
65                                        .getElementsToBeDuplicated(), req
66                                        .getAllDuplicatedElementsMap());
67                }
68        }
69}

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