From 6eff5a52e3078e23bb6cc982adb9f6120110f679 Mon Sep 17 00:00:00 2001
From: Francesco Guidieri
Date: Thu, 4 Jul 2013 16:30:36 +0200
Subject: Initial contribution
---
.../.classpath | 7 +
.../org.eclipse.emf.examples.library.edit/.project | 46 +++
.../.settings/org.eclipse.jdt.core.prefs | 7 +
.../.settings/org.eclipse.jdt.launching.prefs | 3 +
.../META-INF/MANIFEST.MF | 16 +
.../about.html | 28 ++
.../build.properties | 9 +
.../ctool16/CreateLibrary_borrowers_Borrower.gif | Bin 0 -> 223 bytes
.../ctool16/CreateLibrary_branches_Library.gif | Bin 0 -> 223 bytes
.../ctool16/CreateLibrary_employees_Employee.gif | Bin 0 -> 223 bytes
.../full/ctool16/CreateLibrary_stock_Book.gif | Bin 0 -> 223 bytes
.../ctool16/CreateLibrary_stock_BookOnTape.gif | Bin 0 -> 223 bytes
.../ctool16/CreateLibrary_stock_VideoCassette.gif | Bin 0 -> 223 bytes
.../full/ctool16/CreateLibrary_writers_Writer.gif | Bin 0 -> 223 bytes
.../icons/full/obj16/Book.gif | Bin 0 -> 129 bytes
.../icons/full/obj16/BookOnTape.gif | Bin 0 -> 129 bytes
.../icons/full/obj16/Borrower.gif | Bin 0 -> 129 bytes
.../icons/full/obj16/CirculatingItem.gif | Bin 0 -> 129 bytes
.../icons/full/obj16/Employee.gif | Bin 0 -> 129 bytes
.../icons/full/obj16/Library.gif | Bin 0 -> 129 bytes
.../icons/full/obj16/Person.gif | Bin 0 -> 129 bytes
.../icons/full/obj16/VideoCassette.gif | Bin 0 -> 129 bytes
.../icons/full/obj16/Writer.gif | Bin 0 -> 129 bytes
.../plugin.properties | 79 ++++
.../plugin.xml | 18 +
.../provider/AudioVisualItemItemProvider.java | 199 ++++++++++
.../extlibrary/provider/BookItemProvider.java | 235 ++++++++++++
.../provider/BookOnTapeItemProvider.java | 176 +++++++++
.../extlibrary/provider/BorrowerItemProvider.java | 152 ++++++++
.../provider/CirculatingItemItemProvider.java | 187 ++++++++++
.../extlibrary/provider/EXTLibraryEditPlugin.java | 104 ++++++
.../EXTLibraryItemProviderAdapterFactory.java | 405 +++++++++++++++++++++
.../extlibrary/provider/EmployeeItemProvider.java | 152 ++++++++
.../extlibrary/provider/ItemItemProvider.java | 166 +++++++++
.../extlibrary/provider/LibraryItemProvider.java | 307 ++++++++++++++++
.../provider/PeriodicalItemProvider.java | 174 +++++++++
.../extlibrary/provider/PersonItemProvider.java | 226 ++++++++++++
.../provider/VideoCassetteItemProvider.java | 152 ++++++++
.../extlibrary/provider/WriterItemProvider.java | 185 ++++++++++
39 files changed, 3033 insertions(+)
create mode 100644 examples/org.eclipse.emf.examples.library.edit/.classpath
create mode 100644 examples/org.eclipse.emf.examples.library.edit/.project
create mode 100644 examples/org.eclipse.emf.examples.library.edit/.settings/org.eclipse.jdt.core.prefs
create mode 100644 examples/org.eclipse.emf.examples.library.edit/.settings/org.eclipse.jdt.launching.prefs
create mode 100644 examples/org.eclipse.emf.examples.library.edit/META-INF/MANIFEST.MF
create mode 100644 examples/org.eclipse.emf.examples.library.edit/about.html
create mode 100644 examples/org.eclipse.emf.examples.library.edit/build.properties
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_borrowers_Borrower.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_branches_Library.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_employees_Employee.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_Book.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_BookOnTape.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_VideoCassette.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_writers_Writer.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Book.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/BookOnTape.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Borrower.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/CirculatingItem.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Employee.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Library.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Person.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/VideoCassette.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Writer.gif
create mode 100644 examples/org.eclipse.emf.examples.library.edit/plugin.properties
create mode 100644 examples/org.eclipse.emf.examples.library.edit/plugin.xml
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/AudioVisualItemItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BookItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BookOnTapeItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BorrowerItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/CirculatingItemItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EXTLibraryEditPlugin.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EXTLibraryItemProviderAdapterFactory.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EmployeeItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/ItemItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/LibraryItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/PeriodicalItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/PersonItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/VideoCassetteItemProvider.java
create mode 100644 examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/WriterItemProvider.java
(limited to 'examples/org.eclipse.emf.examples.library.edit')
diff --git a/examples/org.eclipse.emf.examples.library.edit/.classpath b/examples/org.eclipse.emf.examples.library.edit/.classpath
new file mode 100644
index 000000000..304e86186
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/.classpath
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+
diff --git a/examples/org.eclipse.emf.examples.library.edit/.project b/examples/org.eclipse.emf.examples.library.edit/.project
new file mode 100644
index 000000000..3b692448a
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/.project
@@ -0,0 +1,46 @@
+
+
+ org.eclipse.emf.examples.library.edit
+
+
+
+
+
+ org.eclipse.jdt.core.javabuilder
+
+
+
+
+ org.eclipse.pde.ManifestBuilder
+
+
+
+
+ org.eclipse.pde.SchemaBuilder
+
+
+
+
+ org.eclipse.emf.cdo.releng.version.VersionBuilder
+
+
+ ignore.missing.dependency.ranges
+ true
+
+
+ ignore.schema.builder
+ true
+
+
+ release.path
+ /org.eclipse.emf.java/release.xml
+
+
+
+
+
+ org.eclipse.jdt.core.javanature
+ org.eclipse.pde.PluginNature
+ org.eclipse.emf.cdo.releng.version.VersionNature
+
+
diff --git a/examples/org.eclipse.emf.examples.library.edit/.settings/org.eclipse.jdt.core.prefs b/examples/org.eclipse.emf.examples.library.edit/.settings/org.eclipse.jdt.core.prefs
new file mode 100644
index 000000000..d29b0f382
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/.settings/org.eclipse.jdt.core.prefs
@@ -0,0 +1,7 @@
+#Wed Nov 08 10:51:59 EST 2006
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
+org.eclipse.jdt.core.compiler.compliance=1.5
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.source=1.5
diff --git a/examples/org.eclipse.emf.examples.library.edit/.settings/org.eclipse.jdt.launching.prefs b/examples/org.eclipse.emf.examples.library.edit/.settings/org.eclipse.jdt.launching.prefs
new file mode 100644
index 000000000..96809758d
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/.settings/org.eclipse.jdt.launching.prefs
@@ -0,0 +1,3 @@
+#Wed Aug 12 21:10:17 CEST 2009
+eclipse.preferences.version=1
+org.eclipse.jdt.launching.PREF_STRICTLY_COMPATIBLE_JRE_NOT_AVAILABLE=ignore
diff --git a/examples/org.eclipse.emf.examples.library.edit/META-INF/MANIFEST.MF b/examples/org.eclipse.emf.examples.library.edit/META-INF/MANIFEST.MF
new file mode 100644
index 000000000..c75eb7d46
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/META-INF/MANIFEST.MF
@@ -0,0 +1,16 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %pluginName
+Bundle-SymbolicName: org.eclipse.emf.examples.library.edit; singleton:=true
+Bundle-Version: 2.5.0.qualifier
+Bundle-ClassPath: .
+Bundle-Activator: org.eclipse.emf.examples.extlibrary.provider.EXTLibraryEditPlugin$Implementation
+Bundle-Vendor: %providerName
+Bundle-Localization: plugin
+Bundle-RequiredExecutionEnvironment: J2SE-1.5
+Export-Package: org.eclipse.emf.examples.extlibrary.provider
+Require-Bundle: org.eclipse.core.runtime;bundle-version="3.5.0",
+ org.eclipse.emf.examples.library;visibility:=reexport,
+ org.eclipse.emf.edit;bundle-version="2.7.0";visibility:=reexport
+Eclipse-LazyStart: true
+Bundle-ActivationPolicy: lazy
diff --git a/examples/org.eclipse.emf.examples.library.edit/about.html b/examples/org.eclipse.emf.examples.library.edit/about.html
new file mode 100644
index 000000000..1b8f94080
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/about.html
@@ -0,0 +1,28 @@
+
+
+
+
+About
+
+
+About This Content
+
+June 5, 2007
+License
+
+The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available
+at http://www.eclipse.org/legal/epl-v10.html .
+For purposes of the EPL, "Program" will mean the Content.
+
+If you did not receive this Content directly from the Eclipse Foundation, the Content is
+being redistributed by another party ("Redistributor") and different terms and conditions may
+apply to your use of any object code in the Content. Check the Redistributor's license that was
+provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at http://www.eclipse.org .
+
+
+
\ No newline at end of file
diff --git a/examples/org.eclipse.emf.examples.library.edit/build.properties b/examples/org.eclipse.emf.examples.library.edit/build.properties
new file mode 100644
index 000000000..ca45351e6
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/build.properties
@@ -0,0 +1,9 @@
+bin.includes = icons/,\
+ .,\
+ META-INF/,\
+ plugin.xml,\
+ plugin.properties,\
+ about.html
+source.. = src/
+output.. = bin/
+src.includes = about.html
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_borrowers_Borrower.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_borrowers_Borrower.gif
new file mode 100644
index 000000000..6b4e4321e
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_borrowers_Borrower.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_branches_Library.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_branches_Library.gif
new file mode 100644
index 000000000..883ce93b4
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_branches_Library.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_employees_Employee.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_employees_Employee.gif
new file mode 100644
index 000000000..5b7808087
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_employees_Employee.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_Book.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_Book.gif
new file mode 100644
index 000000000..9073955a8
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_Book.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_BookOnTape.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_BookOnTape.gif
new file mode 100644
index 000000000..5d5000a7f
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_BookOnTape.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_VideoCassette.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_VideoCassette.gif
new file mode 100644
index 000000000..cca8aec82
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_stock_VideoCassette.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_writers_Writer.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_writers_Writer.gif
new file mode 100644
index 000000000..564bdbd77
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/ctool16/CreateLibrary_writers_Writer.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Book.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Book.gif
new file mode 100644
index 000000000..c3370c7dd
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Book.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/BookOnTape.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/BookOnTape.gif
new file mode 100644
index 000000000..cb1755a71
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/BookOnTape.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Borrower.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Borrower.gif
new file mode 100644
index 000000000..10d222998
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Borrower.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/CirculatingItem.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/CirculatingItem.gif
new file mode 100644
index 000000000..c3370c7dd
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/CirculatingItem.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Employee.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Employee.gif
new file mode 100644
index 000000000..1e5345fb3
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Employee.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Library.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Library.gif
new file mode 100644
index 000000000..739ebbfa6
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Library.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Person.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Person.gif
new file mode 100644
index 000000000..ea58a657d
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Person.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/VideoCassette.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/VideoCassette.gif
new file mode 100644
index 000000000..9250fecbf
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/VideoCassette.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Writer.gif b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Writer.gif
new file mode 100644
index 000000000..ef56c1408
Binary files /dev/null and b/examples/org.eclipse.emf.examples.library.edit/icons/full/obj16/Writer.gif differ
diff --git a/examples/org.eclipse.emf.examples.library.edit/plugin.properties b/examples/org.eclipse.emf.examples.library.edit/plugin.properties
new file mode 100644
index 000000000..e0c1c64d0
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/plugin.properties
@@ -0,0 +1,79 @@
+# /**
+# * Copyright (c) 2002-2008 IBM Corporation and others.
+# * All rights reserved. This program and the accompanying materials
+# * are made available under the terms of the Eclipse Public License v1.0
+# * which accompanies this distribution, and is available at
+# * http://www.eclipse.org/legal/epl-v10.html
+# *
+# * Contributors:
+# * IBM - Initial API and implementation
+# */
+
+# NLS_MESSAGEFORMAT_VAR
+
+pluginName = EMF Extended Library Edit Example
+providerName = Eclipse Modeling Project
+
+_UI_CreateChild_text = {0}
+_UI_CreateChild_text2 = {1} {0}
+_UI_CreateChild_text3 = {1}
+_UI_CreateChild_tooltip = Create New {0} Under {1} Feature
+_UI_CreateChild_description = Create a new child of type {0} for the {1} feature of the selected {2}.
+_UI_CreateSibling_description = Create a new sibling of type {0} for the selected {2}, under the {1} feature of their parent.
+
+_UI_PropertyDescriptor_description = The {0} of the {1}
+
+_UI_Book_type = Book
+_UI_Library_type = Library
+_UI_Writer_type = Writer
+_UI_Item_type = Item
+_UI_Lendable_type = Lendable
+_UI_CirculatingItem_type = Circulating Item
+_UI_Periodical_type = Periodical
+_UI_AudioVisualItem_type = Audio Visual Item
+_UI_BookOnTape_type = Book On Tape
+_UI_VideoCassette_type = Video Cassette
+_UI_Borrower_type = Borrower
+_UI_Person_type = Person
+_UI_Employee_type = Employee
+_UI_Addressable_type = Addressable
+_UI_Unknown_type = Object
+
+_UI_Unknown_datatype= Value
+
+_UI_Book_title_feature = Title
+_UI_Book_pages_feature = Pages
+_UI_Book_category_feature = Category
+_UI_Book_author_feature = Author
+_UI_Library_name_feature = Name
+_UI_Library_writers_feature = Writers
+_UI_Library_employees_feature = Employees
+_UI_Library_borrowers_feature = Borrowers
+_UI_Library_stock_feature = Stock
+_UI_Library_books_feature = Books
+_UI_Library_branches_feature = Branches
+_UI_Library_parentBranch_feature = Parent Branch
+_UI_Library_people_feature = People
+_UI_Writer_name_feature = Name
+_UI_Writer_books_feature = Books
+_UI_Item_publicationDate_feature = Publication Date
+_UI_Lendable_copies_feature = Copies
+_UI_Lendable_borrowers_feature = Borrowers
+_UI_Periodical_title_feature = Title
+_UI_Periodical_issuesPerYear_feature = Issues Per Year
+_UI_AudioVisualItem_title_feature = Title
+_UI_AudioVisualItem_minutesLength_feature = Minutes Length
+_UI_AudioVisualItem_damaged_feature = Damaged
+_UI_BookOnTape_reader_feature = Reader
+_UI_BookOnTape_author_feature = Author
+_UI_VideoCassette_cast_feature = Cast
+_UI_Borrower_borrowed_feature = Borrowed
+_UI_Person_firstName_feature = First Name
+_UI_Person_lastName_feature = Last Name
+_UI_Employee_manager_feature = Manager
+_UI_Addressable_address_feature = Address
+_UI_Unknown_feature = Unspecified
+
+_UI_BookCategory_Mystery_literal = Mystery
+_UI_BookCategory_ScienceFiction_literal = ScienceFiction
+_UI_BookCategory_Biography_literal = Biography
diff --git a/examples/org.eclipse.emf.examples.library.edit/plugin.xml b/examples/org.eclipse.emf.examples.library.edit/plugin.xml
new file mode 100644
index 000000000..1fdd258c0
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/plugin.xml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/AudioVisualItemItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/AudioVisualItemItemProvider.java
new file mode 100644
index 000000000..e31420af3
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/AudioVisualItemItemProvider.java
@@ -0,0 +1,199 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+
+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.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+import org.eclipse.emf.edit.provider.ItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.ViewerNotification;
+
+import org.eclipse.emf.examples.extlibrary.AudioVisualItem;
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.AudioVisualItem} object.
+ *
+ *
+ * @generated
+ */
+public class AudioVisualItemItemProvider
+ extends CirculatingItemItemProvider
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public AudioVisualItemItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addTitlePropertyDescriptor(object);
+ addMinutesLengthPropertyDescriptor(object);
+ addDamagedPropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Title feature.
+ *
+ *
+ * @generated
+ */
+ protected void addTitlePropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_AudioVisualItem_title_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_AudioVisualItem_title_feature", "_UI_AudioVisualItem_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.AUDIO_VISUAL_ITEM__TITLE,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Minutes Length feature.
+ *
+ *
+ * @generated
+ */
+ protected void addMinutesLengthPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_AudioVisualItem_minutesLength_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_AudioVisualItem_minutesLength_feature", "_UI_AudioVisualItem_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.AUDIO_VISUAL_ITEM__MINUTES_LENGTH,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Damaged feature.
+ *
+ *
+ * @generated
+ */
+ protected void addDamagedPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_AudioVisualItem_damaged_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_AudioVisualItem_damaged_feature", "_UI_AudioVisualItem_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.AUDIO_VISUAL_ITEM__DAMAGED,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ String label = ((AudioVisualItem)object).getTitle();
+ return label == null || label.length() == 0 ?
+ getString("_UI_AudioVisualItem_type") : //$NON-NLS-1$
+ getString("_UI_AudioVisualItem_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+
+ switch (notification.getFeatureID(AudioVisualItem.class))
+ {
+ case EXTLibraryPackage.AUDIO_VISUAL_ITEM__TITLE:
+ case EXTLibraryPackage.AUDIO_VISUAL_ITEM__MINUTES_LENGTH:
+ case EXTLibraryPackage.AUDIO_VISUAL_ITEM__DAMAGED:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ }
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BookItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BookItemProvider.java
new file mode 100644
index 000000000..e5962f3e6
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BookItemProvider.java
@@ -0,0 +1,235 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+
+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.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+import org.eclipse.emf.edit.provider.ItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.ViewerNotification;
+
+import org.eclipse.emf.examples.extlibrary.Book;
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.Book} object.
+ *
+ *
+ * @generated
+ */
+public class BookItemProvider
+ extends CirculatingItemItemProvider
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public BookItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addTitlePropertyDescriptor(object);
+ addPagesPropertyDescriptor(object);
+ addCategoryPropertyDescriptor(object);
+ addAuthorPropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Title feature.
+ *
+ *
+ * @generated
+ */
+ protected void addTitlePropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Book_title_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Book_title_feature", "_UI_Book_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.BOOK__TITLE,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Pages feature.
+ *
+ *
+ * @generated
+ */
+ protected void addPagesPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Book_pages_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Book_pages_feature", "_UI_Book_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.BOOK__PAGES,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Category feature.
+ *
+ *
+ * @generated
+ */
+ protected void addCategoryPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Book_category_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Book_category_feature", "_UI_Book_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.BOOK__CATEGORY,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Author feature.
+ *
+ *
+ * @generated
+ */
+ protected void addAuthorPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Book_author_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Book_author_feature", "_UI_Book_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.BOOK__AUTHOR,
+ true,
+ false,
+ false,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This returns Book.gif.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object getImage(Object object)
+ {
+ return overlayImage(object, getResourceLocator().getImage("full/obj16/Book")); //$NON-NLS-1$
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ String label = ((Book)object).getTitle();
+ return label == null || label.length() == 0 ?
+ getString("_UI_Book_type") : //$NON-NLS-1$
+ getString("_UI_Book_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+
+ switch (notification.getFeatureID(Book.class))
+ {
+ case EXTLibraryPackage.BOOK__TITLE:
+ case EXTLibraryPackage.BOOK__PAGES:
+ case EXTLibraryPackage.BOOK__CATEGORY:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ }
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BookOnTapeItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BookOnTapeItemProvider.java
new file mode 100644
index 000000000..2f4a2824d
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BookOnTapeItemProvider.java
@@ -0,0 +1,176 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+
+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.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+
+import org.eclipse.emf.examples.extlibrary.BookOnTape;
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.BookOnTape} object.
+ *
+ *
+ * @generated
+ */
+public class BookOnTapeItemProvider
+ extends AudioVisualItemItemProvider
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public BookOnTapeItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addReaderPropertyDescriptor(object);
+ addAuthorPropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Reader feature.
+ *
+ *
+ * @generated
+ */
+ protected void addReaderPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_BookOnTape_reader_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_BookOnTape_reader_feature", "_UI_BookOnTape_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.BOOK_ON_TAPE__READER,
+ true,
+ false,
+ false,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Author feature.
+ *
+ *
+ * @generated
+ */
+ protected void addAuthorPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_BookOnTape_author_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_BookOnTape_author_feature", "_UI_BookOnTape_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.BOOK_ON_TAPE__AUTHOR,
+ true,
+ false,
+ false,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This returns BookOnTape.gif.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object getImage(Object object)
+ {
+ return overlayImage(object, getResourceLocator().getImage("full/obj16/BookOnTape")); //$NON-NLS-1$
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ String label = ((BookOnTape)object).getTitle();
+ return label == null || label.length() == 0 ?
+ getString("_UI_BookOnTape_type") : //$NON-NLS-1$
+ getString("_UI_BookOnTape_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BorrowerItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BorrowerItemProvider.java
new file mode 100644
index 000000000..4eaad6e79
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/BorrowerItemProvider.java
@@ -0,0 +1,152 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+
+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.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+
+import org.eclipse.emf.examples.extlibrary.Borrower;
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.Borrower} object.
+ *
+ *
+ * @generated
+ */
+public class BorrowerItemProvider
+ extends PersonItemProvider
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public BorrowerItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addBorrowedPropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Borrowed feature.
+ *
+ *
+ * @generated
+ */
+ protected void addBorrowedPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Borrower_borrowed_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Borrower_borrowed_feature", "_UI_Borrower_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.BORROWER__BORROWED,
+ true,
+ false,
+ false,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This returns Borrower.gif.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object getImage(Object object)
+ {
+ return overlayImage(object, getResourceLocator().getImage("full/obj16/Borrower")); //$NON-NLS-1$
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ String label = ((Borrower)object).getLastName();
+ return label == null || label.length() == 0 ?
+ getString("_UI_Borrower_type") : //$NON-NLS-1$
+ getString("_UI_Borrower_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/CirculatingItemItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/CirculatingItemItemProvider.java
new file mode 100644
index 000000000..d607ac702
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/CirculatingItemItemProvider.java
@@ -0,0 +1,187 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.Date;
+import java.util.List;
+
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+
+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.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+import org.eclipse.emf.edit.provider.ItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.ViewerNotification;
+
+import org.eclipse.emf.examples.extlibrary.CirculatingItem;
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.CirculatingItem} object.
+ *
+ *
+ * @generated
+ */
+public class CirculatingItemItemProvider
+ extends ItemItemProvider
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public CirculatingItemItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addCopiesPropertyDescriptor(object);
+ addBorrowersPropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Copies feature.
+ *
+ *
+ * @generated
+ */
+ protected void addCopiesPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Lendable_copies_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Lendable_copies_feature", "_UI_Lendable_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.LENDABLE__COPIES,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Borrowers feature.
+ *
+ *
+ * @generated
+ */
+ protected void addBorrowersPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Lendable_borrowers_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Lendable_borrowers_feature", "_UI_Lendable_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.LENDABLE__BORROWERS,
+ true,
+ false,
+ false,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This returns CirculatingItem.gif.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object getImage(Object object)
+ {
+ return overlayImage(object, getResourceLocator().getImage("full/obj16/CirculatingItem")); //$NON-NLS-1$
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ Date labelValue = ((CirculatingItem)object).getPublicationDate();
+ String label = labelValue == null ? null : labelValue.toString();
+ return label == null || label.length() == 0 ?
+ getString("_UI_CirculatingItem_type") : //$NON-NLS-1$
+ getString("_UI_CirculatingItem_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+
+ switch (notification.getFeatureID(CirculatingItem.class))
+ {
+ case EXTLibraryPackage.CIRCULATING_ITEM__COPIES:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ }
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EXTLibraryEditPlugin.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EXTLibraryEditPlugin.java
new file mode 100644
index 000000000..55669ff0b
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EXTLibraryEditPlugin.java
@@ -0,0 +1,104 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+import org.eclipse.emf.common.EMFPlugin;
+
+import org.eclipse.emf.common.util.ResourceLocator;
+
+/**
+ * This is the central singleton for the EXTLibrary edit plugin.
+ *
+ *
+ * @generated
+ */
+public final class EXTLibraryEditPlugin extends EMFPlugin
+{
+ /**
+ * Keep track of the singleton.
+ *
+ *
+ * @generated
+ */
+ public static final EXTLibraryEditPlugin INSTANCE = new EXTLibraryEditPlugin();
+
+ /**
+ * Keep track of the singleton.
+ *
+ *
+ * @generated
+ */
+ private static Implementation plugin;
+
+ /**
+ * Create the instance.
+ *
+ *
+ * @generated
+ */
+ public EXTLibraryEditPlugin()
+ {
+ super
+ (new ResourceLocator []
+ {
+ });
+ }
+
+ /**
+ * Returns the singleton instance of the Eclipse plugin.
+ *
+ *
+ * @return the singleton instance.
+ * @generated
+ */
+ @Override
+ public ResourceLocator getPluginResourceLocator()
+ {
+ return plugin;
+ }
+
+ /**
+ * Returns the singleton instance of the Eclipse plugin.
+ *
+ *
+ * @return the singleton instance.
+ * @generated
+ */
+ public static Implementation getPlugin()
+ {
+ return plugin;
+ }
+
+ /**
+ * The actual implementation of the Eclipse Plugin .
+ *
+ *
+ * @generated
+ */
+ public static class Implementation extends EclipsePlugin
+ {
+ /**
+ * Creates an instance.
+ *
+ *
+ * @generated
+ */
+ public Implementation()
+ {
+ super();
+
+ // Remember the static instance.
+ //
+ plugin = this;
+ }
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EXTLibraryItemProviderAdapterFactory.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EXTLibraryItemProviderAdapterFactory.java
new file mode 100644
index 000000000..b69e90a78
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EXTLibraryItemProviderAdapterFactory.java
@@ -0,0 +1,405 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+import java.util.ArrayList;
+import java.util.Collection;
+
+import org.eclipse.emf.common.notify.Adapter;
+import org.eclipse.emf.common.notify.Notification;
+import org.eclipse.emf.common.notify.Notifier;
+
+import org.eclipse.emf.edit.provider.ChangeNotifier;
+import org.eclipse.emf.edit.provider.ComposeableAdapterFactory;
+import org.eclipse.emf.edit.provider.ComposedAdapterFactory;
+import org.eclipse.emf.edit.provider.IChangeNotifier;
+import org.eclipse.emf.edit.provider.IDisposable;
+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.INotifyChangedListener;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+
+import org.eclipse.emf.examples.extlibrary.util.EXTLibraryAdapterFactory;
+
+/**
+ * This is the factory that is used to provide the interfaces needed to support Viewers.
+ * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}.
+ * The adapters also support Eclipse property sheets.
+ * Note that most of the adapters are shared among multiple instances.
+ *
+ *
+ * @generated
+ */
+public class EXTLibraryItemProviderAdapterFactory extends EXTLibraryAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable
+{
+ /**
+ * This keeps track of the root adapter factory that delegates to this adapter factory.
+ *
+ *
+ * @generated
+ */
+ protected ComposedAdapterFactory parentAdapterFactory;
+
+ /**
+ * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}.
+ *
+ *
+ * @generated
+ */
+ protected IChangeNotifier changeNotifier = new ChangeNotifier();
+
+ /**
+ * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}.
+ *
+ *
+ * @generated
+ */
+ protected Collection supportedTypes = new ArrayList();
+
+ /**
+ * This constructs an instance.
+ *
+ *
+ * @generated
+ */
+ public EXTLibraryItemProviderAdapterFactory()
+ {
+ supportedTypes.add(IEditingDomainItemProvider.class);
+ supportedTypes.add(IStructuredItemContentProvider.class);
+ supportedTypes.add(ITreeItemContentProvider.class);
+ supportedTypes.add(IItemLabelProvider.class);
+ supportedTypes.add(IItemPropertySource.class);
+ }
+
+ /**
+ * This keeps track of the one adapter used for all {@link org.eclipse.emf.examples.extlibrary.Book} instances.
+ *
+ *
+ * @generated
+ */
+ protected BookItemProvider bookItemProvider;
+
+ /**
+ * This creates an adapter for a {@link org.eclipse.emf.examples.extlibrary.Book}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Adapter createBookAdapter()
+ {
+ if (bookItemProvider == null)
+ {
+ bookItemProvider = new BookItemProvider(this);
+ }
+
+ return bookItemProvider;
+ }
+
+ /**
+ * This keeps track of the one adapter used for all {@link org.eclipse.emf.examples.extlibrary.Library} instances.
+ *
+ *
+ * @generated
+ */
+ protected LibraryItemProvider libraryItemProvider;
+
+ /**
+ * This creates an adapter for a {@link org.eclipse.emf.examples.extlibrary.Library}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Adapter createLibraryAdapter()
+ {
+ if (libraryItemProvider == null)
+ {
+ libraryItemProvider = new LibraryItemProvider(this);
+ }
+
+ return libraryItemProvider;
+ }
+
+ /**
+ * This keeps track of the one adapter used for all {@link org.eclipse.emf.examples.extlibrary.Writer} instances.
+ *
+ *
+ * @generated
+ */
+ protected WriterItemProvider writerItemProvider;
+
+ /**
+ * This creates an adapter for a {@link org.eclipse.emf.examples.extlibrary.Writer}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Adapter createWriterAdapter()
+ {
+ if (writerItemProvider == null)
+ {
+ writerItemProvider = new WriterItemProvider(this);
+ }
+
+ return writerItemProvider;
+ }
+
+ /**
+ * This keeps track of the one adapter used for all {@link org.eclipse.emf.examples.extlibrary.BookOnTape} instances.
+ *
+ *
+ * @generated
+ */
+ protected BookOnTapeItemProvider bookOnTapeItemProvider;
+
+ /**
+ * This creates an adapter for a {@link org.eclipse.emf.examples.extlibrary.BookOnTape}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Adapter createBookOnTapeAdapter()
+ {
+ if (bookOnTapeItemProvider == null)
+ {
+ bookOnTapeItemProvider = new BookOnTapeItemProvider(this);
+ }
+
+ return bookOnTapeItemProvider;
+ }
+
+ /**
+ * This keeps track of the one adapter used for all {@link org.eclipse.emf.examples.extlibrary.VideoCassette} instances.
+ *
+ *
+ * @generated
+ */
+ protected VideoCassetteItemProvider videoCassetteItemProvider;
+
+ /**
+ * This creates an adapter for a {@link org.eclipse.emf.examples.extlibrary.VideoCassette}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Adapter createVideoCassetteAdapter()
+ {
+ if (videoCassetteItemProvider == null)
+ {
+ videoCassetteItemProvider = new VideoCassetteItemProvider(this);
+ }
+
+ return videoCassetteItemProvider;
+ }
+
+ /**
+ * This keeps track of the one adapter used for all {@link org.eclipse.emf.examples.extlibrary.Borrower} instances.
+ *
+ *
+ * @generated
+ */
+ protected BorrowerItemProvider borrowerItemProvider;
+
+ /**
+ * This creates an adapter for a {@link org.eclipse.emf.examples.extlibrary.Borrower}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Adapter createBorrowerAdapter()
+ {
+ if (borrowerItemProvider == null)
+ {
+ borrowerItemProvider = new BorrowerItemProvider(this);
+ }
+
+ return borrowerItemProvider;
+ }
+
+ /**
+ * This keeps track of the one adapter used for all {@link org.eclipse.emf.examples.extlibrary.Person} instances.
+ *
+ *
+ * @generated
+ */
+ protected PersonItemProvider personItemProvider;
+
+ /**
+ * This creates an adapter for a {@link org.eclipse.emf.examples.extlibrary.Person}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Adapter createPersonAdapter()
+ {
+ if (personItemProvider == null)
+ {
+ personItemProvider = new PersonItemProvider(this);
+ }
+
+ return personItemProvider;
+ }
+
+ /**
+ * This keeps track of the one adapter used for all {@link org.eclipse.emf.examples.extlibrary.Employee} instances.
+ *
+ *
+ * @generated
+ */
+ protected EmployeeItemProvider employeeItemProvider;
+
+ /**
+ * This creates an adapter for a {@link org.eclipse.emf.examples.extlibrary.Employee}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Adapter createEmployeeAdapter()
+ {
+ if (employeeItemProvider == null)
+ {
+ employeeItemProvider = new EmployeeItemProvider(this);
+ }
+
+ return employeeItemProvider;
+ }
+
+ /**
+ * This returns the root adapter factory that contains this factory.
+ *
+ *
+ * @generated
+ */
+ public ComposeableAdapterFactory getRootAdapterFactory()
+ {
+ return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory();
+ }
+
+ /**
+ * This sets the composed adapter factory that contains this factory.
+ *
+ *
+ * @generated
+ */
+ public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory)
+ {
+ this.parentAdapterFactory = parentAdapterFactory;
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ @Override
+ public boolean isFactoryForType(Object type)
+ {
+ return supportedTypes.contains(type) || super.isFactoryForType(type);
+ }
+
+ /**
+ * This implementation substitutes the factory itself as the key for the adapter.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Adapter adapt(Notifier notifier, Object type)
+ {
+ return super.adapt(notifier, this);
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object adapt(Object object, Object type)
+ {
+ if (isFactoryForType(type))
+ {
+ Object adapter = super.adapt(object, type);
+ if (!(type instanceof Class>) || (((Class>)type).isInstance(adapter)))
+ {
+ return adapter;
+ }
+ }
+
+ return null;
+ }
+
+ /**
+ * This adds a listener.
+ *
+ *
+ * @generated
+ */
+ public void addListener(INotifyChangedListener notifyChangedListener)
+ {
+ changeNotifier.addListener(notifyChangedListener);
+ }
+
+ /**
+ * This removes a listener.
+ *
+ *
+ * @generated
+ */
+ public void removeListener(INotifyChangedListener notifyChangedListener)
+ {
+ changeNotifier.removeListener(notifyChangedListener);
+ }
+
+ /**
+ * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}.
+ *
+ *
+ * @generated
+ */
+ public void fireNotifyChanged(Notification notification)
+ {
+ changeNotifier.fireNotifyChanged(notification);
+
+ if (parentAdapterFactory != null)
+ {
+ parentAdapterFactory.fireNotifyChanged(notification);
+ }
+ }
+
+ /**
+ * This disposes all of the item providers created by this factory.
+ *
+ *
+ * @generated
+ */
+ public void dispose()
+ {
+ if (bookItemProvider != null) bookItemProvider.dispose();
+ if (libraryItemProvider != null) libraryItemProvider.dispose();
+ if (writerItemProvider != null) writerItemProvider.dispose();
+ if (bookOnTapeItemProvider != null) bookOnTapeItemProvider.dispose();
+ if (videoCassetteItemProvider != null) videoCassetteItemProvider.dispose();
+ if (borrowerItemProvider != null) borrowerItemProvider.dispose();
+ if (personItemProvider != null) personItemProvider.dispose();
+ if (employeeItemProvider != null) employeeItemProvider.dispose();
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EmployeeItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EmployeeItemProvider.java
new file mode 100644
index 000000000..5c4e17a7b
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/EmployeeItemProvider.java
@@ -0,0 +1,152 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+
+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.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+import org.eclipse.emf.examples.extlibrary.Employee;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.Employee} object.
+ *
+ *
+ * @generated
+ */
+public class EmployeeItemProvider
+ extends PersonItemProvider
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public EmployeeItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addManagerPropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Manager feature.
+ *
+ *
+ * @generated
+ */
+ protected void addManagerPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Employee_manager_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Employee_manager_feature", "_UI_Employee_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.EMPLOYEE__MANAGER,
+ true,
+ false,
+ false,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This returns Employee.gif.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object getImage(Object object)
+ {
+ return overlayImage(object, getResourceLocator().getImage("full/obj16/Employee")); //$NON-NLS-1$
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ String label = ((Employee)object).getLastName();
+ return label == null || label.length() == 0 ?
+ getString("_UI_Employee_type") : //$NON-NLS-1$
+ getString("_UI_Employee_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/ItemItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/ItemItemProvider.java
new file mode 100644
index 000000000..87fdf8543
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/ItemItemProvider.java
@@ -0,0 +1,166 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.Date;
+import java.util.List;
+
+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.edit.provider.ComposeableAdapterFactory;
+import org.eclipse.emf.edit.provider.IEditingDomainItemProvider;
+import org.eclipse.emf.edit.provider.IItemLabelProvider;
+import org.eclipse.emf.edit.provider.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+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;
+
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+import org.eclipse.emf.examples.extlibrary.Item;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.Item} object.
+ *
+ *
+ * @generated
+ */
+public class ItemItemProvider
+ extends ItemProviderAdapter
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public ItemItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addPublicationDatePropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Publication Date feature.
+ *
+ *
+ * @generated
+ */
+ protected void addPublicationDatePropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Item_publicationDate_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Item_publicationDate_feature", "_UI_Item_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.ITEM__PUBLICATION_DATE,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ Date labelValue = ((Item)object).getPublicationDate();
+ String label = labelValue == null ? null : labelValue.toString();
+ return label == null || label.length() == 0 ?
+ getString("_UI_Item_type") : //$NON-NLS-1$
+ getString("_UI_Item_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+
+ switch (notification.getFeatureID(Item.class))
+ {
+ case EXTLibraryPackage.ITEM__PUBLICATION_DATE:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ }
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+ /**
+ * Return the resource locator for this item provider's resources.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public ResourceLocator getResourceLocator()
+ {
+ return EXTLibraryEditPlugin.INSTANCE;
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/LibraryItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/LibraryItemProvider.java
new file mode 100644
index 000000000..0b3267e73
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/LibraryItemProvider.java
@@ -0,0 +1,307 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.List;
+
+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.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+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;
+
+import org.eclipse.emf.examples.extlibrary.EXTLibraryFactory;
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+import org.eclipse.emf.examples.extlibrary.Library;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.Library} object.
+ *
+ *
+ * @generated
+ */
+public class LibraryItemProvider
+ extends ItemProviderAdapter
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public LibraryItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addAddressPropertyDescriptor(object);
+ addNamePropertyDescriptor(object);
+ addBooksPropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Address feature.
+ *
+ *
+ * @generated
+ */
+ protected void addAddressPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Addressable_address_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Addressable_address_feature", "_UI_Addressable_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.ADDRESSABLE__ADDRESS,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Name feature.
+ *
+ *
+ * @generated
+ */
+ protected void addNamePropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Library_name_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Library_name_feature", "_UI_Library_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.LIBRARY__NAME,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Books feature.
+ *
+ *
+ * @generated
+ */
+ protected void addBooksPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Library_books_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Library_books_feature", "_UI_Library_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.LIBRARY__BOOKS,
+ false,
+ false,
+ false,
+ null,
+ 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Collection extends EStructuralFeature> getChildrenFeatures(Object object)
+ {
+ if (childrenFeatures == null)
+ {
+ super.getChildrenFeatures(object);
+ childrenFeatures.add(EXTLibraryPackage.Literals.LIBRARY__WRITERS);
+ childrenFeatures.add(EXTLibraryPackage.Literals.LIBRARY__EMPLOYEES);
+ childrenFeatures.add(EXTLibraryPackage.Literals.LIBRARY__BORROWERS);
+ childrenFeatures.add(EXTLibraryPackage.Literals.LIBRARY__STOCK);
+ childrenFeatures.add(EXTLibraryPackage.Literals.LIBRARY__BRANCHES);
+ }
+ return childrenFeatures;
+ }
+
+ /**
+ *
+ *
+ * @generated
+ */
+ @Override
+ 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 Library.gif.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object getImage(Object object)
+ {
+ return overlayImage(object, getResourceLocator().getImage("full/obj16/Library")); //$NON-NLS-1$
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ String label = ((Library)object).getName();
+ return label == null || label.length() == 0 ?
+ getString("_UI_Library_type") : //$NON-NLS-1$
+ getString("_UI_Library_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+
+ switch (notification.getFeatureID(Library.class))
+ {
+ case EXTLibraryPackage.LIBRARY__ADDRESS:
+ case EXTLibraryPackage.LIBRARY__NAME:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ case EXTLibraryPackage.LIBRARY__WRITERS:
+ case EXTLibraryPackage.LIBRARY__EMPLOYEES:
+ case EXTLibraryPackage.LIBRARY__BORROWERS:
+ case EXTLibraryPackage.LIBRARY__STOCK:
+ case EXTLibraryPackage.LIBRARY__BRANCHES:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
+ }
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+
+ newChildDescriptors.add
+ (createChildParameter
+ (EXTLibraryPackage.Literals.LIBRARY__WRITERS,
+ EXTLibraryFactory.eINSTANCE.createWriter()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (EXTLibraryPackage.Literals.LIBRARY__EMPLOYEES,
+ EXTLibraryFactory.eINSTANCE.createEmployee()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (EXTLibraryPackage.Literals.LIBRARY__BORROWERS,
+ EXTLibraryFactory.eINSTANCE.createBorrower()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (EXTLibraryPackage.Literals.LIBRARY__STOCK,
+ EXTLibraryFactory.eINSTANCE.createBook()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (EXTLibraryPackage.Literals.LIBRARY__STOCK,
+ EXTLibraryFactory.eINSTANCE.createBookOnTape()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (EXTLibraryPackage.Literals.LIBRARY__STOCK,
+ EXTLibraryFactory.eINSTANCE.createVideoCassette()));
+
+ newChildDescriptors.add
+ (createChildParameter
+ (EXTLibraryPackage.Literals.LIBRARY__BRANCHES,
+ EXTLibraryFactory.eINSTANCE.createLibrary()));
+ }
+
+ /**
+ * Return the resource locator for this item provider's resources.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public ResourceLocator getResourceLocator()
+ {
+ return EXTLibraryEditPlugin.INSTANCE;
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/PeriodicalItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/PeriodicalItemProvider.java
new file mode 100644
index 000000000..065b27e46
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/PeriodicalItemProvider.java
@@ -0,0 +1,174 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+
+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.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+import org.eclipse.emf.edit.provider.ItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.ViewerNotification;
+
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+import org.eclipse.emf.examples.extlibrary.Periodical;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.Periodical} object.
+ *
+ *
+ * @generated
+ */
+public class PeriodicalItemProvider
+ extends ItemItemProvider
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public PeriodicalItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addTitlePropertyDescriptor(object);
+ addIssuesPerYearPropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Title feature.
+ *
+ *
+ * @generated
+ */
+ protected void addTitlePropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Periodical_title_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Periodical_title_feature", "_UI_Periodical_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.PERIODICAL__TITLE,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Issues Per Year feature.
+ *
+ *
+ * @generated
+ */
+ protected void addIssuesPerYearPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Periodical_issuesPerYear_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Periodical_issuesPerYear_feature", "_UI_Periodical_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.PERIODICAL__ISSUES_PER_YEAR,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ String label = ((Periodical)object).getTitle();
+ return label == null || label.length() == 0 ?
+ getString("_UI_Periodical_type") : //$NON-NLS-1$
+ getString("_UI_Periodical_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+
+ switch (notification.getFeatureID(Periodical.class))
+ {
+ case EXTLibraryPackage.PERIODICAL__TITLE:
+ case EXTLibraryPackage.PERIODICAL__ISSUES_PER_YEAR:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ }
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/PersonItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/PersonItemProvider.java
new file mode 100644
index 000000000..9bb8d8a2a
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/PersonItemProvider.java
@@ -0,0 +1,226 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.List;
+
+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.edit.provider.ComposeableAdapterFactory;
+import org.eclipse.emf.edit.provider.IEditingDomainItemProvider;
+import org.eclipse.emf.edit.provider.IItemLabelProvider;
+import org.eclipse.emf.edit.provider.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+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;
+
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+import org.eclipse.emf.examples.extlibrary.Person;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.Person} object.
+ *
+ *
+ * @generated
+ */
+public class PersonItemProvider
+ extends ItemProviderAdapter
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public PersonItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addAddressPropertyDescriptor(object);
+ addFirstNamePropertyDescriptor(object);
+ addLastNamePropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Address feature.
+ *
+ *
+ * @generated
+ */
+ protected void addAddressPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Addressable_address_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Addressable_address_feature", "_UI_Addressable_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.ADDRESSABLE__ADDRESS,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the First Name feature.
+ *
+ *
+ * @generated
+ */
+ protected void addFirstNamePropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Person_firstName_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Person_firstName_feature", "_UI_Person_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.PERSON__FIRST_NAME,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Last Name feature.
+ *
+ *
+ * @generated
+ */
+ protected void addLastNamePropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Person_lastName_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Person_lastName_feature", "_UI_Person_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.PERSON__LAST_NAME,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This returns Person.gif.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object getImage(Object object)
+ {
+ return overlayImage(object, getResourceLocator().getImage("full/obj16/Person")); //$NON-NLS-1$
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ String label = ((Person)object).getLastName();
+ return label == null || label.length() == 0 ?
+ getString("_UI_Person_type") : //$NON-NLS-1$
+ getString("_UI_Person_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+
+ switch (notification.getFeatureID(Person.class))
+ {
+ case EXTLibraryPackage.PERSON__ADDRESS:
+ case EXTLibraryPackage.PERSON__FIRST_NAME:
+ case EXTLibraryPackage.PERSON__LAST_NAME:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ }
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+ /**
+ * Return the resource locator for this item provider's resources.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public ResourceLocator getResourceLocator()
+ {
+ return EXTLibraryEditPlugin.INSTANCE;
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/VideoCassetteItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/VideoCassetteItemProvider.java
new file mode 100644
index 000000000..f58af887f
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/VideoCassetteItemProvider.java
@@ -0,0 +1,152 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+
+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.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+import org.eclipse.emf.examples.extlibrary.VideoCassette;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.VideoCassette} object.
+ *
+ *
+ * @generated
+ */
+public class VideoCassetteItemProvider
+ extends AudioVisualItemItemProvider
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public VideoCassetteItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addCastPropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Cast feature.
+ *
+ *
+ * @generated
+ */
+ protected void addCastPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VideoCassette_cast_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_VideoCassette_cast_feature", "_UI_VideoCassette_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.VIDEO_CASSETTE__CAST,
+ true,
+ false,
+ false,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This returns VideoCassette.gif.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object getImage(Object object)
+ {
+ return overlayImage(object, getResourceLocator().getImage("full/obj16/VideoCassette")); //$NON-NLS-1$
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ String label = ((VideoCassette)object).getTitle();
+ return label == null || label.length() == 0 ?
+ getString("_UI_VideoCassette_type") : //$NON-NLS-1$
+ getString("_UI_VideoCassette_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+}
diff --git a/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/WriterItemProvider.java b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/WriterItemProvider.java
new file mode 100644
index 000000000..1de4e032c
--- /dev/null
+++ b/examples/org.eclipse.emf.examples.library.edit/src/org/eclipse/emf/examples/extlibrary/provider/WriterItemProvider.java
@@ -0,0 +1,185 @@
+/**
+ * Copyright (c) 2005-2006 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM - Initial API and implementation
+ */
+package org.eclipse.emf.examples.extlibrary.provider;
+
+
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.emf.common.notify.AdapterFactory;
+import org.eclipse.emf.common.notify.Notification;
+
+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.IItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
+import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
+import org.eclipse.emf.edit.provider.ItemPropertyDescriptor;
+import org.eclipse.emf.edit.provider.ViewerNotification;
+
+import org.eclipse.emf.examples.extlibrary.EXTLibraryPackage;
+import org.eclipse.emf.examples.extlibrary.Writer;
+
+/**
+ * This is the item provider adapter for a {@link org.eclipse.emf.examples.extlibrary.Writer} object.
+ *
+ *
+ * @generated
+ */
+public class WriterItemProvider
+ extends PersonItemProvider
+ implements
+ IEditingDomainItemProvider,
+ IStructuredItemContentProvider,
+ ITreeItemContentProvider,
+ IItemLabelProvider,
+ IItemPropertySource
+{
+ /**
+ * This constructs an instance from a factory and a notifier.
+ *
+ *
+ * @generated
+ */
+ public WriterItemProvider(AdapterFactory adapterFactory)
+ {
+ super(adapterFactory);
+ }
+
+ /**
+ * This returns the property descriptors for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public List getPropertyDescriptors(Object object)
+ {
+ if (itemPropertyDescriptors == null)
+ {
+ super.getPropertyDescriptors(object);
+
+ addNamePropertyDescriptor(object);
+ addBooksPropertyDescriptor(object);
+ }
+ return itemPropertyDescriptors;
+ }
+
+ /**
+ * This adds a property descriptor for the Name feature.
+ *
+ *
+ * @generated
+ */
+ protected void addNamePropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Writer_name_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Writer_name_feature", "_UI_Writer_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.WRITER__NAME,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
+ }
+
+ /**
+ * This adds a property descriptor for the Books feature.
+ *
+ *
+ * @generated
+ */
+ protected void addBooksPropertyDescriptor(Object object)
+ {
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Writer_books_feature"), //$NON-NLS-1$
+ getString("_UI_PropertyDescriptor_description", "_UI_Writer_books_feature", "_UI_Writer_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ EXTLibraryPackage.Literals.WRITER__BOOKS,
+ true,
+ false,
+ false,
+ null,
+ null,
+ null));
+ }
+
+ /**
+ * This returns Writer.gif.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public Object getImage(Object object)
+ {
+ return overlayImage(object, getResourceLocator().getImage("full/obj16/Writer")); //$NON-NLS-1$
+ }
+
+ /**
+ * This returns the label text for the adapted class.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public String getText(Object object)
+ {
+ String label = ((Writer)object).getName();
+ return label == null || label.length() == 0 ?
+ getString("_UI_Writer_type") : //$NON-NLS-1$
+ getString("_UI_Writer_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ /**
+ * 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}.
+ *
+ *
+ * @generated
+ */
+ @Override
+ public void notifyChanged(Notification notification)
+ {
+ updateChildren(notification);
+
+ switch (notification.getFeatureID(Writer.class))
+ {
+ case EXTLibraryPackage.WRITER__NAME:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ }
+ super.notifyChanged(notification);
+ }
+
+ /**
+ * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
+ * that can be created under this object.
+ *
+ *
+ * @generated
+ */
+ @Override
+ protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object)
+ {
+ super.collectNewChildDescriptors(newChildDescriptors, object);
+ }
+
+}
--
cgit v1.2.3