geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sppa...@apache.org
Subject svn commit: r366818 - /geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/
Date Sat, 07 Jan 2006 16:26:30 GMT
Author: sppatel
Date: Sat Jan  7 08:26:22 2006
New Revision: 366818

URL: http://svn.apache.org/viewcvs?rev=366818&view=rev
Log:
add/update providers

Added:
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/GbeanRefTypeItemProvider.java   (with props)
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ServiceRefTypeItemProvider.java   (with props)
Modified:
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/EjbLocalRefTypeItemProvider.java
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/EjbRefTypeItemProvider.java
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceEnvRefTypeItemProvider.java
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceRefTypeItemProvider.java

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/EjbLocalRefTypeItemProvider.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/EjbLocalRefTypeItemProvider.java?rev=366818&r1=366817&r2=366818&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/EjbLocalRefTypeItemProvider.java (original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/EjbLocalRefTypeItemProvider.java Sat Jan  7 08:26:22 2006
@@ -321,6 +321,12 @@
 		return GeronimoEMFEditPlugin.INSTANCE;
 	}
 
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnText(java.lang.Object,
+	 *      int)
+	 */
 	public String getColumnText(Object object, int columnIndex) {
 		EjbLocalRefType o = (EjbLocalRefType) object;
 		switch (columnIndex) {
@@ -339,12 +345,15 @@
 		return "";
 	}
 
-	/**
-	 * This does the same thing as ITableLabelProvider.getColumnImage.
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnImage(java.lang.Object,
+	 *      int)
 	 */
 	public Object getColumnImage(Object object, int columnIndex) {
 		if (columnIndex == 0) {
-			return getResourceLocator().getImage("full/obj16/EjbLocalRefType");
+			return getImage(object);
 		}
 		return null;
 	}

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/EjbRefTypeItemProvider.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/EjbRefTypeItemProvider.java?rev=366818&r1=366817&r2=366818&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/EjbRefTypeItemProvider.java (original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/EjbRefTypeItemProvider.java Sat Jan  7 08:26:22 2006
@@ -431,6 +431,12 @@
 		return GeronimoEMFEditPlugin.INSTANCE;
 	}
 
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnText(java.lang.Object,
+	 *      int)
+	 */
 	public String getColumnText(Object object, int columnIndex) {
 		EjbRefType o = (EjbRefType) object;
 		switch (columnIndex) {
@@ -448,12 +454,12 @@
 		return "";
 	}
 
-	/**
-	 * This does the same thing as ITableLabelProvider.getColumnImage.
+	/* (non-Javadoc)
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnImage(java.lang.Object, int)
 	 */
 	public Object getColumnImage(Object object, int columnIndex) {
 		if (columnIndex == 0) {
-			return getResourceLocator().getImage("full/obj16/EjbRefType");
+			return getImage(object);
 		}
 		return null;
 	}

Added: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/GbeanRefTypeItemProvider.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/GbeanRefTypeItemProvider.java?rev=366818&view=auto
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/GbeanRefTypeItemProvider.java (added)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/GbeanRefTypeItemProvider.java Sat Jan  7 08:26:22 2006
@@ -0,0 +1,437 @@
+/**
+ * Copyright 2004, 2005 The Apache Software Foundation or its licensors, as applicable
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.xml.ns.naming.provider;
+
+import java.util.Collection;
+import java.util.List;
+
+import org.apache.geronimo.deployment.model.edit.GeronimoEMFEditPlugin;
+import org.apache.geronimo.xml.ns.naming.GbeanRefType;
+import org.apache.geronimo.xml.ns.naming.NamingPackage;
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+import org.eclipse.emf.common.util.ResourceLocator;
+import org.eclipse.emf.ecore.util.FeatureMapUtil;
+import org.eclipse.emf.edit.provider.ComposeableAdapterFactory;
+import org.eclipse.emf.edit.provider.IEditingDomainItemProvider;
+import org.eclipse.emf.edit.provider.IItemLabelProvider;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITableItemLabelProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+import org.eclipse.emf.edit.provider.ItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.ItemProviderAdapter;
+import org.eclipse.emf.edit.provider.ViewerNotification;
+
+/**
+ * This is the item provider adapter for a
+ * {@link org.apache.geronimo.xml.ns.naming.GbeanRefType} object. <!--
+ * begin-user-doc --> <!-- end-user-doc -->
+ * 
+ * @generated NOT
+ */
+public class GbeanRefTypeItemProvider extends ItemProviderAdapter implements
+		IEditingDomainItemProvider, IStructuredItemContentProvider,
+		ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource,
+		ITableItemLabelProvider {
+	/**
+	 * <!-- begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public static final String copyright = "";
+
+	/**
+	 * This constructs an instance from a factory and a notifier. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public GbeanRefTypeItemProvider(AdapterFactory adapterFactory) {
+		super(adapterFactory);
+	}
+
+	/**
+	 * This returns the property descriptors for the adapted class. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public List getPropertyDescriptors(Object object) {
+		if (itemPropertyDescriptors == null) {
+			super.getPropertyDescriptors(object);
+
+			addRefNamePropertyDescriptor(object);
+			addRefTypePropertyDescriptor(object);
+			addProxyTypePropertyDescriptor(object);
+			addDomainPropertyDescriptor(object);
+			addServerPropertyDescriptor(object);
+			addApplicationPropertyDescriptor(object);
+			addModulePropertyDescriptor(object);
+			addTypePropertyDescriptor(object);
+			addNamePropertyDescriptor(object);
+			addTargetNamePropertyDescriptor(object);
+		}
+		return itemPropertyDescriptors;
+	}
+
+	/**
+	 * This adds a property descriptor for the Ref Name feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addRefNamePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_GbeanRefType_refName_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_GbeanRefType_refName_feature",
+						"_UI_GbeanRefType_type"), NamingPackage.eINSTANCE
+						.getGbeanRefType_RefName(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Ref Type feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addRefTypePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_GbeanRefType_refType_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_GbeanRefType_refType_feature",
+						"_UI_GbeanRefType_type"), NamingPackage.eINSTANCE
+						.getGbeanRefType_RefType(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Proxy Type feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addProxyTypePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_GbeanRefType_proxyType_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_GbeanRefType_proxyType_feature",
+						"_UI_GbeanRefType_type"), NamingPackage.eINSTANCE
+						.getGbeanRefType_ProxyType(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Domain feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addDomainPropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_GbeanRefType_domain_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_GbeanRefType_domain_feature",
+						"_UI_GbeanRefType_type"), NamingPackage.eINSTANCE
+						.getGbeanRefType_Domain(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Server feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addServerPropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_GbeanRefType_server_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_GbeanRefType_server_feature",
+						"_UI_GbeanRefType_type"), NamingPackage.eINSTANCE
+						.getGbeanRefType_Server(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Application feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addApplicationPropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_GbeanRefType_application_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_GbeanRefType_application_feature",
+						"_UI_GbeanRefType_type"), NamingPackage.eINSTANCE
+						.getGbeanRefType_Application(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Module feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addModulePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_GbeanRefType_module_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_GbeanRefType_module_feature",
+						"_UI_GbeanRefType_type"), NamingPackage.eINSTANCE
+						.getGbeanRefType_Module(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Type feature. <!-- begin-user-doc
+	 * --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addTypePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_GbeanRefType_type_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_GbeanRefType_type_feature",
+						"_UI_GbeanRefType_type"), NamingPackage.eINSTANCE
+						.getGbeanRefType_Type(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Name feature. <!-- begin-user-doc
+	 * --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addNamePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_GbeanRefType_name_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_GbeanRefType_name_feature",
+						"_UI_GbeanRefType_type"), NamingPackage.eINSTANCE
+						.getGbeanRefType_Name(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Target Name feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addTargetNamePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_GbeanRefType_targetName_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_GbeanRefType_targetName_feature",
+						"_UI_GbeanRefType_type"), NamingPackage.eINSTANCE
+						.getGbeanRefType_TargetName(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This specifies how to implement {@link #getChildren} and is used to
+	 * deduce an appropriate feature for an
+	 * {@link org.eclipse.emf.edit.command.AddCommand},
+	 * {@link org.eclipse.emf.edit.command.RemoveCommand} or
+	 * {@link org.eclipse.emf.edit.command.MoveCommand} in
+	 * {@link #createCommand}. <!-- begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public Collection getChildrenFeatures(Object object) {
+		if (childrenFeatures == null) {
+			super.getChildrenFeatures(object);
+			childrenFeatures.add(NamingPackage.eINSTANCE
+					.getGbeanRefType_Group());
+		}
+		return childrenFeatures;
+	}
+
+	/**
+	 * This returns GbeanRefType.gif. <!-- begin-user-doc --> <!-- end-user-doc
+	 * -->
+	 * 
+	 * @generated
+	 */
+	public Object getImage(Object object) {
+		return getResourceLocator().getImage("full/obj16/GbeanRefType");
+	}
+
+	/**
+	 * This returns the label text for the adapted class. <!-- begin-user-doc
+	 * --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public String getText(Object object) {
+		String label = ((GbeanRefType) object).getRefName();
+		return label == null || label.length() == 0 ? getString("_UI_GbeanRefType_type")
+				: getString("_UI_GbeanRefType_type") + " " + label;
+	}
+
+	/**
+	 * This handles model notifications by calling {@link #updateChildren} to
+	 * update any cached children and by creating a viewer notification, which
+	 * it passes to {@link #fireNotifyChanged}. <!-- begin-user-doc --> <!--
+	 * end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public void notifyChanged(Notification notification) {
+		updateChildren(notification);
+
+		switch (notification.getFeatureID(GbeanRefType.class)) {
+		case NamingPackage.GBEAN_REF_TYPE__REF_NAME:
+		case NamingPackage.GBEAN_REF_TYPE__REF_TYPE:
+		case NamingPackage.GBEAN_REF_TYPE__PROXY_TYPE:
+		case NamingPackage.GBEAN_REF_TYPE__DOMAIN:
+		case NamingPackage.GBEAN_REF_TYPE__SERVER:
+		case NamingPackage.GBEAN_REF_TYPE__APPLICATION:
+		case NamingPackage.GBEAN_REF_TYPE__MODULE:
+		case NamingPackage.GBEAN_REF_TYPE__TYPE:
+		case NamingPackage.GBEAN_REF_TYPE__NAME:
+		case NamingPackage.GBEAN_REF_TYPE__TARGET_NAME:
+			fireNotifyChanged(new ViewerNotification(notification, notification
+					.getNotifier(), false, true));
+			return;
+		case NamingPackage.GBEAN_REF_TYPE__GROUP:
+			fireNotifyChanged(new ViewerNotification(notification, notification
+					.getNotifier(), true, false));
+			return;
+		}
+		super.notifyChanged(notification);
+	}
+
+	/**
+	 * This adds to the collection of
+	 * {@link org.eclipse.emf.edit.command.CommandParameter}s describing all of
+	 * the children that can be created under this object. <!-- begin-user-doc
+	 * --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void collectNewChildDescriptors(Collection newChildDescriptors,
+			Object object) {
+		super.collectNewChildDescriptors(newChildDescriptors, object);
+
+		newChildDescriptors.add(createChildParameter(NamingPackage.eINSTANCE
+				.getGbeanRefType_Group(), FeatureMapUtil.createEntry(
+				NamingPackage.eINSTANCE.getGbeanRefType_Domain(), "")));
+
+		newChildDescriptors.add(createChildParameter(NamingPackage.eINSTANCE
+				.getGbeanRefType_Group(), FeatureMapUtil.createEntry(
+				NamingPackage.eINSTANCE.getGbeanRefType_Server(), "")));
+
+		newChildDescriptors.add(createChildParameter(NamingPackage.eINSTANCE
+				.getGbeanRefType_Group(), FeatureMapUtil.createEntry(
+				NamingPackage.eINSTANCE.getGbeanRefType_Application(), "")));
+
+		newChildDescriptors.add(createChildParameter(NamingPackage.eINSTANCE
+				.getGbeanRefType_Group(), FeatureMapUtil.createEntry(
+				NamingPackage.eINSTANCE.getGbeanRefType_Module(), "")));
+
+		newChildDescriptors.add(createChildParameter(NamingPackage.eINSTANCE
+				.getGbeanRefType_Group(), FeatureMapUtil.createEntry(
+				NamingPackage.eINSTANCE.getGbeanRefType_Type(), "")));
+
+		newChildDescriptors.add(createChildParameter(NamingPackage.eINSTANCE
+				.getGbeanRefType_Group(), FeatureMapUtil.createEntry(
+				NamingPackage.eINSTANCE.getGbeanRefType_Name(), "")));
+
+		newChildDescriptors.add(createChildParameter(NamingPackage.eINSTANCE
+				.getGbeanRefType_Group(), FeatureMapUtil.createEntry(
+				NamingPackage.eINSTANCE.getGbeanRefType_TargetName(), "")));
+	}
+
+	/**
+	 * Return the resource locator for this item provider's resources. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public ResourceLocator getResourceLocator() {
+		return GeronimoEMFEditPlugin.INSTANCE;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnText(java.lang.Object,
+	 *      int)
+	 */
+	public String getColumnText(Object object, int columnIndex) {
+		GbeanRefType o = (GbeanRefType) object;
+		switch (columnIndex) {
+		case 0:
+			if (o.eIsSet(NamingPackage.eINSTANCE.getGbeanRefType_RefName())) {
+				return o.getRefName();
+			}
+			break;
+		case 1:
+			if (o.eIsSet(NamingPackage.eINSTANCE.getGbeanRefType_RefType())) {
+				return o.getRefType();
+			}
+			break;
+		case 2:
+			if (o.eIsSet(NamingPackage.eINSTANCE.getGbeanRefType_ProxyType())) {
+				return o.getProxyType();
+			}
+			break;
+		}
+		return "";
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnImage(java.lang.Object,
+	 *      int)
+	 */
+	public Object getColumnImage(Object object, int columnIndex) {
+		if (columnIndex == 0) {
+			return getImage(object);
+		}
+		return null;
+	}
+
+}

Propchange: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/GbeanRefTypeItemProvider.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/GbeanRefTypeItemProvider.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/GbeanRefTypeItemProvider.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceEnvRefTypeItemProvider.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceEnvRefTypeItemProvider.java?rev=366818&r1=366817&r2=366818&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceEnvRefTypeItemProvider.java (original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceEnvRefTypeItemProvider.java Sat Jan  7 08:26:22 2006
@@ -15,7 +15,6 @@
  */
 package org.apache.geronimo.xml.ns.naming.provider;
 
-
 import java.util.Collection;
 import java.util.List;
 
@@ -37,388 +36,354 @@
 import org.eclipse.emf.edit.provider.ViewerNotification;
 
 /**
- * This is the item provider adapter for a {@link org.apache.geronimo.xml.ns.naming.ResourceEnvRefType} object.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
+ * This is the item provider adapter for a
+ * {@link org.apache.geronimo.xml.ns.naming.ResourceEnvRefType} object. <!--
+ * begin-user-doc --> <!-- end-user-doc -->
+ * 
  * @generated NOT
  */
-public class ResourceEnvRefTypeItemProvider
-  extends ItemProviderAdapter
-  implements	
-    IEditingDomainItemProvider,	
-    IStructuredItemContentProvider,	
-    ITreeItemContentProvider,	
-    IItemLabelProvider,	
-    IItemPropertySource	,
-    ITableItemLabelProvider
-{
-  /**
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  public static final String copyright = "";
-
-  /**
-   * This constructs an instance from a factory and a notifier.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  public ResourceEnvRefTypeItemProvider(AdapterFactory adapterFactory)
-  {
-    super(adapterFactory);
-  }
-
-  /**
-   * This returns the property descriptors for the adapted class.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  public List getPropertyDescriptors(Object object)
-  {
-    if (itemPropertyDescriptors == null)
-    {
-      super.getPropertyDescriptors(object);
-
-      addRefNamePropertyDescriptor(object);
-      addDomainPropertyDescriptor(object);
-      addServerPropertyDescriptor(object);
-      addApplicationPropertyDescriptor(object);
-      addModulePropertyDescriptor(object);
-      addTypePropertyDescriptor(object);
-      addNamePropertyDescriptor(object);
-      addMessageDestinationLinkPropertyDescriptor(object);
-      addAdminObjectModulePropertyDescriptor(object);
-      addAdminObjectLinkPropertyDescriptor(object);
-      addTargetNamePropertyDescriptor(object);
-    }
-    return itemPropertyDescriptors;
-  }
-
-  /**
-   * This adds a property descriptor for the Ref Name feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addRefNamePropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_refName_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_refName_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_RefName(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This adds a property descriptor for the Domain feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addDomainPropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_domain_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_domain_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_Domain(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This adds a property descriptor for the Server feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addServerPropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_server_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_server_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_Server(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This adds a property descriptor for the Application feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addApplicationPropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_application_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_application_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_Application(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This adds a property descriptor for the Module feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addModulePropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_module_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_module_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_Module(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This adds a property descriptor for the Type feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addTypePropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_type_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_type_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_Type(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This adds a property descriptor for the Name feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addNamePropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_name_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_name_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_Name(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This adds a property descriptor for the Message Destination Link feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addMessageDestinationLinkPropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_messageDestinationLink_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_messageDestinationLink_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_MessageDestinationLink(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This adds a property descriptor for the Admin Object Module feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addAdminObjectModulePropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_adminObjectModule_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_adminObjectModule_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_AdminObjectModule(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This adds a property descriptor for the Admin Object Link feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addAdminObjectLinkPropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_adminObjectLink_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_adminObjectLink_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_AdminObjectLink(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This adds a property descriptor for the Target Name feature.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void addTargetNamePropertyDescriptor(Object object)
-  {
-    itemPropertyDescriptors.add
-      (createItemPropertyDescriptor
-        (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
-         getResourceLocator(),
-         getString("_UI_ResourceEnvRefType_targetName_feature"),
-         getString("_UI_PropertyDescriptor_description", "_UI_ResourceEnvRefType_targetName_feature", "_UI_ResourceEnvRefType_type"),
-         NamingPackage.eINSTANCE.getResourceEnvRefType_TargetName(),
-         true,
-         ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
-         null,
-         null));
-  }
-
-  /**
-   * This returns ResourceEnvRefType.gif.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  public Object getImage(Object object)
-  {
-    return getResourceLocator().getImage("full/obj16/ResourceEnvRefType");
-  }
-
-  /**
-   * This returns the label text for the adapted class.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  public String getText(Object object)
-  {
-    String label = ((ResourceEnvRefType)object).getName();
-    return label == null || label.length() == 0 ?
-      getString("_UI_ResourceEnvRefType_type") :
-      getString("_UI_ResourceEnvRefType_type") + " " + label;
-  }
-
-  /**
-   * This handles model notifications by calling {@link #updateChildren} to update any cached
-   * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  public void notifyChanged(Notification notification)
-  {
-    updateChildren(notification);
-
-    switch (notification.getFeatureID(ResourceEnvRefType.class))
-    {
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__REF_NAME:
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__DOMAIN:
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__SERVER:
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__APPLICATION:
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__MODULE:
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__TYPE:
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__NAME:
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__MESSAGE_DESTINATION_LINK:
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__ADMIN_OBJECT_MODULE:
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__ADMIN_OBJECT_LINK:
-      case NamingPackage.RESOURCE_ENV_REF_TYPE__TARGET_NAME:
-        fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
-        return;
-    }
-    super.notifyChanged(notification);
-  }
-
-  /**
-   * This adds to the collection of {@link org.eclipse.emf.edit.command.CommandParameter}s
-   * describing all of the children that can be created under this object.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
-  {
-    super.collectNewChildDescriptors(newChildDescriptors, object);
-  }
-
-  /**
-   * Return the resource locator for this item provider's resources.
-   * <!-- begin-user-doc -->
-   * <!-- end-user-doc -->
-   * @generated
-   */
-  public ResourceLocator getResourceLocator()
-  {
-    return GeronimoEMFEditPlugin.INSTANCE;
-  }
-  
-  /**
-	 * This does the same thing as ITableLabelProvider.getColumnText.
+public class ResourceEnvRefTypeItemProvider extends ItemProviderAdapter
+		implements IEditingDomainItemProvider, IStructuredItemContentProvider,
+		ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource,
+		ITableItemLabelProvider {
+	/**
+	 * <!-- begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public static final String copyright = "";
+
+	/**
+	 * This constructs an instance from a factory and a notifier. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public ResourceEnvRefTypeItemProvider(AdapterFactory adapterFactory) {
+		super(adapterFactory);
+	}
+
+	/**
+	 * This returns the property descriptors for the adapted class. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public List getPropertyDescriptors(Object object) {
+		if (itemPropertyDescriptors == null) {
+			super.getPropertyDescriptors(object);
+
+			addRefNamePropertyDescriptor(object);
+			addDomainPropertyDescriptor(object);
+			addServerPropertyDescriptor(object);
+			addApplicationPropertyDescriptor(object);
+			addModulePropertyDescriptor(object);
+			addTypePropertyDescriptor(object);
+			addNamePropertyDescriptor(object);
+			addMessageDestinationLinkPropertyDescriptor(object);
+			addAdminObjectModulePropertyDescriptor(object);
+			addAdminObjectLinkPropertyDescriptor(object);
+			addTargetNamePropertyDescriptor(object);
+		}
+		return itemPropertyDescriptors;
+	}
+
+	/**
+	 * This adds a property descriptor for the Ref Name feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addRefNamePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ResourceEnvRefType_refName_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_ResourceEnvRefType_refName_feature",
+						"_UI_ResourceEnvRefType_type"), NamingPackage.eINSTANCE
+						.getResourceEnvRefType_RefName(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Domain feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addDomainPropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ResourceEnvRefType_domain_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_ResourceEnvRefType_domain_feature",
+						"_UI_ResourceEnvRefType_type"), NamingPackage.eINSTANCE
+						.getResourceEnvRefType_Domain(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Server feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addServerPropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ResourceEnvRefType_server_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_ResourceEnvRefType_server_feature",
+						"_UI_ResourceEnvRefType_type"), NamingPackage.eINSTANCE
+						.getResourceEnvRefType_Server(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Application feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addApplicationPropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ResourceEnvRefType_application_feature"),
+				getString("_UI_PropertyDescriptor_description",
+						"_UI_ResourceEnvRefType_application_feature",
+						"_UI_ResourceEnvRefType_type"), NamingPackage.eINSTANCE
+						.getResourceEnvRefType_Application(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Module feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addModulePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ResourceEnvRefType_module_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_ResourceEnvRefType_module_feature",
+						"_UI_ResourceEnvRefType_type"), NamingPackage.eINSTANCE
+						.getResourceEnvRefType_Module(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Type feature. <!-- begin-user-doc
+	 * --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addTypePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ResourceEnvRefType_type_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_ResourceEnvRefType_type_feature",
+						"_UI_ResourceEnvRefType_type"), NamingPackage.eINSTANCE
+						.getResourceEnvRefType_Type(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Name feature. <!-- begin-user-doc
+	 * --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addNamePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ResourceEnvRefType_name_feature"), getString(
+						"_UI_PropertyDescriptor_description",
+						"_UI_ResourceEnvRefType_name_feature",
+						"_UI_ResourceEnvRefType_type"), NamingPackage.eINSTANCE
+						.getResourceEnvRefType_Name(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Message Destination Link feature.
+	 * <!-- begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addMessageDestinationLinkPropertyDescriptor(Object object) {
+		itemPropertyDescriptors
+				.add(createItemPropertyDescriptor(
+						((ComposeableAdapterFactory) adapterFactory)
+								.getRootAdapterFactory(),
+						getResourceLocator(),
+						getString("_UI_ResourceEnvRefType_messageDestinationLink_feature"),
+						getString(
+								"_UI_PropertyDescriptor_description",
+								"_UI_ResourceEnvRefType_messageDestinationLink_feature",
+								"_UI_ResourceEnvRefType_type"),
+						NamingPackage.eINSTANCE
+								.getResourceEnvRefType_MessageDestinationLink(),
+						true, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null,
+						null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Admin Object Module feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addAdminObjectModulePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ResourceEnvRefType_adminObjectModule_feature"),
+				getString("_UI_PropertyDescriptor_description",
+						"_UI_ResourceEnvRefType_adminObjectModule_feature",
+						"_UI_ResourceEnvRefType_type"), NamingPackage.eINSTANCE
+						.getResourceEnvRefType_AdminObjectModule(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Admin Object Link feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addAdminObjectLinkPropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ResourceEnvRefType_adminObjectLink_feature"),
+				getString("_UI_PropertyDescriptor_description",
+						"_UI_ResourceEnvRefType_adminObjectLink_feature",
+						"_UI_ResourceEnvRefType_type"), NamingPackage.eINSTANCE
+						.getResourceEnvRefType_AdminObjectLink(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This adds a property descriptor for the Target Name feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addTargetNamePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ResourceEnvRefType_targetName_feature"),
+				getString("_UI_PropertyDescriptor_description",
+						"_UI_ResourceEnvRefType_targetName_feature",
+						"_UI_ResourceEnvRefType_type"), NamingPackage.eINSTANCE
+						.getResourceEnvRefType_TargetName(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This returns ResourceEnvRefType.gif. <!-- begin-user-doc --> <!--
+	 * end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public Object getImage(Object object) {
+		return getResourceLocator().getImage("full/obj16/ResourceEnvRefType");
+	}
+
+	/**
+	 * This returns the label text for the adapted class. <!-- begin-user-doc
+	 * --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public String getText(Object object) {
+		String label = ((ResourceEnvRefType) object).getName();
+		return label == null || label.length() == 0 ? getString("_UI_ResourceEnvRefType_type")
+				: getString("_UI_ResourceEnvRefType_type") + " " + label;
+	}
+
+	/**
+	 * This handles model notifications by calling {@link #updateChildren} to
+	 * update any cached children and by creating a viewer notification, which
+	 * it passes to {@link #fireNotifyChanged}. <!-- begin-user-doc --> <!--
+	 * end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public void notifyChanged(Notification notification) {
+		updateChildren(notification);
+
+		switch (notification.getFeatureID(ResourceEnvRefType.class)) {
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__REF_NAME:
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__DOMAIN:
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__SERVER:
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__APPLICATION:
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__MODULE:
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__TYPE:
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__NAME:
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__MESSAGE_DESTINATION_LINK:
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__ADMIN_OBJECT_MODULE:
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__ADMIN_OBJECT_LINK:
+		case NamingPackage.RESOURCE_ENV_REF_TYPE__TARGET_NAME:
+			fireNotifyChanged(new ViewerNotification(notification, notification
+					.getNotifier(), false, true));
+			return;
+		}
+		super.notifyChanged(notification);
+	}
+
+	/**
+	 * This adds to the collection of
+	 * {@link org.eclipse.emf.edit.command.CommandParameter}s describing all of
+	 * the children that can be created under this object. <!-- begin-user-doc
+	 * --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void collectNewChildDescriptors(Collection newChildDescriptors,
+			Object object) {
+		super.collectNewChildDescriptors(newChildDescriptors, object);
+	}
+
+	/**
+	 * Return the resource locator for this item provider's resources. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public ResourceLocator getResourceLocator() {
+		return GeronimoEMFEditPlugin.INSTANCE;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnText(java.lang.Object,
+	 *      int)
 	 */
 	public String getColumnText(Object object, int columnIndex) {
 		ResourceEnvRefType o = (ResourceEnvRefType) object;
-		switch(columnIndex) {
+		switch (columnIndex) {
 		case 0:
-			if(o.eIsSet(NamingPackage.eINSTANCE.getResourceEnvRefType_RefName())) {
+			if (o.eIsSet(NamingPackage.eINSTANCE
+					.getResourceEnvRefType_RefName())) {
 				return o.getRefName();
 			}
 			break;
 		case 1:
-			if(o.eIsSet(NamingPackage.eINSTANCE.getResourceEnvRefType_MessageDestinationLink())) {
+			if (o.eIsSet(NamingPackage.eINSTANCE
+					.getResourceEnvRefType_MessageDestinationLink())) {
 				return o.getMessageDestinationLink();
 			}
 			break;
@@ -426,12 +391,15 @@
 		return "";
 	}
 
-	/**
-	 * This does the same thing as ITableLabelProvider.getColumnImage.
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnImage(java.lang.Object,
+	 *      int)
 	 */
 	public Object getColumnImage(Object object, int columnIndex) {
 		if (columnIndex == 0) {
-			return getResourceLocator().getImage("full/obj16/ResourceEnvRefType");
+			return getImage(object);
 		}
 		return null;
 	}

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceRefTypeItemProvider.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceRefTypeItemProvider.java?rev=366818&r1=366817&r2=366818&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceRefTypeItemProvider.java (original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceRefTypeItemProvider.java Sat Jan  7 08:26:22 2006
@@ -341,8 +341,8 @@
 		return GeronimoEMFEditPlugin.INSTANCE;
 	}
 
-	/**
-	 * This does the same thing as ITableLabelProvider.getColumnText.
+	/* (non-Javadoc)
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnText(java.lang.Object, int)
 	 */
 	public String getColumnText(Object object, int columnIndex) {
 		ResourceRefType o = (ResourceRefType) object;
@@ -363,12 +363,12 @@
 		return "";
 	}
 
-	/**
-	 * This does the same thing as ITableLabelProvider.getColumnImage.
+	/* (non-Javadoc)
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnImage(java.lang.Object, int)
 	 */
 	public Object getColumnImage(Object object, int columnIndex) {
 		if (columnIndex == 0) {
-			return getResourceLocator().getImage("full/obj16/ResourceRefType");
+			return getImage(object);
 		}
 		return null;
 	}

Added: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ServiceRefTypeItemProvider.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ServiceRefTypeItemProvider.java?rev=366818&view=auto
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ServiceRefTypeItemProvider.java (added)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ServiceRefTypeItemProvider.java Sat Jan  7 08:26:22 2006
@@ -0,0 +1,241 @@
+/**
+ * Copyright 2004, 2005 The Apache Software Foundation or its licensors, as applicable
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.xml.ns.naming.provider;
+
+import java.util.Collection;
+import java.util.List;
+
+import org.apache.geronimo.deployment.model.edit.GeronimoEMFEditPlugin;
+
+import org.apache.geronimo.xml.ns.naming.NamingFactory;
+import org.apache.geronimo.xml.ns.naming.NamingPackage;
+import org.apache.geronimo.xml.ns.naming.ResourceRefType;
+import org.apache.geronimo.xml.ns.naming.ServiceRefType;
+
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+
+import org.eclipse.emf.common.util.ResourceLocator;
+
+import org.eclipse.emf.ecore.EStructuralFeature;
+
+import org.eclipse.emf.edit.provider.ComposeableAdapterFactory;
+import org.eclipse.emf.edit.provider.IEditingDomainItemProvider;
+import org.eclipse.emf.edit.provider.IItemLabelProvider;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITableItemLabelProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+import org.eclipse.emf.edit.provider.ItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.ItemProviderAdapter;
+import org.eclipse.emf.edit.provider.ViewerNotification;
+
+/**
+ * This is the item provider adapter for a
+ * {@link org.apache.geronimo.xml.ns.naming.ServiceRefType} object. <!--
+ * begin-user-doc --> <!-- end-user-doc -->
+ * 
+ * @generated NOT
+ */
+public class ServiceRefTypeItemProvider extends ItemProviderAdapter implements
+		IEditingDomainItemProvider, IStructuredItemContentProvider,
+		ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource,
+		ITableItemLabelProvider {
+	/**
+	 * <!-- begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public static final String copyright = "";
+
+	/**
+	 * This constructs an instance from a factory and a notifier. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public ServiceRefTypeItemProvider(AdapterFactory adapterFactory) {
+		super(adapterFactory);
+	}
+
+	/**
+	 * This returns the property descriptors for the adapted class. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public List getPropertyDescriptors(Object object) {
+		if (itemPropertyDescriptors == null) {
+			super.getPropertyDescriptors(object);
+
+			addServiceRefNamePropertyDescriptor(object);
+		}
+		return itemPropertyDescriptors;
+	}
+
+	/**
+	 * This adds a property descriptor for the Service Ref Name feature. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void addServiceRefNamePropertyDescriptor(Object object) {
+		itemPropertyDescriptors.add(createItemPropertyDescriptor(
+				((ComposeableAdapterFactory) adapterFactory)
+						.getRootAdapterFactory(), getResourceLocator(),
+				getString("_UI_ServiceRefType_serviceRefName_feature"),
+				getString("_UI_PropertyDescriptor_description",
+						"_UI_ServiceRefType_serviceRefName_feature",
+						"_UI_ServiceRefType_type"), NamingPackage.eINSTANCE
+						.getServiceRefType_ServiceRefName(), true,
+				ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+	}
+
+	/**
+	 * This specifies how to implement {@link #getChildren} and is used to
+	 * deduce an appropriate feature for an
+	 * {@link org.eclipse.emf.edit.command.AddCommand},
+	 * {@link org.eclipse.emf.edit.command.RemoveCommand} or
+	 * {@link org.eclipse.emf.edit.command.MoveCommand} in
+	 * {@link #createCommand}. <!-- begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public Collection getChildrenFeatures(Object object) {
+		if (childrenFeatures == null) {
+			super.getChildrenFeatures(object);
+			childrenFeatures.add(NamingPackage.eINSTANCE
+					.getServiceRefType_ServiceCompletion());
+			childrenFeatures.add(NamingPackage.eINSTANCE
+					.getServiceRefType_Port());
+		}
+		return childrenFeatures;
+	}
+
+	/**
+	 * <!-- begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected EStructuralFeature getChildFeature(Object object, Object child) {
+		// Check the type of the specified child object and return the proper
+		// feature to use for
+		// adding (see {@link AddCommand}) it as a child.
+
+		return super.getChildFeature(object, child);
+	}
+
+	/**
+	 * This returns ServiceRefType.gif. <!-- begin-user-doc --> <!--
+	 * end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public Object getImage(Object object) {
+		return getResourceLocator().getImage("full/obj16/ServiceRefType");
+	}
+
+	/**
+	 * This returns the label text for the adapted class. <!-- begin-user-doc
+	 * --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public String getText(Object object) {
+		String label = ((ServiceRefType) object).getServiceRefName();
+		return label == null || label.length() == 0 ? getString("_UI_ServiceRefType_type")
+				: getString("_UI_ServiceRefType_type") + " " + label;
+	}
+
+	/**
+	 * This handles model notifications by calling {@link #updateChildren} to
+	 * update any cached children and by creating a viewer notification, which
+	 * it passes to {@link #fireNotifyChanged}. <!-- begin-user-doc --> <!--
+	 * end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public void notifyChanged(Notification notification) {
+		updateChildren(notification);
+
+		switch (notification.getFeatureID(ServiceRefType.class)) {
+		case NamingPackage.SERVICE_REF_TYPE__SERVICE_REF_NAME:
+			fireNotifyChanged(new ViewerNotification(notification, notification
+					.getNotifier(), false, true));
+			return;
+		case NamingPackage.SERVICE_REF_TYPE__SERVICE_COMPLETION:
+		case NamingPackage.SERVICE_REF_TYPE__PORT:
+			fireNotifyChanged(new ViewerNotification(notification, notification
+					.getNotifier(), true, false));
+			return;
+		}
+		super.notifyChanged(notification);
+	}
+
+	/**
+	 * This adds to the collection of
+	 * {@link org.eclipse.emf.edit.command.CommandParameter}s describing all of
+	 * the children that can be created under this object. <!-- begin-user-doc
+	 * --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	protected void collectNewChildDescriptors(Collection newChildDescriptors,
+			Object object) {
+		super.collectNewChildDescriptors(newChildDescriptors, object);
+
+		newChildDescriptors.add(createChildParameter(NamingPackage.eINSTANCE
+				.getServiceRefType_ServiceCompletion(), NamingFactory.eINSTANCE
+				.createServiceCompletionType()));
+
+		newChildDescriptors.add(createChildParameter(NamingPackage.eINSTANCE
+				.getServiceRefType_Port(), NamingFactory.eINSTANCE
+				.createPortType()));
+	}
+
+	/**
+	 * Return the resource locator for this item provider's resources. <!--
+	 * begin-user-doc --> <!-- end-user-doc -->
+	 * 
+	 * @generated
+	 */
+	public ResourceLocator getResourceLocator() {
+		return GeronimoEMFEditPlugin.INSTANCE;
+	}
+
+	/* (non-Javadoc)
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnText(java.lang.Object, int)
+	 */
+	public String getColumnText(Object object, int columnIndex) {
+		ServiceRefType o = (ServiceRefType) object;
+		switch (columnIndex) {
+		case 0:
+			return o.getServiceRefName();
+		}
+		return "";
+	}
+
+	/* (non-Javadoc)
+	 * @see org.eclipse.emf.edit.provider.ITableItemLabelProvider#getColumnImage(java.lang.Object, int)
+	 */
+	public Object getColumnImage(Object object, int columnIndex) {
+		if (columnIndex == 0) {
+			return getImage(object);
+		}
+		return null;
+	}
+
+}

Propchange: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ServiceRefTypeItemProvider.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ServiceRefTypeItemProvider.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ServiceRefTypeItemProvider.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain



Mime
View raw message