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

COVERAGE SUMMARY FOR SOURCE FILE [ParametricResourceDemandItemProvider.java]

nameclass, %method, %block, %line, %
ParametricResourceDemandItemProvider.java0%   (0/1)0%   (0/10)0%   (0/114)0%   (0/40)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class ParametricResourceDemandItemProvider0%   (0/1)0%   (0/10)0%   (0/114)0%   (0/40)
ParametricResourceDemandItemProvider (AdapterFactory): void 0%   (0/1)0%   (0/4)0%   (0/2)
addRequiredResource_ParametricResourceDemandPropertyDescriptor (Object): void 0%   (0/1)0%   (0/28)0%   (0/14)
collectNewChildDescriptors (Collection, Object): void 0%   (0/1)0%   (0/13)0%   (0/6)
getChildFeature (Object, Object): EStructuralFeature 0%   (0/1)0%   (0/5)0%   (0/1)
getChildrenFeatures (Object): Collection 0%   (0/1)0%   (0/15)0%   (0/4)
getImage (Object): Object 0%   (0/1)0%   (0/8)0%   (0/1)
getPropertyDescriptors (Object): List 0%   (0/1)0%   (0/13)0%   (0/4)
getResourceLocator (): ResourceLocator 0%   (0/1)0%   (0/2)0%   (0/1)
getText (Object): String 0%   (0/1)0%   (0/4)0%   (0/1)
notifyChanged (Notification): void 0%   (0/1)0%   (0/22)0%   (0/6)

