001: /**
002: * <copyright>
003: * </copyright>
004: *
005: * $Id: StyleItemProvider.java 24145 2007-02-01 18:03:34Z jeichar $
006: */package net.refractions.udig.project.internal.render.provider;
007:
008: import java.util.Collection;
009: import java.util.List;
010:
011: import net.refractions.udig.project.internal.provider.ProjectEditPlugin;
012:
013: import org.eclipse.emf.common.notify.AdapterFactory;
014: import org.eclipse.emf.common.notify.Notification;
015: import org.eclipse.emf.common.util.ResourceLocator;
016: import org.eclipse.emf.edit.provider.IEditingDomainItemProvider;
017: import org.eclipse.emf.edit.provider.IItemLabelProvider;
018: import org.eclipse.emf.edit.provider.IItemPropertySource;
019: import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
020: import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
021: import org.eclipse.emf.edit.provider.ItemProviderAdapter;
022:
023: /**
024: * This is the item provider adapter for a
025: * {@link net.refractions.udig.project.internal.render.Style} object. <!-- begin-user-doc --> <!--
026: * end-user-doc -->
027: *
028: * @generated
029: */
030: public class StyleItemProvider extends ItemProviderAdapter implements
031: IEditingDomainItemProvider, IStructuredItemContentProvider,
032: ITreeItemContentProvider, IItemLabelProvider,
033: IItemPropertySource {
034: /**
035: * <!-- begin-user-doc --> <!-- end-user-doc -->
036: *
037: * @generated
038: */
039: public static final String copyright = "uDig - User Friendly Desktop Internet GIS client http://udig.refractions.net (C) 2004, Refractions Research Inc. This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; version 2.1 of the License. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details."; //$NON-NLS-1$
040:
041: /**
042: * This constructs an instance from a factory and a notifier. <!-- begin-user-doc --> <!--
043: * end-user-doc -->
044: *
045: * @generated
046: */
047: public StyleItemProvider(AdapterFactory adapterFactory) {
048: super (adapterFactory);
049: }
050:
051: /**
052: * This returns the property descriptors for the adapted class. <!-- begin-user-doc --> <!--
053: * end-user-doc -->
054: *
055: * @generated
056: */
057: public List getPropertyDescriptors(Object object) {
058: if (itemPropertyDescriptors == null) {
059: super .getPropertyDescriptors(object);
060:
061: }
062: return itemPropertyDescriptors;
063: }
064:
065: /**
066: * This returns Style.gif. <!-- begin-user-doc --> <!-- end-user-doc -->
067: *
068: * @generated
069: */
070: public Object getImage(Object object) {
071: return getResourceLocator().getImage("full/obj16/Style"); //$NON-NLS-1$
072: }
073:
074: /**
075: * This returns the label text for the adapted class. <!-- begin-user-doc --> <!-- end-user-doc
076: * -->
077: *
078: * @generated NOT
079: */
080: public String getText(Object object) {
081: return "Style";
082: }
083:
084: /**
085: * This handles model notifications by calling {@link #updateChildren} to update any cached
086: * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
087: * <!-- begin-user-doc --> <!-- end-user-doc -->
088: *
089: * @generated
090: */
091: public void notifyChanged(Notification notification) {
092: updateChildren(notification);
093: super .notifyChanged(notification);
094: }
095:
096: /**
097: * This adds to the collection of {@link org.eclipse.emf.edit.command.CommandParameter}s
098: * describing all of the children that can be created under this object. <!-- begin-user-doc -->
099: * <!-- end-user-doc -->
100: *
101: * @generated
102: */
103: protected void collectNewChildDescriptors(
104: Collection newChildDescriptors, Object object) {
105: super .collectNewChildDescriptors(newChildDescriptors, object);
106: }
107:
108: /**
109: * Return the resource locator for this item provider's resources. <!-- begin-user-doc --> <!--
110: * end-user-doc -->
111: *
112: * @generated
113: */
114: public ResourceLocator getResourceLocator() {
115: return ProjectEditPlugin.INSTANCE;
116: }
117:
118: }
|