1/**
2 * Copyright 2005-2009 by SDQ, IPD, University of Karlsruhe, Germany
3 *
4 * $Id$
5 */
6package de.uka.ipd.sdq.pcm.seff.seff_performance.provider;
7 
8 
9import java.util.Collection;
10import java.util.List;
11 
12import org.eclipse.emf.common.notify.AdapterFactory;
13import org.eclipse.emf.common.notify.Notification;
14import org.eclipse.emf.common.util.ResourceLocator;
15import org.eclipse.emf.ecore.EStructuralFeature;
16import org.eclipse.emf.edit.provider.ComposeableAdapterFactory;
17import org.eclipse.emf.edit.provider.IEditingDomainItemProvider;
18import org.eclipse.emf.edit.provider.IItemLabelProvider;
19import org.eclipse.emf.edit.provider.IItemPropertyDescriptor;
20import org.eclipse.emf.edit.provider.IItemPropertySource;
21import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
22import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
23import org.eclipse.emf.edit.provider.ItemProviderAdapter;
24import org.eclipse.emf.edit.provider.ViewerNotification;
25 
26import de.uka.ipd.sdq.pcm.core.CoreFactory;
27import de.uka.ipd.sdq.pcm.core.provider.PalladioComponentModelEditPlugin;
28import de.uka.ipd.sdq.pcm.seff.seff_performance.ParametricResourceDemand;
29import de.uka.ipd.sdq.pcm.seff.seff_performance.Seff_performancePackage;
30 
31/**
32 * This is the item provider adapter for a {@link de.uka.ipd.sdq.pcm.seff.seff_performance.ParametricResourceDemand} object.
33 * <!-- begin-user-doc -->
34 * <!-- end-user-doc -->
35 * @generated
36 */
37public class ParametricResourceDemandItemProvider
38        extends ItemProviderAdapter
39        implements
40                IEditingDomainItemProvider,
41                IStructuredItemContentProvider,
42                ITreeItemContentProvider,
43                IItemLabelProvider,
44                IItemPropertySource {
45        /**
46         * <!-- begin-user-doc -->
47         * <!-- end-user-doc -->
48         * @generated
49         */
50        public static final String copyright = "Copyright 2005-2009 by SDQ, IPD, University of Karlsruhe, Germany";
51 
52        /**
53         * This constructs an instance from a factory and a notifier.
54         * <!-- begin-user-doc -->
55         * <!-- end-user-doc -->
56         * @generated
57         */
58        public ParametricResourceDemandItemProvider(AdapterFactory adapterFactory) {
59                super(adapterFactory);
60        }
61 
62        /**
63         * This returns the property descriptors for the adapted class.
64         * <!-- begin-user-doc -->
65         * <!-- end-user-doc -->
66         * @generated
67         */
68        @Override
69        public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) {
70                if (itemPropertyDescriptors == null) {
71                        super.getPropertyDescriptors(object);
72 
73                        addRequiredResource_ParametricResourceDemandPropertyDescriptor(object);
74                }
75                return itemPropertyDescriptors;
76        }
77 
78        /**
79         * This adds a property descriptor for the Required Resource Parametric Resource Demand feature.
80         * <!-- begin-user-doc -->
81         * <!-- end-user-doc -->
82         * @generated
83         */
84        protected void addRequiredResource_ParametricResourceDemandPropertyDescriptor(Object object) {
85                itemPropertyDescriptors.add
86                        (createItemPropertyDescriptor
87                                (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
88                                 getResourceLocator(),
89                                 getString("_UI_ParametricResourceDemand_requiredResource_ParametricResourceDemand_feature"),
90                                 getString("_UI_PropertyDescriptor_description", "_UI_ParametricResourceDemand_requiredResource_ParametricResourceDemand_feature", "_UI_ParametricResourceDemand_type"),
91                                 Seff_performancePackage.Literals.PARAMETRIC_RESOURCE_DEMAND__REQUIRED_RESOURCE_PARAMETRIC_RESOURCE_DEMAND,
92                                 true,
93                                 false,
94                                 true,
95                                 null,
96                                 null,
97                                 null));
98        }
99 
100        /**
101         * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
102         * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
103         * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
104         * <!-- begin-user-doc -->
105         * <!-- end-user-doc -->
106         * @generated
107         */
108        @Override
109        public Collection<? extends EStructuralFeature> getChildrenFeatures(Object object) {
110                if (childrenFeatures == null) {
111                        super.getChildrenFeatures(object);
112                        childrenFeatures.add(Seff_performancePackage.Literals.PARAMETRIC_RESOURCE_DEMAND__SPECIFICATION_PARAMETERIC_RESOURCE_DEMAND);
113                }
114                return childrenFeatures;
115        }
116 
117        /**
118         * <!-- begin-user-doc -->
119         * <!-- end-user-doc -->
120         * @generated
121         */
122        @Override
123        protected EStructuralFeature getChildFeature(Object object, Object child) {
124                // Check the type of the specified child object and return the proper feature to use for
125                // adding (see {@link AddCommand}) it as a child.
126 
127                return super.getChildFeature(object, child);
128        }
129 
130        /**
131         * This returns ParametricResourceDemand.gif.
132         * <!-- begin-user-doc -->
133         * <!-- end-user-doc -->
134         * @generated
135         */
136        @Override
137        public Object getImage(Object object) {
138                return overlayImage(object, getResourceLocator().getImage("full/obj16/ParametricResourceDemand"));
139        }
140 
141        /**
142         * This returns the label text for the adapted class.
143         * <!-- begin-user-doc -->
144         * <!-- end-user-doc -->
145         * @generated
146         */
147        @Override
148        public String getText(Object object) {
149                return getString("_UI_ParametricResourceDemand_type");
150        }
151 
152        /**
153         * This handles model notifications by calling {@link #updateChildren} to update any cached
154         * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
155         * <!-- begin-user-doc -->
156         * <!-- end-user-doc -->
157         * @generated
158         */
159        @Override
160        public void notifyChanged(Notification notification) {
161                updateChildren(notification);
162 
163                switch (notification.getFeatureID(ParametricResourceDemand.class)) {
164                        case Seff_performancePackage.PARAMETRIC_RESOURCE_DEMAND__SPECIFICATION_PARAMETERIC_RESOURCE_DEMAND:
165                                fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
166                                return;
167                }
168                super.notifyChanged(notification);
169        }
170 
171        /**
172         * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
173         * that can be created under this object.
174         * <!-- begin-user-doc -->
175         * <!-- end-user-doc -->
176         * @generated
177         */
178        @Override
179        protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) {
180                super.collectNewChildDescriptors(newChildDescriptors, object);
181 
182                newChildDescriptors.add
183                        (createChildParameter
184                                (Seff_performancePackage.Literals.PARAMETRIC_RESOURCE_DEMAND__SPECIFICATION_PARAMETERIC_RESOURCE_DEMAND,
185                                 CoreFactory.eINSTANCE.createPCMRandomVariable()));
186        }
187 
188        /**
189         * Return the resource locator for this item provider's resources.
190         * <!-- begin-user-doc -->
191         * <!-- end-user-doc -->
192         * @generated
193         */
194        @Override
195        public ResourceLocator getResourceLocator() {
196                return PalladioComponentModelEditPlugin.INSTANCE;
197        }
198 
199}

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