diff options
author | Ed Willink | 2016-05-30 22:06:58 +0000 |
---|---|---|
committer | Ed Willink | 2016-05-30 22:06:58 +0000 |
commit | 5d76ad54ec3fe5473b895729323a16e7b2db6f72 (patch) | |
tree | 95ae4a512c29c9c37c2f662d3d1a6f36a2e41b89 /examples | |
parent | 56699eba9c1795362f61a8ac90015168ccbc0715 (diff) | |
download | org.eclipse.qvtd-5d76ad54ec3fe5473b895729323a16e7b2db6f72.tar.gz org.eclipse.qvtd-5d76ad54ec3fe5473b895729323a16e7b2db6f72.tar.xz org.eclipse.qvtd-5d76ad54ec3fe5473b895729323a16e7b2db6f72.zip |
[486722] A working QVTc and QVTr example
Diffstat (limited to 'examples')
90 files changed, 17177 insertions, 69 deletions
diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/.settings/SimpleUML2RDBMS.qvtc.launch b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/.settings/SimpleUML2RDBMS.qvtc.launch index 1ae6b5335..c1c7ccc29 100644 --- a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/.settings/SimpleUML2RDBMS.qvtc.launch +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/.settings/SimpleUML2RDBMS.qvtc.launch @@ -5,23 +5,24 @@ <stringAttribute key="direction" value="rdbms"/>
<stringAttribute key="genmodel" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.genmodel"/>
<mapAttribute key="in">
-<mapEntry key="uml" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUMLPeople.xmi"/>
+<mapEntry key="uml" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/in/SimpleUMLPeople.xmi"/>
</mapAttribute>
<mapAttribute key="intermediates">
-<mapEntry key="QVTc" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvtcas"/>
-<mapEntry key="QVTi" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvtias"/>
-<mapEntry key="QVTm" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvtm.qvtcas"/>
-<mapEntry key="QVTp" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvtp.qvtcas"/>
-<mapEntry key="QVTs" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvts.xmi"/>
-<mapEntry key="QVTu" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvtu.qvtcas"/>
+<mapEntry key="QVTc" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/temp/SimpleUML2RDBMS.qvtcas"/>
+<mapEntry key="QVTi" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/temp/SimpleUML2RDBMS.qvtias"/>
+<mapEntry key="QVTm" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/temp/SimpleUML2RDBMS.qvtm.qvtcas"/>
+<mapEntry key="QVTp" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/temp/SimpleUML2RDBMS.qvtp.qvtcas"/>
+<mapEntry key="QVTs" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/temp/SimpleUML2RDBMS.qvts.xmi"/>
+<mapEntry key="QVTu" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/temp/SimpleUML2RDBMS.qvtu.qvtcas"/>
</mapAttribute>
<booleanAttribute key="interpreted" value="true"/>
<stringAttribute key="mode" value="ENFORCE - CREATE"/>
<mapAttribute key="old-in"/>
<mapAttribute key="old-out"/>
<mapAttribute key="out">
-<mapEntry key="rdbms" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleRDBMSPeople.xmi"/>
+<mapEntry key="rdbms" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/out/SimpleRDBMSPeople.xmi"/>
</mapAttribute>
+<stringAttribute key="project" value="org.eclipse.qvtd.examples.qvtcore.uml2rdbms"/>
<stringAttribute key="tx" value="platform:/resource/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvtc"/>
<booleanAttribute key="view" value="false"/>
</launchConfiguration>
diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/META-INF/MANIFEST.MF b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/META-INF/MANIFEST.MF index 83fd9e306..053eca09b 100644 --- a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/META-INF/MANIFEST.MF +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/META-INF/MANIFEST.MF @@ -7,4 +7,4 @@ Bundle-Vendor: %providerName Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Export-Package: org.eclipse.qvtd.examples.qvtcore.uml2rdbms -Require-Bundle: org.eclipse.emf.ecore +Require-Bundle: org.eclipse.qvtd.runtime diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/build.properties b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/build.properties index 7413ff641..75ea0377b 100644 --- a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/build.properties +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/build.properties @@ -14,6 +14,5 @@ output.. = bin/ bin.includes = META-INF/,\ .,\ plugin.properties,\ - about.html,\ - plugin.xml + about.html src.includes = about.html diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/plugin.xml b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/plugin.xml deleted file mode 100644 index 796f5a9fe..000000000 --- a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/plugin.xml +++ /dev/null @@ -1,38 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<?eclipse version="3.0"?> - -<!-- - Copyright (c) 2015, 2016 Willink Transformations 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: - E.D.Willink - Initial API and implementation ---> - -<plugin> - - <extension point="org.eclipse.emf.ecore.generated_package"> - <package - uri="http://www.eclipse.org/qvtd/examples/qvtcore/UML2RDBMS/1.0/SimpleUMLtoRDBMS" - class="org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage" - genModel="src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.genmodel"/> - </extension> - - <extension point="org.eclipse.emf.ecore.generated_package"> - <package - uri="http://www.eclipse.org/qvtd/examples/qvtcore/UML2RDBMS/1.0/simpleUML" - class="org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage" - genModel="src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.genmodel"/> - </extension> - - <extension point="org.eclipse.emf.ecore.generated_package"> - <package - uri="http://www.eclipse.org/qvtd/examples/qvtcore/UML2RDBMS/1.0/SimpleRDBMS" - class="org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage" - genModel="src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.genmodel"/> - </extension> - -</plugin> diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/.gitignore b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/.gitignore deleted file mode 100644 index cf1db2eed..000000000 --- a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/org/ diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/Delete.Me b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/Delete.Me deleted file mode 100644 index 4cb946ffd..000000000 --- a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/Delete.Me +++ /dev/null @@ -1 +0,0 @@ -This file is here just to avoid loss of the parent folder during ZIPping and unZIPping.
\ No newline at end of file diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Column.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Column.java new file mode 100644 index 000000000..8c611d745 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Column.java @@ -0,0 +1,125 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Column</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getType <em>Type</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getForeignKeys <em>Foreign Keys</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getKeys <em>Keys</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getColumn() + * @model + * @generated + */ +public interface Column extends RModelElement { + /** + * Returns the value of the '<em><b>Type</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Type</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Type</em>' attribute. + * @see #setType(String) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getColumn_Type() + * @model + * @generated + */ + String getType(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getType <em>Type</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Type</em>' attribute. + * @see #getType() + * @generated + */ + void setType(String value); + + /** + * Returns the value of the '<em><b>Owner</b></em>' container reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getColumns <em>Columns</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Owner</em>' container reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Owner</em>' container reference. + * @see #setOwner(Table) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getColumn_Owner() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getColumns + * @model opposite="columns" required="true" transient="false" + * @generated + */ + Table getOwner(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getOwner <em>Owner</em>}' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Owner</em>' container reference. + * @see #getOwner() + * @generated + */ + void setOwner(Table value); + + /** + * Returns the value of the '<em><b>Foreign Keys</b></em>' reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getColumns <em>Columns</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Foreign Keys</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Foreign Keys</em>' reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getColumn_ForeignKeys() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getColumns + * @model opposite="columns" + * @generated + */ + EList<ForeignKey> getForeignKeys(); + + /** + * Returns the value of the '<em><b>Keys</b></em>' reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getColumn <em>Column</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Keys</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Keys</em>' reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getColumn_Keys() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getColumn + * @model opposite="column" + * @generated + */ + EList<Key> getKeys(); + +} // Column diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/ForeignKey.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/ForeignKey.java new file mode 100644 index 000000000..ac2bccf74 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/ForeignKey.java @@ -0,0 +1,106 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Foreign Key</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getRefersTo <em>Refers To</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getColumns <em>Columns</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getOwner <em>Owner</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getForeignKey() + * @model + * @generated + */ +public interface ForeignKey extends RModelElement { + /** + * Returns the value of the '<em><b>Refers To</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Refers To</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Refers To</em>' reference. + * @see #setRefersTo(Key) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getForeignKey_RefersTo() + * @model required="true" + * @generated + */ + Key getRefersTo(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getRefersTo <em>Refers To</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Refers To</em>' reference. + * @see #getRefersTo() + * @generated + */ + void setRefersTo(Key value); + + /** + * Returns the value of the '<em><b>Columns</b></em>' reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getForeignKeys <em>Foreign Keys</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Columns</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Columns</em>' reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getForeignKey_Columns() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getForeignKeys + * @model opposite="foreignKeys" + * @generated + */ + EList<Column> getColumns(); + + /** + * Returns the value of the '<em><b>Owner</b></em>' container reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getForeignKeys <em>Foreign Keys</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Owner</em>' container reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Owner</em>' container reference. + * @see #setOwner(Table) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getForeignKey_Owner() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getForeignKeys + * @model opposite="foreignKeys" required="true" transient="false" + * @generated + */ + Table getOwner(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getOwner <em>Owner</em>}' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Owner</em>' container reference. + * @see #getOwner() + * @generated + */ + void setOwner(Table value); + +} // ForeignKey diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Key.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Key.java new file mode 100644 index 000000000..87095a776 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Key.java @@ -0,0 +1,79 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Key</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getColumn <em>Column</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getKey() + * @model + * @generated + */ +public interface Key extends RModelElement { + /** + * Returns the value of the '<em><b>Owner</b></em>' container reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getKeys <em>Keys</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Owner</em>' container reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Owner</em>' container reference. + * @see #setOwner(Table) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getKey_Owner() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getKeys + * @model opposite="keys" required="true" transient="false" + * @generated + */ + Table getOwner(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getOwner <em>Owner</em>}' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Owner</em>' container reference. + * @see #getOwner() + * @generated + */ + void setOwner(Table value); + + /** + * Returns the value of the '<em><b>Column</b></em>' reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getKeys <em>Keys</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Column</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Column</em>' reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getKey_Column() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getKeys + * @model opposite="keys" + * @generated + */ + EList<Column> getColumn(); + +} // Key diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/RModelElement.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/RModelElement.java new file mode 100644 index 000000000..483b71926 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/RModelElement.java @@ -0,0 +1,85 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms; + +import org.eclipse.emf.ecore.EObject; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>RModel Element</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement#getName <em>Name</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement#getKind <em>Kind</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getRModelElement() + * @model abstract="true" + * @generated + */ +public interface RModelElement extends EObject { + /** + * Returns the value of the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Name</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Name</em>' attribute. + * @see #setName(String) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getRModelElement_Name() + * @model + * @generated + */ + String getName(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement#getName <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Name</em>' attribute. + * @see #getName() + * @generated + */ + void setName(String value); + + /** + * Returns the value of the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Kind</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Kind</em>' attribute. + * @see #setKind(String) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getRModelElement_Kind() + * @model + * @generated + */ + String getKind(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement#getKind <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Kind</em>' attribute. + * @see #getKind() + * @generated + */ + void setKind(String value); + +} // RModelElement diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Schema.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Schema.java new file mode 100644 index 000000000..36033d2fc --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Schema.java @@ -0,0 +1,50 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Schema</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema#getTables <em>Tables</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getSchema() + * @model + * @generated + */ +public interface Schema extends RModelElement { + /** + * Returns the value of the '<em><b>Tables</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getSchema <em>Schema</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Tables</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Tables</em>' containment reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getSchema_Tables() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getSchema + * @model opposite="schema" containment="true" + * @generated + */ + EList<Table> getTables(); + +} // Schema diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/SimplerdbmsFactory.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/SimplerdbmsFactory.java new file mode 100644 index 000000000..413fc072c --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/SimplerdbmsFactory.java @@ -0,0 +1,86 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms; + +import org.eclipse.emf.ecore.EFactory; + +/** + * <!-- begin-user-doc --> + * The <b>Factory</b> for the model. + * It provides a create method for each non-abstract class of the model. + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage + * @generated + */ +public interface SimplerdbmsFactory extends EFactory { + /** + * The singleton instance of the factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + SimplerdbmsFactory eINSTANCE = org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsFactoryImpl.init(); + + /** + * Returns a new object of class '<em>Column</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Column</em>'. + * @generated + */ + Column createColumn(); + + /** + * Returns a new object of class '<em>Foreign Key</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Foreign Key</em>'. + * @generated + */ + ForeignKey createForeignKey(); + + /** + * Returns a new object of class '<em>Key</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Key</em>'. + * @generated + */ + Key createKey(); + + /** + * Returns a new object of class '<em>Schema</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Schema</em>'. + * @generated + */ + Schema createSchema(); + + /** + * Returns a new object of class '<em>Table</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Table</em>'. + * @generated + */ + Table createTable(); + + /** + * Returns the package supported by this factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the package supported by this factory. + * @generated + */ + SimplerdbmsPackage getSimplerdbmsPackage(); + +} //SimplerdbmsFactory diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/SimplerdbmsPackage.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/SimplerdbmsPackage.java new file mode 100644 index 000000000..ff9f76860 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/SimplerdbmsPackage.java @@ -0,0 +1,951 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms; + +import org.eclipse.emf.ecore.EAttribute; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EDataType; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +/** + * <!-- begin-user-doc --> + * The <b>Package</b> for the model. + * It contains accessors for the meta objects to represent + * <ul> + * <li>each class,</li> + * <li>each feature of each class,</li> + * <li>each operation of each class,</li> + * <li>each enum,</li> + * <li>and each data type</li> + * </ul> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsFactory + * @model kind="package" + * @generated + */ +public interface SimplerdbmsPackage extends EPackage { + /** + * The package name. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNAME = "simplerdbms"; + + /** + * The package namespace URI. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNS_URI = "http://www.eclipse.org/qvtd/examples/qvtcore/UML2RDBMS/1.0/SimpleRDBMS"; + + /** + * The package namespace name. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNS_PREFIX = "simplerdbms"; + + /** + * The singleton instance of the package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + SimplerdbmsPackage eINSTANCE = org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl.init(); + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.RModelElementImpl <em>RModel Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.RModelElementImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getRModelElement() + * @generated + */ + int RMODEL_ELEMENT = 3; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int RMODEL_ELEMENT__NAME = 0; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int RMODEL_ELEMENT__KIND = 1; + + /** + * The number of structural features of the '<em>RModel Element</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int RMODEL_ELEMENT_FEATURE_COUNT = 2; + + /** + * The number of operations of the '<em>RModel Element</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int RMODEL_ELEMENT_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ColumnImpl <em>Column</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ColumnImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getColumn() + * @generated + */ + int COLUMN = 0; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int COLUMN__NAME = RMODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int COLUMN__KIND = RMODEL_ELEMENT__KIND; + + /** + * The feature id for the '<em><b>Type</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int COLUMN__TYPE = RMODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int COLUMN__OWNER = RMODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Foreign Keys</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int COLUMN__FOREIGN_KEYS = RMODEL_ELEMENT_FEATURE_COUNT + 2; + + /** + * The feature id for the '<em><b>Keys</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int COLUMN__KEYS = RMODEL_ELEMENT_FEATURE_COUNT + 3; + + /** + * The number of structural features of the '<em>Column</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int COLUMN_FEATURE_COUNT = RMODEL_ELEMENT_FEATURE_COUNT + 4; + + /** + * The number of operations of the '<em>Column</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int COLUMN_OPERATION_COUNT = RMODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ForeignKeyImpl <em>Foreign Key</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ForeignKeyImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getForeignKey() + * @generated + */ + int FOREIGN_KEY = 1; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FOREIGN_KEY__NAME = RMODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FOREIGN_KEY__KIND = RMODEL_ELEMENT__KIND; + + /** + * The feature id for the '<em><b>Refers To</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FOREIGN_KEY__REFERS_TO = RMODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Columns</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FOREIGN_KEY__COLUMNS = RMODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FOREIGN_KEY__OWNER = RMODEL_ELEMENT_FEATURE_COUNT + 2; + + /** + * The number of structural features of the '<em>Foreign Key</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FOREIGN_KEY_FEATURE_COUNT = RMODEL_ELEMENT_FEATURE_COUNT + 3; + + /** + * The number of operations of the '<em>Foreign Key</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FOREIGN_KEY_OPERATION_COUNT = RMODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.KeyImpl <em>Key</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.KeyImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getKey() + * @generated + */ + int KEY = 2; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int KEY__NAME = RMODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int KEY__KIND = RMODEL_ELEMENT__KIND; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int KEY__OWNER = RMODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Column</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int KEY__COLUMN = RMODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The number of structural features of the '<em>Key</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int KEY_FEATURE_COUNT = RMODEL_ELEMENT_FEATURE_COUNT + 2; + + /** + * The number of operations of the '<em>Key</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int KEY_OPERATION_COUNT = RMODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SchemaImpl <em>Schema</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SchemaImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getSchema() + * @generated + */ + int SCHEMA = 4; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int SCHEMA__NAME = RMODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int SCHEMA__KIND = RMODEL_ELEMENT__KIND; + + /** + * The feature id for the '<em><b>Tables</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int SCHEMA__TABLES = RMODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The number of structural features of the '<em>Schema</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int SCHEMA_FEATURE_COUNT = RMODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The number of operations of the '<em>Schema</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int SCHEMA_OPERATION_COUNT = RMODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.TableImpl <em>Table</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.TableImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getTable() + * @generated + */ + int TABLE = 5; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TABLE__NAME = RMODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TABLE__KIND = RMODEL_ELEMENT__KIND; + + /** + * The feature id for the '<em><b>Columns</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TABLE__COLUMNS = RMODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Schema</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TABLE__SCHEMA = RMODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Keys</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TABLE__KEYS = RMODEL_ELEMENT_FEATURE_COUNT + 2; + + /** + * The feature id for the '<em><b>Foreign Keys</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TABLE__FOREIGN_KEYS = RMODEL_ELEMENT_FEATURE_COUNT + 3; + + /** + * The number of structural features of the '<em>Table</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TABLE_FEATURE_COUNT = RMODEL_ELEMENT_FEATURE_COUNT + 4; + + /** + * The number of operations of the '<em>Table</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TABLE_OPERATION_COUNT = RMODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '<em>String</em>' data type. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see java.lang.Object + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getString() + * @generated + */ + int STRING = 6; + + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column <em>Column</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Column</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column + * @generated + */ + EClass getColumn(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getType <em>Type</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Type</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getType() + * @see #getColumn() + * @generated + */ + EAttribute getColumn_Type(); + + /** + * Returns the meta object for the container reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the container reference '<em>Owner</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getOwner() + * @see #getColumn() + * @generated + */ + EReference getColumn_Owner(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getForeignKeys <em>Foreign Keys</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Foreign Keys</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getForeignKeys() + * @see #getColumn() + * @generated + */ + EReference getColumn_ForeignKeys(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getKeys <em>Keys</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Keys</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getKeys() + * @see #getColumn() + * @generated + */ + EReference getColumn_Keys(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey <em>Foreign Key</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Foreign Key</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey + * @generated + */ + EClass getForeignKey(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getRefersTo <em>Refers To</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Refers To</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getRefersTo() + * @see #getForeignKey() + * @generated + */ + EReference getForeignKey_RefersTo(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getColumns <em>Columns</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Columns</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getColumns() + * @see #getForeignKey() + * @generated + */ + EReference getForeignKey_Columns(); + + /** + * Returns the meta object for the container reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the container reference '<em>Owner</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getOwner() + * @see #getForeignKey() + * @generated + */ + EReference getForeignKey_Owner(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key <em>Key</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Key</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key + * @generated + */ + EClass getKey(); + + /** + * Returns the meta object for the container reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the container reference '<em>Owner</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getOwner() + * @see #getKey() + * @generated + */ + EReference getKey_Owner(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getColumn <em>Column</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Column</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getColumn() + * @see #getKey() + * @generated + */ + EReference getKey_Column(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement <em>RModel Element</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>RModel Element</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement + * @generated + */ + EClass getRModelElement(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement#getName <em>Name</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Name</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement#getName() + * @see #getRModelElement() + * @generated + */ + EAttribute getRModelElement_Name(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement#getKind <em>Kind</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Kind</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement#getKind() + * @see #getRModelElement() + * @generated + */ + EAttribute getRModelElement_Kind(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema <em>Schema</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Schema</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema + * @generated + */ + EClass getSchema(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema#getTables <em>Tables</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Tables</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema#getTables() + * @see #getSchema() + * @generated + */ + EReference getSchema_Tables(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table <em>Table</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Table</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table + * @generated + */ + EClass getTable(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getColumns <em>Columns</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Columns</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getColumns() + * @see #getTable() + * @generated + */ + EReference getTable_Columns(); + + /** + * Returns the meta object for the container reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getSchema <em>Schema</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the container reference '<em>Schema</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getSchema() + * @see #getTable() + * @generated + */ + EReference getTable_Schema(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getKeys <em>Keys</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Keys</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getKeys() + * @see #getTable() + * @generated + */ + EReference getTable_Keys(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getForeignKeys <em>Foreign Keys</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Foreign Keys</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getForeignKeys() + * @see #getTable() + * @generated + */ + EReference getTable_ForeignKeys(); + + /** + * Returns the meta object for data type '{@link java.lang.Object <em>String</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for data type '<em>String</em>'. + * @see java.lang.Object + * @model instanceClass="java.lang.Object" + * @generated + */ + EDataType getString(); + + /** + * Returns the factory that creates the instances of the model. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the factory that creates the instances of the model. + * @generated + */ + SimplerdbmsFactory getSimplerdbmsFactory(); + + /** + * <!-- begin-user-doc --> + * Defines literals for the meta objects that represent + * <ul> + * <li>each class,</li> + * <li>each feature of each class,</li> + * <li>each operation of each class,</li> + * <li>each enum,</li> + * <li>and each data type</li> + * </ul> + * <!-- end-user-doc --> + * @generated + */ + interface Literals { + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ColumnImpl <em>Column</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ColumnImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getColumn() + * @generated + */ + EClass COLUMN = eINSTANCE.getColumn(); + + /** + * The meta object literal for the '<em><b>Type</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute COLUMN__TYPE = eINSTANCE.getColumn_Type(); + + /** + * The meta object literal for the '<em><b>Owner</b></em>' container reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference COLUMN__OWNER = eINSTANCE.getColumn_Owner(); + + /** + * The meta object literal for the '<em><b>Foreign Keys</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference COLUMN__FOREIGN_KEYS = eINSTANCE.getColumn_ForeignKeys(); + + /** + * The meta object literal for the '<em><b>Keys</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference COLUMN__KEYS = eINSTANCE.getColumn_Keys(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ForeignKeyImpl <em>Foreign Key</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ForeignKeyImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getForeignKey() + * @generated + */ + EClass FOREIGN_KEY = eINSTANCE.getForeignKey(); + + /** + * The meta object literal for the '<em><b>Refers To</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference FOREIGN_KEY__REFERS_TO = eINSTANCE.getForeignKey_RefersTo(); + + /** + * The meta object literal for the '<em><b>Columns</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference FOREIGN_KEY__COLUMNS = eINSTANCE.getForeignKey_Columns(); + + /** + * The meta object literal for the '<em><b>Owner</b></em>' container reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference FOREIGN_KEY__OWNER = eINSTANCE.getForeignKey_Owner(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.KeyImpl <em>Key</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.KeyImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getKey() + * @generated + */ + EClass KEY = eINSTANCE.getKey(); + + /** + * The meta object literal for the '<em><b>Owner</b></em>' container reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference KEY__OWNER = eINSTANCE.getKey_Owner(); + + /** + * The meta object literal for the '<em><b>Column</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference KEY__COLUMN = eINSTANCE.getKey_Column(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.RModelElementImpl <em>RModel Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.RModelElementImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getRModelElement() + * @generated + */ + EClass RMODEL_ELEMENT = eINSTANCE.getRModelElement(); + + /** + * The meta object literal for the '<em><b>Name</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute RMODEL_ELEMENT__NAME = eINSTANCE.getRModelElement_Name(); + + /** + * The meta object literal for the '<em><b>Kind</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute RMODEL_ELEMENT__KIND = eINSTANCE.getRModelElement_Kind(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SchemaImpl <em>Schema</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SchemaImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getSchema() + * @generated + */ + EClass SCHEMA = eINSTANCE.getSchema(); + + /** + * The meta object literal for the '<em><b>Tables</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference SCHEMA__TABLES = eINSTANCE.getSchema_Tables(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.TableImpl <em>Table</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.TableImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getTable() + * @generated + */ + EClass TABLE = eINSTANCE.getTable(); + + /** + * The meta object literal for the '<em><b>Columns</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference TABLE__COLUMNS = eINSTANCE.getTable_Columns(); + + /** + * The meta object literal for the '<em><b>Schema</b></em>' container reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference TABLE__SCHEMA = eINSTANCE.getTable_Schema(); + + /** + * The meta object literal for the '<em><b>Keys</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference TABLE__KEYS = eINSTANCE.getTable_Keys(); + + /** + * The meta object literal for the '<em><b>Foreign Keys</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference TABLE__FOREIGN_KEYS = eINSTANCE.getTable_ForeignKeys(); + + /** + * The meta object literal for the '<em>String</em>' data type. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see java.lang.Object + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl#getString() + * @generated + */ + EDataType STRING = eINSTANCE.getString(); + + } + +} //SimplerdbmsPackage diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Table.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Table.java new file mode 100644 index 000000000..7cfd77fda --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/Table.java @@ -0,0 +1,117 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Table</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getColumns <em>Columns</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getSchema <em>Schema</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getKeys <em>Keys</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getForeignKeys <em>Foreign Keys</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getTable() + * @model + * @generated + */ +public interface Table extends RModelElement { + /** + * Returns the value of the '<em><b>Columns</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Columns</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Columns</em>' containment reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getTable_Columns() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column#getOwner + * @model opposite="owner" containment="true" + * @generated + */ + EList<Column> getColumns(); + + /** + * Returns the value of the '<em><b>Schema</b></em>' container reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema#getTables <em>Tables</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Schema</em>' container reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Schema</em>' container reference. + * @see #setSchema(Schema) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getTable_Schema() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema#getTables + * @model opposite="tables" required="true" transient="false" + * @generated + */ + Schema getSchema(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table#getSchema <em>Schema</em>}' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Schema</em>' container reference. + * @see #getSchema() + * @generated + */ + void setSchema(Schema value); + + /** + * Returns the value of the '<em><b>Keys</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Keys</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Keys</em>' containment reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getTable_Keys() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key#getOwner + * @model opposite="owner" containment="true" + * @generated + */ + EList<Key> getKeys(); + + /** + * Returns the value of the '<em><b>Foreign Keys</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Foreign Keys</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Foreign Keys</em>' containment reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#getTable_ForeignKeys() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey#getOwner + * @model opposite="owner" containment="true" + * @generated + */ + EList<ForeignKey> getForeignKeys(); + +} // Table diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/ColumnImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/ColumnImpl.java new file mode 100644 index 000000000..9a11715f1 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/ColumnImpl.java @@ -0,0 +1,357 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList; +import org.eclipse.emf.ecore.util.EcoreUtil; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Column</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ColumnImpl#getType <em>Type</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ColumnImpl#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ColumnImpl#getForeignKeys <em>Foreign Keys</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ColumnImpl#getKeys <em>Keys</em>}</li> + * </ul> + * + * @generated + */ +public class ColumnImpl extends RModelElementImpl implements Column { + /** + * The default value of the '{@link #getType() <em>Type</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getType() + * @generated + * @ordered + */ + protected static final String TYPE_EDEFAULT = null; + + /** + * The cached value of the '{@link #getType() <em>Type</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getType() + * @generated + * @ordered + */ + protected String type = TYPE_EDEFAULT; + + /** + * The cached value of the '{@link #getForeignKeys() <em>Foreign Keys</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getForeignKeys() + * @generated + * @ordered + */ + protected EList<ForeignKey> foreignKeys; + + /** + * The cached value of the '{@link #getKeys() <em>Keys</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getKeys() + * @generated + * @ordered + */ + protected EList<Key> keys; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ColumnImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimplerdbmsPackage.Literals.COLUMN; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getType() { + return type; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setType(String newType) { + String oldType = type; + type = newType; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimplerdbmsPackage.COLUMN__TYPE, oldType, type)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Table getOwner() { + if (eContainerFeatureID() != SimplerdbmsPackage.COLUMN__OWNER) return null; + return (Table)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetOwner(Table newOwner, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newOwner, SimplerdbmsPackage.COLUMN__OWNER, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setOwner(Table newOwner) { + if (newOwner != eInternalContainer() || (eContainerFeatureID() != SimplerdbmsPackage.COLUMN__OWNER && newOwner != null)) { + if (EcoreUtil.isAncestor(this, newOwner)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newOwner != null) + msgs = ((InternalEObject)newOwner).eInverseAdd(this, SimplerdbmsPackage.TABLE__COLUMNS, Table.class, msgs); + msgs = basicSetOwner(newOwner, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimplerdbmsPackage.COLUMN__OWNER, newOwner, newOwner)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<ForeignKey> getForeignKeys() { + if (foreignKeys == null) { + foreignKeys = new EObjectWithInverseResolvingEList.ManyInverse<ForeignKey>(ForeignKey.class, this, SimplerdbmsPackage.COLUMN__FOREIGN_KEYS, SimplerdbmsPackage.FOREIGN_KEY__COLUMNS); + } + return foreignKeys; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<Key> getKeys() { + if (keys == null) { + keys = new EObjectWithInverseResolvingEList.ManyInverse<Key>(Key.class, this, SimplerdbmsPackage.COLUMN__KEYS, SimplerdbmsPackage.KEY__COLUMN); + } + return keys; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimplerdbmsPackage.COLUMN__OWNER: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetOwner((Table)otherEnd, msgs); + case SimplerdbmsPackage.COLUMN__FOREIGN_KEYS: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getForeignKeys()).basicAdd(otherEnd, msgs); + case SimplerdbmsPackage.COLUMN__KEYS: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getKeys()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimplerdbmsPackage.COLUMN__OWNER: + return basicSetOwner(null, msgs); + case SimplerdbmsPackage.COLUMN__FOREIGN_KEYS: + return ((InternalEList<?>)getForeignKeys()).basicRemove(otherEnd, msgs); + case SimplerdbmsPackage.COLUMN__KEYS: + return ((InternalEList<?>)getKeys()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case SimplerdbmsPackage.COLUMN__OWNER: + return eInternalContainer().eInverseRemove(this, SimplerdbmsPackage.TABLE__COLUMNS, Table.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimplerdbmsPackage.COLUMN__TYPE: + return getType(); + case SimplerdbmsPackage.COLUMN__OWNER: + return getOwner(); + case SimplerdbmsPackage.COLUMN__FOREIGN_KEYS: + return getForeignKeys(); + case SimplerdbmsPackage.COLUMN__KEYS: + return getKeys(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimplerdbmsPackage.COLUMN__TYPE: + setType((String)newValue); + return; + case SimplerdbmsPackage.COLUMN__OWNER: + setOwner((Table)newValue); + return; + case SimplerdbmsPackage.COLUMN__FOREIGN_KEYS: + getForeignKeys().clear(); + getForeignKeys().addAll((Collection<? extends ForeignKey>)newValue); + return; + case SimplerdbmsPackage.COLUMN__KEYS: + getKeys().clear(); + getKeys().addAll((Collection<? extends Key>)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.COLUMN__TYPE: + setType(TYPE_EDEFAULT); + return; + case SimplerdbmsPackage.COLUMN__OWNER: + setOwner((Table)null); + return; + case SimplerdbmsPackage.COLUMN__FOREIGN_KEYS: + getForeignKeys().clear(); + return; + case SimplerdbmsPackage.COLUMN__KEYS: + getKeys().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.COLUMN__TYPE: + return TYPE_EDEFAULT == null ? type != null : !TYPE_EDEFAULT.equals(type); + case SimplerdbmsPackage.COLUMN__OWNER: + return getOwner() != null; + case SimplerdbmsPackage.COLUMN__FOREIGN_KEYS: + return foreignKeys != null && !foreignKeys.isEmpty(); + case SimplerdbmsPackage.COLUMN__KEYS: + return keys != null && !keys.isEmpty(); + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuffer result = new StringBuffer(super.toString()); + result.append(" (type: "); + result.append(type); + result.append(')'); + return result.toString(); + } + +} //ColumnImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/ForeignKeyImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/ForeignKeyImpl.java new file mode 100644 index 000000000..21f65d006 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/ForeignKeyImpl.java @@ -0,0 +1,311 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList; +import org.eclipse.emf.ecore.util.EcoreUtil; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Foreign Key</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ForeignKeyImpl#getRefersTo <em>Refers To</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ForeignKeyImpl#getColumns <em>Columns</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.ForeignKeyImpl#getOwner <em>Owner</em>}</li> + * </ul> + * + * @generated + */ +public class ForeignKeyImpl extends RModelElementImpl implements ForeignKey { + /** + * The cached value of the '{@link #getRefersTo() <em>Refers To</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getRefersTo() + * @generated + * @ordered + */ + protected Key refersTo; + + /** + * The cached value of the '{@link #getColumns() <em>Columns</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getColumns() + * @generated + * @ordered + */ + protected EList<Column> columns; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ForeignKeyImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimplerdbmsPackage.Literals.FOREIGN_KEY; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Key getRefersTo() { + if (refersTo != null && refersTo.eIsProxy()) { + InternalEObject oldRefersTo = (InternalEObject)refersTo; + refersTo = (Key)eResolveProxy(oldRefersTo); + if (refersTo != oldRefersTo) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, SimplerdbmsPackage.FOREIGN_KEY__REFERS_TO, oldRefersTo, refersTo)); + } + } + return refersTo; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Key basicGetRefersTo() { + return refersTo; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setRefersTo(Key newRefersTo) { + Key oldRefersTo = refersTo; + refersTo = newRefersTo; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimplerdbmsPackage.FOREIGN_KEY__REFERS_TO, oldRefersTo, refersTo)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<Column> getColumns() { + if (columns == null) { + columns = new EObjectWithInverseResolvingEList.ManyInverse<Column>(Column.class, this, SimplerdbmsPackage.FOREIGN_KEY__COLUMNS, SimplerdbmsPackage.COLUMN__FOREIGN_KEYS); + } + return columns; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Table getOwner() { + if (eContainerFeatureID() != SimplerdbmsPackage.FOREIGN_KEY__OWNER) return null; + return (Table)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetOwner(Table newOwner, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newOwner, SimplerdbmsPackage.FOREIGN_KEY__OWNER, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setOwner(Table newOwner) { + if (newOwner != eInternalContainer() || (eContainerFeatureID() != SimplerdbmsPackage.FOREIGN_KEY__OWNER && newOwner != null)) { + if (EcoreUtil.isAncestor(this, newOwner)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newOwner != null) + msgs = ((InternalEObject)newOwner).eInverseAdd(this, SimplerdbmsPackage.TABLE__FOREIGN_KEYS, Table.class, msgs); + msgs = basicSetOwner(newOwner, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimplerdbmsPackage.FOREIGN_KEY__OWNER, newOwner, newOwner)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimplerdbmsPackage.FOREIGN_KEY__COLUMNS: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getColumns()).basicAdd(otherEnd, msgs); + case SimplerdbmsPackage.FOREIGN_KEY__OWNER: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetOwner((Table)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimplerdbmsPackage.FOREIGN_KEY__COLUMNS: + return ((InternalEList<?>)getColumns()).basicRemove(otherEnd, msgs); + case SimplerdbmsPackage.FOREIGN_KEY__OWNER: + return basicSetOwner(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case SimplerdbmsPackage.FOREIGN_KEY__OWNER: + return eInternalContainer().eInverseRemove(this, SimplerdbmsPackage.TABLE__FOREIGN_KEYS, Table.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimplerdbmsPackage.FOREIGN_KEY__REFERS_TO: + if (resolve) return getRefersTo(); + return basicGetRefersTo(); + case SimplerdbmsPackage.FOREIGN_KEY__COLUMNS: + return getColumns(); + case SimplerdbmsPackage.FOREIGN_KEY__OWNER: + return getOwner(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimplerdbmsPackage.FOREIGN_KEY__REFERS_TO: + setRefersTo((Key)newValue); + return; + case SimplerdbmsPackage.FOREIGN_KEY__COLUMNS: + getColumns().clear(); + getColumns().addAll((Collection<? extends Column>)newValue); + return; + case SimplerdbmsPackage.FOREIGN_KEY__OWNER: + setOwner((Table)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.FOREIGN_KEY__REFERS_TO: + setRefersTo((Key)null); + return; + case SimplerdbmsPackage.FOREIGN_KEY__COLUMNS: + getColumns().clear(); + return; + case SimplerdbmsPackage.FOREIGN_KEY__OWNER: + setOwner((Table)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.FOREIGN_KEY__REFERS_TO: + return refersTo != null; + case SimplerdbmsPackage.FOREIGN_KEY__COLUMNS: + return columns != null && !columns.isEmpty(); + case SimplerdbmsPackage.FOREIGN_KEY__OWNER: + return getOwner() != null; + } + return super.eIsSet(featureID); + } + +} //ForeignKeyImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/KeyImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/KeyImpl.java new file mode 100644 index 000000000..cc37abe75 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/KeyImpl.java @@ -0,0 +1,250 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList; +import org.eclipse.emf.ecore.util.EcoreUtil; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Key</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.KeyImpl#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.KeyImpl#getColumn <em>Column</em>}</li> + * </ul> + * + * @generated + */ +public class KeyImpl extends RModelElementImpl implements Key { + /** + * The cached value of the '{@link #getColumn() <em>Column</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getColumn() + * @generated + * @ordered + */ + protected EList<Column> column; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected KeyImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimplerdbmsPackage.Literals.KEY; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Table getOwner() { + if (eContainerFeatureID() != SimplerdbmsPackage.KEY__OWNER) return null; + return (Table)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetOwner(Table newOwner, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newOwner, SimplerdbmsPackage.KEY__OWNER, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setOwner(Table newOwner) { + if (newOwner != eInternalContainer() || (eContainerFeatureID() != SimplerdbmsPackage.KEY__OWNER && newOwner != null)) { + if (EcoreUtil.isAncestor(this, newOwner)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newOwner != null) + msgs = ((InternalEObject)newOwner).eInverseAdd(this, SimplerdbmsPackage.TABLE__KEYS, Table.class, msgs); + msgs = basicSetOwner(newOwner, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimplerdbmsPackage.KEY__OWNER, newOwner, newOwner)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<Column> getColumn() { + if (column == null) { + column = new EObjectWithInverseResolvingEList.ManyInverse<Column>(Column.class, this, SimplerdbmsPackage.KEY__COLUMN, SimplerdbmsPackage.COLUMN__KEYS); + } + return column; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimplerdbmsPackage.KEY__OWNER: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetOwner((Table)otherEnd, msgs); + case SimplerdbmsPackage.KEY__COLUMN: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getColumn()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimplerdbmsPackage.KEY__OWNER: + return basicSetOwner(null, msgs); + case SimplerdbmsPackage.KEY__COLUMN: + return ((InternalEList<?>)getColumn()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case SimplerdbmsPackage.KEY__OWNER: + return eInternalContainer().eInverseRemove(this, SimplerdbmsPackage.TABLE__KEYS, Table.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimplerdbmsPackage.KEY__OWNER: + return getOwner(); + case SimplerdbmsPackage.KEY__COLUMN: + return getColumn(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimplerdbmsPackage.KEY__OWNER: + setOwner((Table)newValue); + return; + case SimplerdbmsPackage.KEY__COLUMN: + getColumn().clear(); + getColumn().addAll((Collection<? extends Column>)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.KEY__OWNER: + setOwner((Table)null); + return; + case SimplerdbmsPackage.KEY__COLUMN: + getColumn().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.KEY__OWNER: + return getOwner() != null; + case SimplerdbmsPackage.KEY__COLUMN: + return column != null && !column.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //KeyImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/RModelElementImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/RModelElementImpl.java new file mode 100644 index 000000000..69c24a13a --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/RModelElementImpl.java @@ -0,0 +1,225 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl; + +import org.eclipse.emf.common.notify.Notification; + +import org.eclipse.emf.ecore.EClass; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>RModel Element</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.RModelElementImpl#getName <em>Name</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.RModelElementImpl#getKind <em>Kind</em>}</li> + * </ul> + * + * @generated + */ +public abstract class RModelElementImpl extends MinimalEObjectImpl.Container implements RModelElement { + /** + * The default value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected static final String NAME_EDEFAULT = null; + + /** + * The cached value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected String name = NAME_EDEFAULT; + + /** + * The default value of the '{@link #getKind() <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getKind() + * @generated + * @ordered + */ + protected static final String KIND_EDEFAULT = null; + + /** + * The cached value of the '{@link #getKind() <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getKind() + * @generated + * @ordered + */ + protected String kind = KIND_EDEFAULT; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected RModelElementImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimplerdbmsPackage.Literals.RMODEL_ELEMENT; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getName() { + return name; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setName(String newName) { + String oldName = name; + name = newName; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimplerdbmsPackage.RMODEL_ELEMENT__NAME, oldName, name)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getKind() { + return kind; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setKind(String newKind) { + String oldKind = kind; + kind = newKind; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimplerdbmsPackage.RMODEL_ELEMENT__KIND, oldKind, kind)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimplerdbmsPackage.RMODEL_ELEMENT__NAME: + return getName(); + case SimplerdbmsPackage.RMODEL_ELEMENT__KIND: + return getKind(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimplerdbmsPackage.RMODEL_ELEMENT__NAME: + setName((String)newValue); + return; + case SimplerdbmsPackage.RMODEL_ELEMENT__KIND: + setKind((String)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.RMODEL_ELEMENT__NAME: + setName(NAME_EDEFAULT); + return; + case SimplerdbmsPackage.RMODEL_ELEMENT__KIND: + setKind(KIND_EDEFAULT); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.RMODEL_ELEMENT__NAME: + return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); + case SimplerdbmsPackage.RMODEL_ELEMENT__KIND: + return KIND_EDEFAULT == null ? kind != null : !KIND_EDEFAULT.equals(kind); + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuffer result = new StringBuffer(super.toString()); + result.append(" (name: "); + result.append(name); + result.append(", kind: "); + result.append(kind); + result.append(')'); + return result.toString(); + } + +} //RModelElementImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/SchemaImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/SchemaImpl.java new file mode 100644 index 000000000..3d9dc4211 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/SchemaImpl.java @@ -0,0 +1,173 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Schema</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SchemaImpl#getTables <em>Tables</em>}</li> + * </ul> + * + * @generated + */ +public class SchemaImpl extends RModelElementImpl implements Schema { + /** + * The cached value of the '{@link #getTables() <em>Tables</em>}' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getTables() + * @generated + * @ordered + */ + protected EList<Table> tables; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected SchemaImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimplerdbmsPackage.Literals.SCHEMA; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<Table> getTables() { + if (tables == null) { + tables = new EObjectContainmentWithInverseEList<Table>(Table.class, this, SimplerdbmsPackage.SCHEMA__TABLES, SimplerdbmsPackage.TABLE__SCHEMA); + } + return tables; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimplerdbmsPackage.SCHEMA__TABLES: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getTables()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimplerdbmsPackage.SCHEMA__TABLES: + return ((InternalEList<?>)getTables()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimplerdbmsPackage.SCHEMA__TABLES: + return getTables(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimplerdbmsPackage.SCHEMA__TABLES: + getTables().clear(); + getTables().addAll((Collection<? extends Table>)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.SCHEMA__TABLES: + getTables().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.SCHEMA__TABLES: + return tables != null && !tables.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //SchemaImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/SimplerdbmsFactoryImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/SimplerdbmsFactoryImpl.java new file mode 100644 index 000000000..40e881c7c --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/SimplerdbmsFactoryImpl.java @@ -0,0 +1,196 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EDataType; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.impl.EFactoryImpl; + +import org.eclipse.emf.ecore.plugin.EcorePlugin; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.*; + +/** + * <!-- begin-user-doc --> + * An implementation of the model <b>Factory</b>. + * <!-- end-user-doc --> + * @generated + */ +public class SimplerdbmsFactoryImpl extends EFactoryImpl implements SimplerdbmsFactory { + /** + * Creates the default factory implementation. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public static SimplerdbmsFactory init() { + try { + SimplerdbmsFactory theSimplerdbmsFactory = (SimplerdbmsFactory)EPackage.Registry.INSTANCE.getEFactory(SimplerdbmsPackage.eNS_URI); + if (theSimplerdbmsFactory != null) { + return theSimplerdbmsFactory; + } + } + catch (Exception exception) { + EcorePlugin.INSTANCE.log(exception); + } + return new SimplerdbmsFactoryImpl(); + } + + /** + * Creates an instance of the factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SimplerdbmsFactoryImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public EObject create(EClass eClass) { + switch (eClass.getClassifierID()) { + case SimplerdbmsPackage.COLUMN: return createColumn(); + case SimplerdbmsPackage.FOREIGN_KEY: return createForeignKey(); + case SimplerdbmsPackage.KEY: return createKey(); + case SimplerdbmsPackage.SCHEMA: return createSchema(); + case SimplerdbmsPackage.TABLE: return createTable(); + default: + throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object createFromString(EDataType eDataType, String initialValue) { + switch (eDataType.getClassifierID()) { + case SimplerdbmsPackage.STRING: + return createStringFromString(eDataType, initialValue); + default: + throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String convertToString(EDataType eDataType, Object instanceValue) { + switch (eDataType.getClassifierID()) { + case SimplerdbmsPackage.STRING: + return convertStringToString(eDataType, instanceValue); + default: + throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Column createColumn() { + ColumnImpl column = new ColumnImpl(); + return column; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ForeignKey createForeignKey() { + ForeignKeyImpl foreignKey = new ForeignKeyImpl(); + return foreignKey; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Key createKey() { + KeyImpl key = new KeyImpl(); + return key; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Schema createSchema() { + SchemaImpl schema = new SchemaImpl(); + return schema; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Table createTable() { + TableImpl table = new TableImpl(); + return table; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Object createStringFromString(EDataType eDataType, String initialValue) { + return super.createFromString(eDataType, initialValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String convertStringToString(EDataType eDataType, Object instanceValue) { + return super.convertToString(eDataType, instanceValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SimplerdbmsPackage getSimplerdbmsPackage() { + return (SimplerdbmsPackage)getEPackage(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @deprecated + * @generated + */ + @Deprecated + public static SimplerdbmsPackage getPackage() { + return SimplerdbmsPackage.eINSTANCE; + } + +} //SimplerdbmsFactoryImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/SimplerdbmsPackageImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/SimplerdbmsPackageImpl.java new file mode 100644 index 000000000..19305487e --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/SimplerdbmsPackageImpl.java @@ -0,0 +1,500 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl; + +import org.eclipse.emf.ecore.EAttribute; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EDataType; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +import org.eclipse.emf.ecore.impl.EPackageImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsFactory; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl; + +/** + * <!-- begin-user-doc --> + * An implementation of the model <b>Package</b>. + * <!-- end-user-doc --> + * @generated + */ +public class SimplerdbmsPackageImpl extends EPackageImpl implements SimplerdbmsPackage { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass columnEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass foreignKeyEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass keyEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass rModelElementEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass schemaEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass tableEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EDataType stringEDataType = null; + + /** + * Creates an instance of the model <b>Package</b>, registered with + * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package + * package URI value. + * <p>Note: the correct way to create the package is via the static + * factory method {@link #init init()}, which also performs + * initialization of the package, or returns the registered package, + * if one already exists. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.ecore.EPackage.Registry + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage#eNS_URI + * @see #init() + * @generated + */ + private SimplerdbmsPackageImpl() { + super(eNS_URI, SimplerdbmsFactory.eINSTANCE); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private static boolean isInited = false; + + /** + * Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends. + * + * <p>This method is used to initialize {@link SimplerdbmsPackage#eINSTANCE} when that field is accessed. + * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #eNS_URI + * @see #createPackageContents() + * @see #initializePackageContents() + * @generated + */ + public static SimplerdbmsPackage init() { + if (isInited) return (SimplerdbmsPackage)EPackage.Registry.INSTANCE.getEPackage(SimplerdbmsPackage.eNS_URI); + + // Obtain or create and register package + SimplerdbmsPackageImpl theSimplerdbmsPackage = (SimplerdbmsPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof SimplerdbmsPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new SimplerdbmsPackageImpl()); + + isInited = true; + + // Obtain or create and register interdependencies + Simpleuml2rdbmsPackageImpl theSimpleuml2rdbmsPackage = (Simpleuml2rdbmsPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(Simpleuml2rdbmsPackage.eNS_URI) instanceof Simpleuml2rdbmsPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(Simpleuml2rdbmsPackage.eNS_URI) : Simpleuml2rdbmsPackage.eINSTANCE); + SimpleumlPackageImpl theSimpleumlPackage = (SimpleumlPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(SimpleumlPackage.eNS_URI) instanceof SimpleumlPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(SimpleumlPackage.eNS_URI) : SimpleumlPackage.eINSTANCE); + + // Create package meta-data objects + theSimplerdbmsPackage.createPackageContents(); + theSimpleuml2rdbmsPackage.createPackageContents(); + theSimpleumlPackage.createPackageContents(); + + // Initialize created meta-data + theSimplerdbmsPackage.initializePackageContents(); + theSimpleuml2rdbmsPackage.initializePackageContents(); + theSimpleumlPackage.initializePackageContents(); + + // Mark meta-data to indicate it can't be changed + theSimplerdbmsPackage.freeze(); + + + // Update the registry and return the package + EPackage.Registry.INSTANCE.put(SimplerdbmsPackage.eNS_URI, theSimplerdbmsPackage); + return theSimplerdbmsPackage; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getColumn() { + return columnEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getColumn_Type() { + return (EAttribute)columnEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getColumn_Owner() { + return (EReference)columnEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getColumn_ForeignKeys() { + return (EReference)columnEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getColumn_Keys() { + return (EReference)columnEClass.getEStructuralFeatures().get(3); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getForeignKey() { + return foreignKeyEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getForeignKey_RefersTo() { + return (EReference)foreignKeyEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getForeignKey_Columns() { + return (EReference)foreignKeyEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getForeignKey_Owner() { + return (EReference)foreignKeyEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getKey() { + return keyEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getKey_Owner() { + return (EReference)keyEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getKey_Column() { + return (EReference)keyEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getRModelElement() { + return rModelElementEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getRModelElement_Name() { + return (EAttribute)rModelElementEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getRModelElement_Kind() { + return (EAttribute)rModelElementEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getSchema() { + return schemaEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getSchema_Tables() { + return (EReference)schemaEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getTable() { + return tableEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getTable_Columns() { + return (EReference)tableEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getTable_Schema() { + return (EReference)tableEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getTable_Keys() { + return (EReference)tableEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getTable_ForeignKeys() { + return (EReference)tableEClass.getEStructuralFeatures().get(3); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EDataType getString() { + return stringEDataType; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SimplerdbmsFactory getSimplerdbmsFactory() { + return (SimplerdbmsFactory)getEFactoryInstance(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private boolean isCreated = false; + + /** + * Creates the meta-model objects for the package. This method is + * guarded to have no affect on any invocation but its first. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void createPackageContents() { + if (isCreated) return; + isCreated = true; + + // Create classes and their features + columnEClass = createEClass(COLUMN); + createEAttribute(columnEClass, COLUMN__TYPE); + createEReference(columnEClass, COLUMN__OWNER); + createEReference(columnEClass, COLUMN__FOREIGN_KEYS); + createEReference(columnEClass, COLUMN__KEYS); + + foreignKeyEClass = createEClass(FOREIGN_KEY); + createEReference(foreignKeyEClass, FOREIGN_KEY__REFERS_TO); + createEReference(foreignKeyEClass, FOREIGN_KEY__COLUMNS); + createEReference(foreignKeyEClass, FOREIGN_KEY__OWNER); + + keyEClass = createEClass(KEY); + createEReference(keyEClass, KEY__OWNER); + createEReference(keyEClass, KEY__COLUMN); + + rModelElementEClass = createEClass(RMODEL_ELEMENT); + createEAttribute(rModelElementEClass, RMODEL_ELEMENT__NAME); + createEAttribute(rModelElementEClass, RMODEL_ELEMENT__KIND); + + schemaEClass = createEClass(SCHEMA); + createEReference(schemaEClass, SCHEMA__TABLES); + + tableEClass = createEClass(TABLE); + createEReference(tableEClass, TABLE__COLUMNS); + createEReference(tableEClass, TABLE__SCHEMA); + createEReference(tableEClass, TABLE__KEYS); + createEReference(tableEClass, TABLE__FOREIGN_KEYS); + + // Create data types + stringEDataType = createEDataType(STRING); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private boolean isInitialized = false; + + /** + * Complete the initialization of the package and its meta-model. This + * method is guarded to have no affect on any invocation but its first. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void initializePackageContents() { + if (isInitialized) return; + isInitialized = true; + + // Initialize package + setName(eNAME); + setNsPrefix(eNS_PREFIX); + setNsURI(eNS_URI); + + // Create type parameters + + // Set bounds for type parameters + + // Add supertypes to classes + columnEClass.getESuperTypes().add(this.getRModelElement()); + foreignKeyEClass.getESuperTypes().add(this.getRModelElement()); + keyEClass.getESuperTypes().add(this.getRModelElement()); + schemaEClass.getESuperTypes().add(this.getRModelElement()); + tableEClass.getESuperTypes().add(this.getRModelElement()); + + // Initialize classes, features, and operations; add parameters + initEClass(columnEClass, Column.class, "Column", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEAttribute(getColumn_Type(), ecorePackage.getEString(), "type", null, 0, 1, Column.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getColumn_Owner(), this.getTable(), this.getTable_Columns(), "owner", null, 1, 1, Column.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getColumn_ForeignKeys(), this.getForeignKey(), this.getForeignKey_Columns(), "foreignKeys", null, 0, -1, Column.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getColumn_Keys(), this.getKey(), this.getKey_Column(), "keys", null, 0, -1, Column.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(foreignKeyEClass, ForeignKey.class, "ForeignKey", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getForeignKey_RefersTo(), this.getKey(), null, "refersTo", null, 1, 1, ForeignKey.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getForeignKey_Columns(), this.getColumn(), this.getColumn_ForeignKeys(), "columns", null, 0, -1, ForeignKey.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getForeignKey_Owner(), this.getTable(), this.getTable_ForeignKeys(), "owner", null, 1, 1, ForeignKey.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(keyEClass, Key.class, "Key", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getKey_Owner(), this.getTable(), this.getTable_Keys(), "owner", null, 1, 1, Key.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getKey_Column(), this.getColumn(), this.getColumn_Keys(), "column", null, 0, -1, Key.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(rModelElementEClass, RModelElement.class, "RModelElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEAttribute(getRModelElement_Name(), ecorePackage.getEString(), "name", null, 0, 1, RModelElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEAttribute(getRModelElement_Kind(), ecorePackage.getEString(), "kind", null, 0, 1, RModelElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(schemaEClass, Schema.class, "Schema", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getSchema_Tables(), this.getTable(), this.getTable_Schema(), "tables", null, 0, -1, Schema.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(tableEClass, Table.class, "Table", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getTable_Columns(), this.getColumn(), this.getColumn_Owner(), "columns", null, 0, -1, Table.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getTable_Schema(), this.getSchema(), this.getSchema_Tables(), "schema", null, 1, 1, Table.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getTable_Keys(), this.getKey(), this.getKey_Owner(), "keys", null, 0, -1, Table.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getTable_ForeignKeys(), this.getForeignKey(), this.getForeignKey_Owner(), "foreignKeys", null, 0, -1, Table.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + // Initialize data types + initEDataType(stringEDataType, Object.class, "String", IS_SERIALIZABLE, !IS_GENERATED_INSTANCE_CLASS); + + // Create resource + createResource(eNS_URI); + } + +} //SimplerdbmsPackageImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/TableImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/TableImpl.java new file mode 100644 index 000000000..2de7efcc0 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/impl/TableImpl.java @@ -0,0 +1,328 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.EcoreUtil; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Table</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.TableImpl#getColumns <em>Columns</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.TableImpl#getSchema <em>Schema</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.TableImpl#getKeys <em>Keys</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.TableImpl#getForeignKeys <em>Foreign Keys</em>}</li> + * </ul> + * + * @generated + */ +public class TableImpl extends RModelElementImpl implements Table { + /** + * The cached value of the '{@link #getColumns() <em>Columns</em>}' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getColumns() + * @generated + * @ordered + */ + protected EList<Column> columns; + + /** + * The cached value of the '{@link #getKeys() <em>Keys</em>}' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getKeys() + * @generated + * @ordered + */ + protected EList<Key> keys; + + /** + * The cached value of the '{@link #getForeignKeys() <em>Foreign Keys</em>}' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getForeignKeys() + * @generated + * @ordered + */ + protected EList<ForeignKey> foreignKeys; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected TableImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimplerdbmsPackage.Literals.TABLE; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<Column> getColumns() { + if (columns == null) { + columns = new EObjectContainmentWithInverseEList<Column>(Column.class, this, SimplerdbmsPackage.TABLE__COLUMNS, SimplerdbmsPackage.COLUMN__OWNER); + } + return columns; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Schema getSchema() { + if (eContainerFeatureID() != SimplerdbmsPackage.TABLE__SCHEMA) return null; + return (Schema)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetSchema(Schema newSchema, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newSchema, SimplerdbmsPackage.TABLE__SCHEMA, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setSchema(Schema newSchema) { + if (newSchema != eInternalContainer() || (eContainerFeatureID() != SimplerdbmsPackage.TABLE__SCHEMA && newSchema != null)) { + if (EcoreUtil.isAncestor(this, newSchema)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newSchema != null) + msgs = ((InternalEObject)newSchema).eInverseAdd(this, SimplerdbmsPackage.SCHEMA__TABLES, Schema.class, msgs); + msgs = basicSetSchema(newSchema, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimplerdbmsPackage.TABLE__SCHEMA, newSchema, newSchema)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<Key> getKeys() { + if (keys == null) { + keys = new EObjectContainmentWithInverseEList<Key>(Key.class, this, SimplerdbmsPackage.TABLE__KEYS, SimplerdbmsPackage.KEY__OWNER); + } + return keys; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<ForeignKey> getForeignKeys() { + if (foreignKeys == null) { + foreignKeys = new EObjectContainmentWithInverseEList<ForeignKey>(ForeignKey.class, this, SimplerdbmsPackage.TABLE__FOREIGN_KEYS, SimplerdbmsPackage.FOREIGN_KEY__OWNER); + } + return foreignKeys; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimplerdbmsPackage.TABLE__COLUMNS: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getColumns()).basicAdd(otherEnd, msgs); + case SimplerdbmsPackage.TABLE__SCHEMA: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetSchema((Schema)otherEnd, msgs); + case SimplerdbmsPackage.TABLE__KEYS: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getKeys()).basicAdd(otherEnd, msgs); + case SimplerdbmsPackage.TABLE__FOREIGN_KEYS: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getForeignKeys()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimplerdbmsPackage.TABLE__COLUMNS: + return ((InternalEList<?>)getColumns()).basicRemove(otherEnd, msgs); + case SimplerdbmsPackage.TABLE__SCHEMA: + return basicSetSchema(null, msgs); + case SimplerdbmsPackage.TABLE__KEYS: + return ((InternalEList<?>)getKeys()).basicRemove(otherEnd, msgs); + case SimplerdbmsPackage.TABLE__FOREIGN_KEYS: + return ((InternalEList<?>)getForeignKeys()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case SimplerdbmsPackage.TABLE__SCHEMA: + return eInternalContainer().eInverseRemove(this, SimplerdbmsPackage.SCHEMA__TABLES, Schema.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimplerdbmsPackage.TABLE__COLUMNS: + return getColumns(); + case SimplerdbmsPackage.TABLE__SCHEMA: + return getSchema(); + case SimplerdbmsPackage.TABLE__KEYS: + return getKeys(); + case SimplerdbmsPackage.TABLE__FOREIGN_KEYS: + return getForeignKeys(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimplerdbmsPackage.TABLE__COLUMNS: + getColumns().clear(); + getColumns().addAll((Collection<? extends Column>)newValue); + return; + case SimplerdbmsPackage.TABLE__SCHEMA: + setSchema((Schema)newValue); + return; + case SimplerdbmsPackage.TABLE__KEYS: + getKeys().clear(); + getKeys().addAll((Collection<? extends Key>)newValue); + return; + case SimplerdbmsPackage.TABLE__FOREIGN_KEYS: + getForeignKeys().clear(); + getForeignKeys().addAll((Collection<? extends ForeignKey>)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.TABLE__COLUMNS: + getColumns().clear(); + return; + case SimplerdbmsPackage.TABLE__SCHEMA: + setSchema((Schema)null); + return; + case SimplerdbmsPackage.TABLE__KEYS: + getKeys().clear(); + return; + case SimplerdbmsPackage.TABLE__FOREIGN_KEYS: + getForeignKeys().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimplerdbmsPackage.TABLE__COLUMNS: + return columns != null && !columns.isEmpty(); + case SimplerdbmsPackage.TABLE__SCHEMA: + return getSchema() != null; + case SimplerdbmsPackage.TABLE__KEYS: + return keys != null && !keys.isEmpty(); + case SimplerdbmsPackage.TABLE__FOREIGN_KEYS: + return foreignKeys != null && !foreignKeys.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //TableImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/util/SimplerdbmsAdapterFactory.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/util/SimplerdbmsAdapterFactory.java new file mode 100644 index 000000000..38458a11a --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/util/SimplerdbmsAdapterFactory.java @@ -0,0 +1,218 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.util; + +import org.eclipse.emf.common.notify.Adapter; +import org.eclipse.emf.common.notify.Notifier; + +import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; + +import org.eclipse.emf.ecore.EObject; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.*; + +/** + * <!-- begin-user-doc --> + * The <b>Adapter Factory</b> for the model. + * It provides an adapter <code>createXXX</code> method for each class of the model. + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage + * @generated + */ +public class SimplerdbmsAdapterFactory extends AdapterFactoryImpl { + /** + * The cached model package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected static SimplerdbmsPackage modelPackage; + + /** + * Creates an instance of the adapter factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SimplerdbmsAdapterFactory() { + if (modelPackage == null) { + modelPackage = SimplerdbmsPackage.eINSTANCE; + } + } + + /** + * Returns whether this factory is applicable for the type of the object. + * <!-- begin-user-doc --> + * This implementation returns <code>true</code> if the object is either the model's package or is an instance object of the model. + * <!-- end-user-doc --> + * @return whether this factory is applicable for the type of the object. + * @generated + */ + @Override + public boolean isFactoryForType(Object object) { + if (object == modelPackage) { + return true; + } + if (object instanceof EObject) { + return ((EObject)object).eClass().getEPackage() == modelPackage; + } + return false; + } + + /** + * The switch that delegates to the <code>createXXX</code> methods. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected SimplerdbmsSwitch<Adapter> modelSwitch = + new SimplerdbmsSwitch<Adapter>() { + @Override + public Adapter caseColumn(Column object) { + return createColumnAdapter(); + } + @Override + public Adapter caseForeignKey(ForeignKey object) { + return createForeignKeyAdapter(); + } + @Override + public Adapter caseKey(Key object) { + return createKeyAdapter(); + } + @Override + public Adapter caseRModelElement(RModelElement object) { + return createRModelElementAdapter(); + } + @Override + public Adapter caseSchema(Schema object) { + return createSchemaAdapter(); + } + @Override + public Adapter caseTable(Table object) { + return createTableAdapter(); + } + @Override + public Adapter defaultCase(EObject object) { + return createEObjectAdapter(); + } + }; + + /** + * Creates an adapter for the <code>target</code>. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param target the object to adapt. + * @return the adapter for the <code>target</code>. + * @generated + */ + @Override + public Adapter createAdapter(Notifier target) { + return modelSwitch.doSwitch((EObject)target); + } + + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column <em>Column</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column + * @generated + */ + public Adapter createColumnAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey <em>Foreign Key</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey + * @generated + */ + public Adapter createForeignKeyAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key <em>Key</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key + * @generated + */ + public Adapter createKeyAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement <em>RModel Element</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.RModelElement + * @generated + */ + public Adapter createRModelElementAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema <em>Schema</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema + * @generated + */ + public Adapter createSchemaAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table <em>Table</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table + * @generated + */ + public Adapter createTableAdapter() { + return null; + } + + /** + * Creates a new adapter for the default case. + * <!-- begin-user-doc --> + * This default implementation returns null. + * <!-- end-user-doc --> + * @return the new adapter. + * @generated + */ + public Adapter createEObjectAdapter() { + return null; + } + +} //SimplerdbmsAdapterFactory diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/util/SimplerdbmsSwitch.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/util/SimplerdbmsSwitch.java new file mode 100644 index 000000000..b9097da7b --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simplerdbms/util/SimplerdbmsSwitch.java @@ -0,0 +1,228 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.util; + +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.util.Switch; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.*; + +/** + * <!-- begin-user-doc --> + * The <b>Switch</b> for the model's inheritance hierarchy. + * It supports the call {@link #doSwitch(EObject) doSwitch(object)} + * to invoke the <code>caseXXX</code> method for each class of the model, + * starting with the actual class of the object + * and proceeding up the inheritance hierarchy + * until a non-null result is returned, + * which is the result of the switch. + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage + * @generated + */ +public class SimplerdbmsSwitch<T> extends Switch<T> { + /** + * The cached model package + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected static SimplerdbmsPackage modelPackage; + + /** + * Creates an instance of the switch. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SimplerdbmsSwitch() { + if (modelPackage == null) { + modelPackage = SimplerdbmsPackage.eINSTANCE; + } + } + + /** + * Checks whether this is a switch for the given package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param ePackage the package in question. + * @return whether this is a switch for the given package. + * @generated + */ + @Override + protected boolean isSwitchFor(EPackage ePackage) { + return ePackage == modelPackage; + } + + /** + * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the first non-null result returned by a <code>caseXXX</code> call. + * @generated + */ + @Override + protected T doSwitch(int classifierID, EObject theEObject) { + switch (classifierID) { + case SimplerdbmsPackage.COLUMN: { + Column column = (Column)theEObject; + T result = caseColumn(column); + if (result == null) result = caseRModelElement(column); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimplerdbmsPackage.FOREIGN_KEY: { + ForeignKey foreignKey = (ForeignKey)theEObject; + T result = caseForeignKey(foreignKey); + if (result == null) result = caseRModelElement(foreignKey); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimplerdbmsPackage.KEY: { + Key key = (Key)theEObject; + T result = caseKey(key); + if (result == null) result = caseRModelElement(key); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimplerdbmsPackage.RMODEL_ELEMENT: { + RModelElement rModelElement = (RModelElement)theEObject; + T result = caseRModelElement(rModelElement); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimplerdbmsPackage.SCHEMA: { + Schema schema = (Schema)theEObject; + T result = caseSchema(schema); + if (result == null) result = caseRModelElement(schema); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimplerdbmsPackage.TABLE: { + Table table = (Table)theEObject; + T result = caseTable(table); + if (result == null) result = caseRModelElement(table); + if (result == null) result = defaultCase(theEObject); + return result; + } + default: return defaultCase(theEObject); + } + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Column</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Column</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseColumn(Column object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Foreign Key</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Foreign Key</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseForeignKey(ForeignKey object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Key</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Key</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseKey(Key object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>RModel Element</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>RModel Element</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseRModelElement(RModelElement object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Schema</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Schema</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseSchema(Schema object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Table</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Table</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseTable(Table object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>EObject</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch, but this is the last case anyway. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>EObject</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) + * @generated + */ + @Override + public T defaultCase(EObject object) { + return null; + } + +} //SimplerdbmsSwitch diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Association.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Association.java new file mode 100644 index 000000000..d9092c59e --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Association.java @@ -0,0 +1,88 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml; + + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Association</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getDestination <em>Destination</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getSource <em>Source</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getAssociation() + * @model + * @generated + */ +public interface Association extends PackageElement { + /** + * Returns the value of the '<em><b>Destination</b></em>' reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getReverse <em>Reverse</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Destination</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Destination</em>' reference. + * @see #setDestination(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getAssociation_Destination() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getReverse + * @model opposite="reverse" required="true" + * @generated + */ + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class getDestination(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getDestination <em>Destination</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Destination</em>' reference. + * @see #getDestination() + * @generated + */ + void setDestination(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class value); + + /** + * Returns the value of the '<em><b>Source</b></em>' reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getForward <em>Forward</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Source</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Source</em>' reference. + * @see #setSource(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getAssociation_Source() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getForward + * @model opposite="forward" required="true" + * @generated + */ + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class getSource(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getSource <em>Source</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Source</em>' reference. + * @see #getSource() + * @generated + */ + void setSource(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class value); + +} // Association diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Attribute.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Attribute.java new file mode 100644 index 000000000..8b83bcd22 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Attribute.java @@ -0,0 +1,88 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml; + + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Attribute</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getType <em>Type</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getAttribute() + * @model + * @generated + */ +public interface Attribute extends UMLModelElement { + /** + * Returns the value of the '<em><b>Owner</b></em>' container reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getAttributes <em>Attributes</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Owner</em>' container reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Owner</em>' container reference. + * @see #setOwner(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getAttribute_Owner() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getAttributes + * @model opposite="attributes" required="true" transient="false" + * @generated + */ + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class getOwner(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getOwner <em>Owner</em>}' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Owner</em>' container reference. + * @see #getOwner() + * @generated + */ + void setOwner(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class value); + + /** + * Returns the value of the '<em><b>Type</b></em>' reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier#getTypeOpposite <em>Type Opposite</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Type</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Type</em>' reference. + * @see #setType(Classifier) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getAttribute_Type() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier#getTypeOpposite + * @model opposite="typeOpposite" required="true" + * @generated + */ + Classifier getType(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getType <em>Type</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Type</em>' reference. + * @see #getType() + * @generated + */ + void setType(Classifier value); + +} // Attribute diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Class.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Class.java new file mode 100644 index 000000000..e6890fb53 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Class.java @@ -0,0 +1,126 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Class</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getAttributes <em>Attributes</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getForward <em>Forward</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getGeneral <em>General</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getGeneralOpposite <em>General Opposite</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getReverse <em>Reverse</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getClass_() + * @model + * @generated + */ +public interface Class extends Classifier { + /** + * Returns the value of the '<em><b>Attributes</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Attributes</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Attributes</em>' containment reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getClass_Attributes() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getOwner + * @model opposite="owner" containment="true" + * @generated + */ + EList<Attribute> getAttributes(); + + /** + * Returns the value of the '<em><b>Forward</b></em>' reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getSource <em>Source</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Forward</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Forward</em>' reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getClass_Forward() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getSource + * @model opposite="source" + * @generated + */ + EList<Association> getForward(); + + /** + * Returns the value of the '<em><b>General</b></em>' reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getGeneralOpposite <em>General Opposite</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>General</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>General</em>' reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getClass_General() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getGeneralOpposite + * @model opposite="generalOpposite" + * @generated + */ + EList<Class> getGeneral(); + + /** + * Returns the value of the '<em><b>General Opposite</b></em>' reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getGeneral <em>General</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>General Opposite</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>General Opposite</em>' reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getClass_GeneralOpposite() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getGeneral + * @model opposite="general" + * @generated + */ + EList<Class> getGeneralOpposite(); + + /** + * Returns the value of the '<em><b>Reverse</b></em>' reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getDestination <em>Destination</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Reverse</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Reverse</em>' reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getClass_Reverse() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getDestination + * @model opposite="destination" derived="true" + * @generated + */ + EList<Association> getReverse(); + +} // Class diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Classifier.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Classifier.java new file mode 100644 index 000000000..a7c12e4a5 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Classifier.java @@ -0,0 +1,50 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Classifier</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier#getTypeOpposite <em>Type Opposite</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getClassifier() + * @model abstract="true" + * @generated + */ +public interface Classifier extends PackageElement { + /** + * Returns the value of the '<em><b>Type Opposite</b></em>' reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getType <em>Type</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Type Opposite</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Type Opposite</em>' reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getClassifier_TypeOpposite() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getType + * @model opposite="type" + * @generated + */ + EList<Attribute> getTypeOpposite(); + +} // Classifier diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Package.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Package.java new file mode 100644 index 000000000..b3b56879b --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/Package.java @@ -0,0 +1,50 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Package</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package#getElements <em>Elements</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getPackage() + * @model + * @generated + */ +public interface Package extends UMLModelElement { + /** + * Returns the value of the '<em><b>Elements</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement#getNamespace <em>Namespace</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Elements</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Elements</em>' containment reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getPackage_Elements() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement#getNamespace + * @model opposite="namespace" containment="true" + * @generated + */ + EList<PackageElement> getElements(); + +} // Package diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/PackageElement.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/PackageElement.java new file mode 100644 index 000000000..9d86a85a9 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/PackageElement.java @@ -0,0 +1,59 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml; + + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Package Element</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement#getNamespace <em>Namespace</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getPackageElement() + * @model abstract="true" + * @generated + */ +public interface PackageElement extends UMLModelElement { + /** + * Returns the value of the '<em><b>Namespace</b></em>' container reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package#getElements <em>Elements</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Namespace</em>' container reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Namespace</em>' container reference. + * @see #setNamespace(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getPackageElement_Namespace() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package#getElements + * @model opposite="elements" required="true" transient="false" + * @generated + */ + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package getNamespace(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement#getNamespace <em>Namespace</em>}' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Namespace</em>' container reference. + * @see #getNamespace() + * @generated + */ + void setNamespace(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package value); + +} // PackageElement diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/PrimitiveDataType.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/PrimitiveDataType.java new file mode 100644 index 000000000..20d357558 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/PrimitiveDataType.java @@ -0,0 +1,25 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml; + + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Primitive Data Type</b></em>'. + * <!-- end-user-doc --> + * + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getPrimitiveDataType() + * @model + * @generated + */ +public interface PrimitiveDataType extends Classifier { +} // PrimitiveDataType diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/SimpleumlFactory.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/SimpleumlFactory.java new file mode 100644 index 000000000..f634fa3be --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/SimpleumlFactory.java @@ -0,0 +1,86 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml; + +import org.eclipse.emf.ecore.EFactory; + +/** + * <!-- begin-user-doc --> + * The <b>Factory</b> for the model. + * It provides a create method for each non-abstract class of the model. + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage + * @generated + */ +public interface SimpleumlFactory extends EFactory { + /** + * The singleton instance of the factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + SimpleumlFactory eINSTANCE = org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlFactoryImpl.init(); + + /** + * Returns a new object of class '<em>Attribute</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Attribute</em>'. + * @generated + */ + Attribute createAttribute(); + + /** + * Returns a new object of class '<em>Association</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Association</em>'. + * @generated + */ + Association createAssociation(); + + /** + * Returns a new object of class '<em>Class</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Class</em>'. + * @generated + */ + Class createClass(); + + /** + * Returns a new object of class '<em>Package</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Package</em>'. + * @generated + */ + Package createPackage(); + + /** + * Returns a new object of class '<em>Primitive Data Type</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Primitive Data Type</em>'. + * @generated + */ + PrimitiveDataType createPrimitiveDataType(); + + /** + * Returns the package supported by this factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the package supported by this factory. + * @generated + */ + SimpleumlPackage getSimpleumlPackage(); + +} //SimpleumlFactory diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/SimpleumlPackage.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/SimpleumlPackage.java new file mode 100644 index 000000000..e4f998dc7 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/SimpleumlPackage.java @@ -0,0 +1,1049 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml; + +import org.eclipse.emf.ecore.EAttribute; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +/** + * <!-- begin-user-doc --> + * The <b>Package</b> for the model. + * It contains accessors for the meta objects to represent + * <ul> + * <li>each class,</li> + * <li>each feature of each class,</li> + * <li>each operation of each class,</li> + * <li>each enum,</li> + * <li>and each data type</li> + * </ul> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlFactory + * @model kind="package" + * @generated + */ +public interface SimpleumlPackage extends EPackage { + /** + * The package name. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNAME = "simpleuml"; + + /** + * The package namespace URI. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNS_URI = "http://www.eclipse.org/qvtd/examples/qvtcore/UML2RDBMS/1.0/simpleUML"; + + /** + * The package namespace name. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNS_PREFIX = "simpleuml"; + + /** + * The singleton instance of the package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + SimpleumlPackage eINSTANCE = org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl.init(); + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.UMLModelElementImpl <em>UML Model Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.UMLModelElementImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getUMLModelElement() + * @generated + */ + int UML_MODEL_ELEMENT = 7; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int UML_MODEL_ELEMENT__KIND = 0; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int UML_MODEL_ELEMENT__NAME = 1; + + /** + * The number of structural features of the '<em>UML Model Element</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int UML_MODEL_ELEMENT_FEATURE_COUNT = 2; + + /** + * The number of operations of the '<em>UML Model Element</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int UML_MODEL_ELEMENT_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AttributeImpl <em>Attribute</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AttributeImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getAttribute() + * @generated + */ + int ATTRIBUTE = 0; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE__KIND = UML_MODEL_ELEMENT__KIND; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE__NAME = UML_MODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE__OWNER = UML_MODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Type</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE__TYPE = UML_MODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The number of structural features of the '<em>Attribute</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_FEATURE_COUNT = UML_MODEL_ELEMENT_FEATURE_COUNT + 2; + + /** + * The number of operations of the '<em>Attribute</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_OPERATION_COUNT = UML_MODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PackageElementImpl <em>Package Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PackageElementImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getPackageElement() + * @generated + */ + int PACKAGE_ELEMENT = 5; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_ELEMENT__KIND = UML_MODEL_ELEMENT__KIND; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_ELEMENT__NAME = UML_MODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Namespace</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_ELEMENT__NAMESPACE = UML_MODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The number of structural features of the '<em>Package Element</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_ELEMENT_FEATURE_COUNT = UML_MODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The number of operations of the '<em>Package Element</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_ELEMENT_OPERATION_COUNT = UML_MODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AssociationImpl <em>Association</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AssociationImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getAssociation() + * @generated + */ + int ASSOCIATION = 1; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION__KIND = PACKAGE_ELEMENT__KIND; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION__NAME = PACKAGE_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Namespace</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION__NAMESPACE = PACKAGE_ELEMENT__NAMESPACE; + + /** + * The feature id for the '<em><b>Destination</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION__DESTINATION = PACKAGE_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Source</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION__SOURCE = PACKAGE_ELEMENT_FEATURE_COUNT + 1; + + /** + * The number of structural features of the '<em>Association</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION_FEATURE_COUNT = PACKAGE_ELEMENT_FEATURE_COUNT + 2; + + /** + * The number of operations of the '<em>Association</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION_OPERATION_COUNT = PACKAGE_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassifierImpl <em>Classifier</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassifierImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getClassifier() + * @generated + */ + int CLASSIFIER = 3; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASSIFIER__KIND = PACKAGE_ELEMENT__KIND; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASSIFIER__NAME = PACKAGE_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Namespace</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASSIFIER__NAMESPACE = PACKAGE_ELEMENT__NAMESPACE; + + /** + * The feature id for the '<em><b>Type Opposite</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASSIFIER__TYPE_OPPOSITE = PACKAGE_ELEMENT_FEATURE_COUNT + 0; + + /** + * The number of structural features of the '<em>Classifier</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASSIFIER_FEATURE_COUNT = PACKAGE_ELEMENT_FEATURE_COUNT + 1; + + /** + * The number of operations of the '<em>Classifier</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASSIFIER_OPERATION_COUNT = PACKAGE_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassImpl <em>Class</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getClass_() + * @generated + */ + int CLASS = 2; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS__KIND = CLASSIFIER__KIND; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS__NAME = CLASSIFIER__NAME; + + /** + * The feature id for the '<em><b>Namespace</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS__NAMESPACE = CLASSIFIER__NAMESPACE; + + /** + * The feature id for the '<em><b>Type Opposite</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS__TYPE_OPPOSITE = CLASSIFIER__TYPE_OPPOSITE; + + /** + * The feature id for the '<em><b>Attributes</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS__ATTRIBUTES = CLASSIFIER_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Forward</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS__FORWARD = CLASSIFIER_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>General</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS__GENERAL = CLASSIFIER_FEATURE_COUNT + 2; + + /** + * The feature id for the '<em><b>General Opposite</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS__GENERAL_OPPOSITE = CLASSIFIER_FEATURE_COUNT + 3; + + /** + * The feature id for the '<em><b>Reverse</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS__REVERSE = CLASSIFIER_FEATURE_COUNT + 4; + + /** + * The number of structural features of the '<em>Class</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_FEATURE_COUNT = CLASSIFIER_FEATURE_COUNT + 5; + + /** + * The number of operations of the '<em>Class</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_OPERATION_COUNT = CLASSIFIER_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PackageImpl <em>Package</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PackageImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getPackage() + * @generated + */ + int PACKAGE = 4; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE__KIND = UML_MODEL_ELEMENT__KIND; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE__NAME = UML_MODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Elements</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE__ELEMENTS = UML_MODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The number of structural features of the '<em>Package</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_FEATURE_COUNT = UML_MODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The number of operations of the '<em>Package</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_OPERATION_COUNT = UML_MODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PrimitiveDataTypeImpl <em>Primitive Data Type</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PrimitiveDataTypeImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getPrimitiveDataType() + * @generated + */ + int PRIMITIVE_DATA_TYPE = 6; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_DATA_TYPE__KIND = CLASSIFIER__KIND; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_DATA_TYPE__NAME = CLASSIFIER__NAME; + + /** + * The feature id for the '<em><b>Namespace</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_DATA_TYPE__NAMESPACE = CLASSIFIER__NAMESPACE; + + /** + * The feature id for the '<em><b>Type Opposite</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_DATA_TYPE__TYPE_OPPOSITE = CLASSIFIER__TYPE_OPPOSITE; + + /** + * The number of structural features of the '<em>Primitive Data Type</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_DATA_TYPE_FEATURE_COUNT = CLASSIFIER_FEATURE_COUNT + 0; + + /** + * The number of operations of the '<em>Primitive Data Type</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_DATA_TYPE_OPERATION_COUNT = CLASSIFIER_OPERATION_COUNT + 0; + + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute <em>Attribute</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Attribute</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute + * @generated + */ + EClass getAttribute(); + + /** + * Returns the meta object for the container reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the container reference '<em>Owner</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getOwner() + * @see #getAttribute() + * @generated + */ + EReference getAttribute_Owner(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getType <em>Type</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Type</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute#getType() + * @see #getAttribute() + * @generated + */ + EReference getAttribute_Type(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association <em>Association</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Association</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association + * @generated + */ + EClass getAssociation(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getDestination <em>Destination</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Destination</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getDestination() + * @see #getAssociation() + * @generated + */ + EReference getAssociation_Destination(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getSource <em>Source</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Source</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association#getSource() + * @see #getAssociation() + * @generated + */ + EReference getAssociation_Source(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class <em>Class</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Class</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class + * @generated + */ + EClass getClass_(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getAttributes <em>Attributes</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Attributes</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getAttributes() + * @see #getClass_() + * @generated + */ + EReference getClass_Attributes(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getForward <em>Forward</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Forward</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getForward() + * @see #getClass_() + * @generated + */ + EReference getClass_Forward(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getGeneral <em>General</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>General</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getGeneral() + * @see #getClass_() + * @generated + */ + EReference getClass_General(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getGeneralOpposite <em>General Opposite</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>General Opposite</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getGeneralOpposite() + * @see #getClass_() + * @generated + */ + EReference getClass_GeneralOpposite(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getReverse <em>Reverse</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Reverse</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class#getReverse() + * @see #getClass_() + * @generated + */ + EReference getClass_Reverse(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier <em>Classifier</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Classifier</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier + * @generated + */ + EClass getClassifier(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier#getTypeOpposite <em>Type Opposite</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Type Opposite</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier#getTypeOpposite() + * @see #getClassifier() + * @generated + */ + EReference getClassifier_TypeOpposite(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package <em>Package</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Package</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package + * @generated + */ + EClass getPackage(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package#getElements <em>Elements</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Elements</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package#getElements() + * @see #getPackage() + * @generated + */ + EReference getPackage_Elements(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement <em>Package Element</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Package Element</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement + * @generated + */ + EClass getPackageElement(); + + /** + * Returns the meta object for the container reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement#getNamespace <em>Namespace</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the container reference '<em>Namespace</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement#getNamespace() + * @see #getPackageElement() + * @generated + */ + EReference getPackageElement_Namespace(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType <em>Primitive Data Type</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Primitive Data Type</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType + * @generated + */ + EClass getPrimitiveDataType(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement <em>UML Model Element</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>UML Model Element</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement + * @generated + */ + EClass getUMLModelElement(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement#getKind <em>Kind</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Kind</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement#getKind() + * @see #getUMLModelElement() + * @generated + */ + EAttribute getUMLModelElement_Kind(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement#getName <em>Name</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Name</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement#getName() + * @see #getUMLModelElement() + * @generated + */ + EAttribute getUMLModelElement_Name(); + + /** + * Returns the factory that creates the instances of the model. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the factory that creates the instances of the model. + * @generated + */ + SimpleumlFactory getSimpleumlFactory(); + + /** + * <!-- begin-user-doc --> + * Defines literals for the meta objects that represent + * <ul> + * <li>each class,</li> + * <li>each feature of each class,</li> + * <li>each operation of each class,</li> + * <li>each enum,</li> + * <li>and each data type</li> + * </ul> + * <!-- end-user-doc --> + * @generated + */ + interface Literals { + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AttributeImpl <em>Attribute</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AttributeImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getAttribute() + * @generated + */ + EClass ATTRIBUTE = eINSTANCE.getAttribute(); + + /** + * The meta object literal for the '<em><b>Owner</b></em>' container reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ATTRIBUTE__OWNER = eINSTANCE.getAttribute_Owner(); + + /** + * The meta object literal for the '<em><b>Type</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ATTRIBUTE__TYPE = eINSTANCE.getAttribute_Type(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AssociationImpl <em>Association</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AssociationImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getAssociation() + * @generated + */ + EClass ASSOCIATION = eINSTANCE.getAssociation(); + + /** + * The meta object literal for the '<em><b>Destination</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ASSOCIATION__DESTINATION = eINSTANCE.getAssociation_Destination(); + + /** + * The meta object literal for the '<em><b>Source</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ASSOCIATION__SOURCE = eINSTANCE.getAssociation_Source(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassImpl <em>Class</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getClass_() + * @generated + */ + EClass CLASS = eINSTANCE.getClass_(); + + /** + * The meta object literal for the '<em><b>Attributes</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASS__ATTRIBUTES = eINSTANCE.getClass_Attributes(); + + /** + * The meta object literal for the '<em><b>Forward</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASS__FORWARD = eINSTANCE.getClass_Forward(); + + /** + * The meta object literal for the '<em><b>General</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASS__GENERAL = eINSTANCE.getClass_General(); + + /** + * The meta object literal for the '<em><b>General Opposite</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASS__GENERAL_OPPOSITE = eINSTANCE.getClass_GeneralOpposite(); + + /** + * The meta object literal for the '<em><b>Reverse</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASS__REVERSE = eINSTANCE.getClass_Reverse(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassifierImpl <em>Classifier</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassifierImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getClassifier() + * @generated + */ + EClass CLASSIFIER = eINSTANCE.getClassifier(); + + /** + * The meta object literal for the '<em><b>Type Opposite</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASSIFIER__TYPE_OPPOSITE = eINSTANCE.getClassifier_TypeOpposite(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PackageImpl <em>Package</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PackageImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getPackage() + * @generated + */ + EClass PACKAGE = eINSTANCE.getPackage(); + + /** + * The meta object literal for the '<em><b>Elements</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference PACKAGE__ELEMENTS = eINSTANCE.getPackage_Elements(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PackageElementImpl <em>Package Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PackageElementImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getPackageElement() + * @generated + */ + EClass PACKAGE_ELEMENT = eINSTANCE.getPackageElement(); + + /** + * The meta object literal for the '<em><b>Namespace</b></em>' container reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference PACKAGE_ELEMENT__NAMESPACE = eINSTANCE.getPackageElement_Namespace(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PrimitiveDataTypeImpl <em>Primitive Data Type</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PrimitiveDataTypeImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getPrimitiveDataType() + * @generated + */ + EClass PRIMITIVE_DATA_TYPE = eINSTANCE.getPrimitiveDataType(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.UMLModelElementImpl <em>UML Model Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.UMLModelElementImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl#getUMLModelElement() + * @generated + */ + EClass UML_MODEL_ELEMENT = eINSTANCE.getUMLModelElement(); + + /** + * The meta object literal for the '<em><b>Kind</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute UML_MODEL_ELEMENT__KIND = eINSTANCE.getUMLModelElement_Kind(); + + /** + * The meta object literal for the '<em><b>Name</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute UML_MODEL_ELEMENT__NAME = eINSTANCE.getUMLModelElement_Name(); + + } + +} //SimpleumlPackage diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/UMLModelElement.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/UMLModelElement.java new file mode 100644 index 000000000..38f25c2d7 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/UMLModelElement.java @@ -0,0 +1,85 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml; + +import org.eclipse.emf.ecore.EObject; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>UML Model Element</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement#getKind <em>Kind</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement#getName <em>Name</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getUMLModelElement() + * @model abstract="true" + * @generated + */ +public interface UMLModelElement extends EObject { + /** + * Returns the value of the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Kind</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Kind</em>' attribute. + * @see #setKind(String) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getUMLModelElement_Kind() + * @model + * @generated + */ + String getKind(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement#getKind <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Kind</em>' attribute. + * @see #getKind() + * @generated + */ + void setKind(String value); + + /** + * Returns the value of the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Name</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Name</em>' attribute. + * @see #setName(String) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#getUMLModelElement_Name() + * @model + * @generated + */ + String getName(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement#getName <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Name</em>' attribute. + * @see #getName() + * @generated + */ + void setName(String value); + +} // UMLModelElement diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/AssociationImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/AssociationImpl.java new file mode 100644 index 000000000..6b1371773 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/AssociationImpl.java @@ -0,0 +1,304 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Association</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AssociationImpl#getDestination <em>Destination</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AssociationImpl#getSource <em>Source</em>}</li> + * </ul> + * + * @generated + */ +public class AssociationImpl extends PackageElementImpl implements Association { + /** + * The cached value of the '{@link #getDestination() <em>Destination</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getDestination() + * @generated + * @ordered + */ + protected org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class destination; + + /** + * The cached value of the '{@link #getSource() <em>Source</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getSource() + * @generated + * @ordered + */ + protected org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class source; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected AssociationImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimpleumlPackage.Literals.ASSOCIATION; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class getDestination() { + if (destination != null && destination.eIsProxy()) { + InternalEObject oldDestination = (InternalEObject)destination; + destination = (org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)eResolveProxy(oldDestination); + if (destination != oldDestination) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, SimpleumlPackage.ASSOCIATION__DESTINATION, oldDestination, destination)); + } + } + return destination; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class basicGetDestination() { + return destination; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetDestination(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class newDestination, NotificationChain msgs) { + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class oldDestination = destination; + destination = newDestination; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, SimpleumlPackage.ASSOCIATION__DESTINATION, oldDestination, newDestination); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setDestination(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class newDestination) { + if (newDestination != destination) { + NotificationChain msgs = null; + if (destination != null) + msgs = ((InternalEObject)destination).eInverseRemove(this, SimpleumlPackage.CLASS__REVERSE, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, msgs); + if (newDestination != null) + msgs = ((InternalEObject)newDestination).eInverseAdd(this, SimpleumlPackage.CLASS__REVERSE, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, msgs); + msgs = basicSetDestination(newDestination, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimpleumlPackage.ASSOCIATION__DESTINATION, newDestination, newDestination)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class getSource() { + if (source != null && source.eIsProxy()) { + InternalEObject oldSource = (InternalEObject)source; + source = (org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)eResolveProxy(oldSource); + if (source != oldSource) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, SimpleumlPackage.ASSOCIATION__SOURCE, oldSource, source)); + } + } + return source; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class basicGetSource() { + return source; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetSource(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class newSource, NotificationChain msgs) { + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class oldSource = source; + source = newSource; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, SimpleumlPackage.ASSOCIATION__SOURCE, oldSource, newSource); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setSource(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class newSource) { + if (newSource != source) { + NotificationChain msgs = null; + if (source != null) + msgs = ((InternalEObject)source).eInverseRemove(this, SimpleumlPackage.CLASS__FORWARD, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, msgs); + if (newSource != null) + msgs = ((InternalEObject)newSource).eInverseAdd(this, SimpleumlPackage.CLASS__FORWARD, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, msgs); + msgs = basicSetSource(newSource, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimpleumlPackage.ASSOCIATION__SOURCE, newSource, newSource)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.ASSOCIATION__DESTINATION: + if (destination != null) + msgs = ((InternalEObject)destination).eInverseRemove(this, SimpleumlPackage.CLASS__REVERSE, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, msgs); + return basicSetDestination((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)otherEnd, msgs); + case SimpleumlPackage.ASSOCIATION__SOURCE: + if (source != null) + msgs = ((InternalEObject)source).eInverseRemove(this, SimpleumlPackage.CLASS__FORWARD, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, msgs); + return basicSetSource((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.ASSOCIATION__DESTINATION: + return basicSetDestination(null, msgs); + case SimpleumlPackage.ASSOCIATION__SOURCE: + return basicSetSource(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimpleumlPackage.ASSOCIATION__DESTINATION: + if (resolve) return getDestination(); + return basicGetDestination(); + case SimpleumlPackage.ASSOCIATION__SOURCE: + if (resolve) return getSource(); + return basicGetSource(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimpleumlPackage.ASSOCIATION__DESTINATION: + setDestination((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)newValue); + return; + case SimpleumlPackage.ASSOCIATION__SOURCE: + setSource((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimpleumlPackage.ASSOCIATION__DESTINATION: + setDestination((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)null); + return; + case SimpleumlPackage.ASSOCIATION__SOURCE: + setSource((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimpleumlPackage.ASSOCIATION__DESTINATION: + return destination != null; + case SimpleumlPackage.ASSOCIATION__SOURCE: + return source != null; + } + return super.eIsSet(featureID); + } + +} //AssociationImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/AttributeImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/AttributeImpl.java new file mode 100644 index 000000000..778d9ca74 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/AttributeImpl.java @@ -0,0 +1,291 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EcoreUtil; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Attribute</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AttributeImpl#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.AttributeImpl#getType <em>Type</em>}</li> + * </ul> + * + * @generated + */ +public class AttributeImpl extends UMLModelElementImpl implements Attribute { + /** + * The cached value of the '{@link #getType() <em>Type</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getType() + * @generated + * @ordered + */ + protected Classifier type; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected AttributeImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimpleumlPackage.Literals.ATTRIBUTE; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class getOwner() { + if (eContainerFeatureID() != SimpleumlPackage.ATTRIBUTE__OWNER) return null; + return (org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetOwner(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class newOwner, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newOwner, SimpleumlPackage.ATTRIBUTE__OWNER, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setOwner(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class newOwner) { + if (newOwner != eInternalContainer() || (eContainerFeatureID() != SimpleumlPackage.ATTRIBUTE__OWNER && newOwner != null)) { + if (EcoreUtil.isAncestor(this, newOwner)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newOwner != null) + msgs = ((InternalEObject)newOwner).eInverseAdd(this, SimpleumlPackage.CLASS__ATTRIBUTES, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, msgs); + msgs = basicSetOwner(newOwner, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimpleumlPackage.ATTRIBUTE__OWNER, newOwner, newOwner)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Classifier getType() { + if (type != null && type.eIsProxy()) { + InternalEObject oldType = (InternalEObject)type; + type = (Classifier)eResolveProxy(oldType); + if (type != oldType) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, SimpleumlPackage.ATTRIBUTE__TYPE, oldType, type)); + } + } + return type; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Classifier basicGetType() { + return type; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetType(Classifier newType, NotificationChain msgs) { + Classifier oldType = type; + type = newType; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, SimpleumlPackage.ATTRIBUTE__TYPE, oldType, newType); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setType(Classifier newType) { + if (newType != type) { + NotificationChain msgs = null; + if (type != null) + msgs = ((InternalEObject)type).eInverseRemove(this, SimpleumlPackage.CLASSIFIER__TYPE_OPPOSITE, Classifier.class, msgs); + if (newType != null) + msgs = ((InternalEObject)newType).eInverseAdd(this, SimpleumlPackage.CLASSIFIER__TYPE_OPPOSITE, Classifier.class, msgs); + msgs = basicSetType(newType, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimpleumlPackage.ATTRIBUTE__TYPE, newType, newType)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.ATTRIBUTE__OWNER: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetOwner((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)otherEnd, msgs); + case SimpleumlPackage.ATTRIBUTE__TYPE: + if (type != null) + msgs = ((InternalEObject)type).eInverseRemove(this, SimpleumlPackage.CLASSIFIER__TYPE_OPPOSITE, Classifier.class, msgs); + return basicSetType((Classifier)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.ATTRIBUTE__OWNER: + return basicSetOwner(null, msgs); + case SimpleumlPackage.ATTRIBUTE__TYPE: + return basicSetType(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case SimpleumlPackage.ATTRIBUTE__OWNER: + return eInternalContainer().eInverseRemove(this, SimpleumlPackage.CLASS__ATTRIBUTES, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimpleumlPackage.ATTRIBUTE__OWNER: + return getOwner(); + case SimpleumlPackage.ATTRIBUTE__TYPE: + if (resolve) return getType(); + return basicGetType(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimpleumlPackage.ATTRIBUTE__OWNER: + setOwner((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)newValue); + return; + case SimpleumlPackage.ATTRIBUTE__TYPE: + setType((Classifier)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimpleumlPackage.ATTRIBUTE__OWNER: + setOwner((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)null); + return; + case SimpleumlPackage.ATTRIBUTE__TYPE: + setType((Classifier)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimpleumlPackage.ATTRIBUTE__OWNER: + return getOwner() != null; + case SimpleumlPackage.ATTRIBUTE__TYPE: + return type != null; + } + return super.eIsSet(featureID); + } + +} //AttributeImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/ClassImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/ClassImpl.java new file mode 100644 index 000000000..512df8801 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/ClassImpl.java @@ -0,0 +1,326 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Class</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassImpl#getAttributes <em>Attributes</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassImpl#getForward <em>Forward</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassImpl#getGeneral <em>General</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassImpl#getGeneralOpposite <em>General Opposite</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassImpl#getReverse <em>Reverse</em>}</li> + * </ul> + * + * @generated + */ +public class ClassImpl extends ClassifierImpl implements org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class { + /** + * The cached value of the '{@link #getAttributes() <em>Attributes</em>}' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getAttributes() + * @generated + * @ordered + */ + protected EList<Attribute> attributes; + + /** + * The cached value of the '{@link #getForward() <em>Forward</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getForward() + * @generated + * @ordered + */ + protected EList<Association> forward; + + /** + * The cached value of the '{@link #getGeneral() <em>General</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getGeneral() + * @generated + * @ordered + */ + protected EList<org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class> general; + + /** + * The cached value of the '{@link #getGeneralOpposite() <em>General Opposite</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getGeneralOpposite() + * @generated + * @ordered + */ + protected EList<org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class> generalOpposite; + + /** + * The cached value of the '{@link #getReverse() <em>Reverse</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getReverse() + * @generated + * @ordered + */ + protected EList<Association> reverse; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ClassImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimpleumlPackage.Literals.CLASS; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<Attribute> getAttributes() { + if (attributes == null) { + attributes = new EObjectContainmentWithInverseEList<Attribute>(Attribute.class, this, SimpleumlPackage.CLASS__ATTRIBUTES, SimpleumlPackage.ATTRIBUTE__OWNER); + } + return attributes; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<Association> getForward() { + if (forward == null) { + forward = new EObjectWithInverseResolvingEList<Association>(Association.class, this, SimpleumlPackage.CLASS__FORWARD, SimpleumlPackage.ASSOCIATION__SOURCE); + } + return forward; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class> getGeneral() { + if (general == null) { + general = new EObjectWithInverseResolvingEList.ManyInverse<org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class>(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, this, SimpleumlPackage.CLASS__GENERAL, SimpleumlPackage.CLASS__GENERAL_OPPOSITE); + } + return general; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class> getGeneralOpposite() { + if (generalOpposite == null) { + generalOpposite = new EObjectWithInverseResolvingEList.ManyInverse<org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class>(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, this, SimpleumlPackage.CLASS__GENERAL_OPPOSITE, SimpleumlPackage.CLASS__GENERAL); + } + return generalOpposite; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<Association> getReverse() { + if (reverse == null) { + reverse = new EObjectWithInverseResolvingEList<Association>(Association.class, this, SimpleumlPackage.CLASS__REVERSE, SimpleumlPackage.ASSOCIATION__DESTINATION); + } + return reverse; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.CLASS__ATTRIBUTES: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getAttributes()).basicAdd(otherEnd, msgs); + case SimpleumlPackage.CLASS__FORWARD: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getForward()).basicAdd(otherEnd, msgs); + case SimpleumlPackage.CLASS__GENERAL: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getGeneral()).basicAdd(otherEnd, msgs); + case SimpleumlPackage.CLASS__GENERAL_OPPOSITE: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getGeneralOpposite()).basicAdd(otherEnd, msgs); + case SimpleumlPackage.CLASS__REVERSE: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getReverse()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.CLASS__ATTRIBUTES: + return ((InternalEList<?>)getAttributes()).basicRemove(otherEnd, msgs); + case SimpleumlPackage.CLASS__FORWARD: + return ((InternalEList<?>)getForward()).basicRemove(otherEnd, msgs); + case SimpleumlPackage.CLASS__GENERAL: + return ((InternalEList<?>)getGeneral()).basicRemove(otherEnd, msgs); + case SimpleumlPackage.CLASS__GENERAL_OPPOSITE: + return ((InternalEList<?>)getGeneralOpposite()).basicRemove(otherEnd, msgs); + case SimpleumlPackage.CLASS__REVERSE: + return ((InternalEList<?>)getReverse()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimpleumlPackage.CLASS__ATTRIBUTES: + return getAttributes(); + case SimpleumlPackage.CLASS__FORWARD: + return getForward(); + case SimpleumlPackage.CLASS__GENERAL: + return getGeneral(); + case SimpleumlPackage.CLASS__GENERAL_OPPOSITE: + return getGeneralOpposite(); + case SimpleumlPackage.CLASS__REVERSE: + return getReverse(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimpleumlPackage.CLASS__ATTRIBUTES: + getAttributes().clear(); + getAttributes().addAll((Collection<? extends Attribute>)newValue); + return; + case SimpleumlPackage.CLASS__FORWARD: + getForward().clear(); + getForward().addAll((Collection<? extends Association>)newValue); + return; + case SimpleumlPackage.CLASS__GENERAL: + getGeneral().clear(); + getGeneral().addAll((Collection<? extends org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class>)newValue); + return; + case SimpleumlPackage.CLASS__GENERAL_OPPOSITE: + getGeneralOpposite().clear(); + getGeneralOpposite().addAll((Collection<? extends org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class>)newValue); + return; + case SimpleumlPackage.CLASS__REVERSE: + getReverse().clear(); + getReverse().addAll((Collection<? extends Association>)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimpleumlPackage.CLASS__ATTRIBUTES: + getAttributes().clear(); + return; + case SimpleumlPackage.CLASS__FORWARD: + getForward().clear(); + return; + case SimpleumlPackage.CLASS__GENERAL: + getGeneral().clear(); + return; + case SimpleumlPackage.CLASS__GENERAL_OPPOSITE: + getGeneralOpposite().clear(); + return; + case SimpleumlPackage.CLASS__REVERSE: + getReverse().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimpleumlPackage.CLASS__ATTRIBUTES: + return attributes != null && !attributes.isEmpty(); + case SimpleumlPackage.CLASS__FORWARD: + return forward != null && !forward.isEmpty(); + case SimpleumlPackage.CLASS__GENERAL: + return general != null && !general.isEmpty(); + case SimpleumlPackage.CLASS__GENERAL_OPPOSITE: + return generalOpposite != null && !generalOpposite.isEmpty(); + case SimpleumlPackage.CLASS__REVERSE: + return reverse != null && !reverse.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //ClassImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/ClassifierImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/ClassifierImpl.java new file mode 100644 index 000000000..5d77c8722 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/ClassifierImpl.java @@ -0,0 +1,173 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Classifier</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.ClassifierImpl#getTypeOpposite <em>Type Opposite</em>}</li> + * </ul> + * + * @generated + */ +public abstract class ClassifierImpl extends PackageElementImpl implements Classifier { + /** + * The cached value of the '{@link #getTypeOpposite() <em>Type Opposite</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getTypeOpposite() + * @generated + * @ordered + */ + protected EList<Attribute> typeOpposite; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ClassifierImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimpleumlPackage.Literals.CLASSIFIER; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<Attribute> getTypeOpposite() { + if (typeOpposite == null) { + typeOpposite = new EObjectWithInverseResolvingEList<Attribute>(Attribute.class, this, SimpleumlPackage.CLASSIFIER__TYPE_OPPOSITE, SimpleumlPackage.ATTRIBUTE__TYPE); + } + return typeOpposite; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.CLASSIFIER__TYPE_OPPOSITE: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getTypeOpposite()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.CLASSIFIER__TYPE_OPPOSITE: + return ((InternalEList<?>)getTypeOpposite()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimpleumlPackage.CLASSIFIER__TYPE_OPPOSITE: + return getTypeOpposite(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimpleumlPackage.CLASSIFIER__TYPE_OPPOSITE: + getTypeOpposite().clear(); + getTypeOpposite().addAll((Collection<? extends Attribute>)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimpleumlPackage.CLASSIFIER__TYPE_OPPOSITE: + getTypeOpposite().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimpleumlPackage.CLASSIFIER__TYPE_OPPOSITE: + return typeOpposite != null && !typeOpposite.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //ClassifierImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/PackageElementImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/PackageElementImpl.java new file mode 100644 index 000000000..ad3450668 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/PackageElementImpl.java @@ -0,0 +1,202 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EcoreUtil; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Package Element</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PackageElementImpl#getNamespace <em>Namespace</em>}</li> + * </ul> + * + * @generated + */ +public abstract class PackageElementImpl extends UMLModelElementImpl implements PackageElement { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected PackageElementImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimpleumlPackage.Literals.PACKAGE_ELEMENT; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package getNamespace() { + if (eContainerFeatureID() != SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE) return null; + return (org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetNamespace(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package newNamespace, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newNamespace, SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setNamespace(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package newNamespace) { + if (newNamespace != eInternalContainer() || (eContainerFeatureID() != SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE && newNamespace != null)) { + if (EcoreUtil.isAncestor(this, newNamespace)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newNamespace != null) + msgs = ((InternalEObject)newNamespace).eInverseAdd(this, SimpleumlPackage.PACKAGE__ELEMENTS, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package.class, msgs); + msgs = basicSetNamespace(newNamespace, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE, newNamespace, newNamespace)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetNamespace((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE: + return basicSetNamespace(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE: + return eInternalContainer().eInverseRemove(this, SimpleumlPackage.PACKAGE__ELEMENTS, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE: + return getNamespace(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE: + setNamespace((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE: + setNamespace((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE: + return getNamespace() != null; + } + return super.eIsSet(featureID); + } + +} //PackageElementImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/PackageImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/PackageImpl.java new file mode 100644 index 000000000..02bd08c75 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/PackageImpl.java @@ -0,0 +1,172 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Package</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.PackageImpl#getElements <em>Elements</em>}</li> + * </ul> + * + * @generated + */ +public class PackageImpl extends UMLModelElementImpl implements org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package { + /** + * The cached value of the '{@link #getElements() <em>Elements</em>}' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getElements() + * @generated + * @ordered + */ + protected EList<PackageElement> elements; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected PackageImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimpleumlPackage.Literals.PACKAGE; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<PackageElement> getElements() { + if (elements == null) { + elements = new EObjectContainmentWithInverseEList<PackageElement>(PackageElement.class, this, SimpleumlPackage.PACKAGE__ELEMENTS, SimpleumlPackage.PACKAGE_ELEMENT__NAMESPACE); + } + return elements; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.PACKAGE__ELEMENTS: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getElements()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case SimpleumlPackage.PACKAGE__ELEMENTS: + return ((InternalEList<?>)getElements()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimpleumlPackage.PACKAGE__ELEMENTS: + return getElements(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimpleumlPackage.PACKAGE__ELEMENTS: + getElements().clear(); + getElements().addAll((Collection<? extends PackageElement>)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimpleumlPackage.PACKAGE__ELEMENTS: + getElements().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimpleumlPackage.PACKAGE__ELEMENTS: + return elements != null && !elements.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //PackageImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/PrimitiveDataTypeImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/PrimitiveDataTypeImpl.java new file mode 100644 index 000000000..f8a27881a --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/PrimitiveDataTypeImpl.java @@ -0,0 +1,45 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl; + +import org.eclipse.emf.ecore.EClass; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Primitive Data Type</b></em>'. + * <!-- end-user-doc --> + * + * @generated + */ +public class PrimitiveDataTypeImpl extends ClassifierImpl implements PrimitiveDataType { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected PrimitiveDataTypeImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimpleumlPackage.Literals.PRIMITIVE_DATA_TYPE; + } + +} //PrimitiveDataTypeImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/SimpleumlFactoryImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/SimpleumlFactoryImpl.java new file mode 100644 index 000000000..31c633927 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/SimpleumlFactoryImpl.java @@ -0,0 +1,151 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.impl.EFactoryImpl; + +import org.eclipse.emf.ecore.plugin.EcorePlugin; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlFactory; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model <b>Factory</b>. + * <!-- end-user-doc --> + * @generated + */ +public class SimpleumlFactoryImpl extends EFactoryImpl implements SimpleumlFactory { + /** + * Creates the default factory implementation. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public static SimpleumlFactory init() { + try { + SimpleumlFactory theSimpleumlFactory = (SimpleumlFactory)EPackage.Registry.INSTANCE.getEFactory(SimpleumlPackage.eNS_URI); + if (theSimpleumlFactory != null) { + return theSimpleumlFactory; + } + } + catch (Exception exception) { + EcorePlugin.INSTANCE.log(exception); + } + return new SimpleumlFactoryImpl(); + } + + /** + * Creates an instance of the factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SimpleumlFactoryImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public EObject create(EClass eClass) { + switch (eClass.getClassifierID()) { + case SimpleumlPackage.ATTRIBUTE: return createAttribute(); + case SimpleumlPackage.ASSOCIATION: return createAssociation(); + case SimpleumlPackage.CLASS: return createClass(); + case SimpleumlPackage.PACKAGE: return createPackage(); + case SimpleumlPackage.PRIMITIVE_DATA_TYPE: return createPrimitiveDataType(); + default: + throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Attribute createAttribute() { + AttributeImpl attribute = new AttributeImpl(); + return attribute; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Association createAssociation() { + AssociationImpl association = new AssociationImpl(); + return association; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class createClass() { + ClassImpl class_ = new ClassImpl(); + return class_; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package createPackage() { + PackageImpl package_ = new PackageImpl(); + return package_; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public PrimitiveDataType createPrimitiveDataType() { + PrimitiveDataTypeImpl primitiveDataType = new PrimitiveDataTypeImpl(); + return primitiveDataType; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SimpleumlPackage getSimpleumlPackage() { + return (SimpleumlPackage)getEPackage(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @deprecated + * @generated + */ + @Deprecated + public static SimpleumlPackage getPackage() { + return SimpleumlPackage.eINSTANCE; + } + +} //SimpleumlFactoryImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/SimpleumlPackageImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/SimpleumlPackageImpl.java new file mode 100644 index 000000000..0f07cf52f --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/SimpleumlPackageImpl.java @@ -0,0 +1,497 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl; + +import org.eclipse.emf.ecore.EAttribute; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +import org.eclipse.emf.ecore.impl.EPackageImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlFactory; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl; + +/** + * <!-- begin-user-doc --> + * An implementation of the model <b>Package</b>. + * <!-- end-user-doc --> + * @generated + */ +public class SimpleumlPackageImpl extends EPackageImpl implements SimpleumlPackage { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass attributeEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass associationEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass classEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass classifierEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass packageEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass packageElementEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass primitiveDataTypeEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass umlModelElementEClass = null; + + /** + * Creates an instance of the model <b>Package</b>, registered with + * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package + * package URI value. + * <p>Note: the correct way to create the package is via the static + * factory method {@link #init init()}, which also performs + * initialization of the package, or returns the registered package, + * if one already exists. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.ecore.EPackage.Registry + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage#eNS_URI + * @see #init() + * @generated + */ + private SimpleumlPackageImpl() { + super(eNS_URI, SimpleumlFactory.eINSTANCE); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private static boolean isInited = false; + + /** + * Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends. + * + * <p>This method is used to initialize {@link SimpleumlPackage#eINSTANCE} when that field is accessed. + * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #eNS_URI + * @see #createPackageContents() + * @see #initializePackageContents() + * @generated + */ + public static SimpleumlPackage init() { + if (isInited) return (SimpleumlPackage)EPackage.Registry.INSTANCE.getEPackage(SimpleumlPackage.eNS_URI); + + // Obtain or create and register package + SimpleumlPackageImpl theSimpleumlPackage = (SimpleumlPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof SimpleumlPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new SimpleumlPackageImpl()); + + isInited = true; + + // Obtain or create and register interdependencies + Simpleuml2rdbmsPackageImpl theSimpleuml2rdbmsPackage = (Simpleuml2rdbmsPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(Simpleuml2rdbmsPackage.eNS_URI) instanceof Simpleuml2rdbmsPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(Simpleuml2rdbmsPackage.eNS_URI) : Simpleuml2rdbmsPackage.eINSTANCE); + SimplerdbmsPackageImpl theSimplerdbmsPackage = (SimplerdbmsPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(SimplerdbmsPackage.eNS_URI) instanceof SimplerdbmsPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(SimplerdbmsPackage.eNS_URI) : SimplerdbmsPackage.eINSTANCE); + + // Create package meta-data objects + theSimpleumlPackage.createPackageContents(); + theSimpleuml2rdbmsPackage.createPackageContents(); + theSimplerdbmsPackage.createPackageContents(); + + // Initialize created meta-data + theSimpleumlPackage.initializePackageContents(); + theSimpleuml2rdbmsPackage.initializePackageContents(); + theSimplerdbmsPackage.initializePackageContents(); + + // Mark meta-data to indicate it can't be changed + theSimpleumlPackage.freeze(); + + + // Update the registry and return the package + EPackage.Registry.INSTANCE.put(SimpleumlPackage.eNS_URI, theSimpleumlPackage); + return theSimpleumlPackage; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getAttribute() { + return attributeEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getAttribute_Owner() { + return (EReference)attributeEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getAttribute_Type() { + return (EReference)attributeEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getAssociation() { + return associationEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getAssociation_Destination() { + return (EReference)associationEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getAssociation_Source() { + return (EReference)associationEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getClass_() { + return classEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClass_Attributes() { + return (EReference)classEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClass_Forward() { + return (EReference)classEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClass_General() { + return (EReference)classEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClass_GeneralOpposite() { + return (EReference)classEClass.getEStructuralFeatures().get(3); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClass_Reverse() { + return (EReference)classEClass.getEStructuralFeatures().get(4); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getClassifier() { + return classifierEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClassifier_TypeOpposite() { + return (EReference)classifierEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getPackage() { + return packageEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getPackage_Elements() { + return (EReference)packageEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getPackageElement() { + return packageElementEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getPackageElement_Namespace() { + return (EReference)packageElementEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getPrimitiveDataType() { + return primitiveDataTypeEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getUMLModelElement() { + return umlModelElementEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getUMLModelElement_Kind() { + return (EAttribute)umlModelElementEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getUMLModelElement_Name() { + return (EAttribute)umlModelElementEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SimpleumlFactory getSimpleumlFactory() { + return (SimpleumlFactory)getEFactoryInstance(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private boolean isCreated = false; + + /** + * Creates the meta-model objects for the package. This method is + * guarded to have no affect on any invocation but its first. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void createPackageContents() { + if (isCreated) return; + isCreated = true; + + // Create classes and their features + attributeEClass = createEClass(ATTRIBUTE); + createEReference(attributeEClass, ATTRIBUTE__OWNER); + createEReference(attributeEClass, ATTRIBUTE__TYPE); + + associationEClass = createEClass(ASSOCIATION); + createEReference(associationEClass, ASSOCIATION__DESTINATION); + createEReference(associationEClass, ASSOCIATION__SOURCE); + + classEClass = createEClass(CLASS); + createEReference(classEClass, CLASS__ATTRIBUTES); + createEReference(classEClass, CLASS__FORWARD); + createEReference(classEClass, CLASS__GENERAL); + createEReference(classEClass, CLASS__GENERAL_OPPOSITE); + createEReference(classEClass, CLASS__REVERSE); + + classifierEClass = createEClass(CLASSIFIER); + createEReference(classifierEClass, CLASSIFIER__TYPE_OPPOSITE); + + packageEClass = createEClass(PACKAGE); + createEReference(packageEClass, PACKAGE__ELEMENTS); + + packageElementEClass = createEClass(PACKAGE_ELEMENT); + createEReference(packageElementEClass, PACKAGE_ELEMENT__NAMESPACE); + + primitiveDataTypeEClass = createEClass(PRIMITIVE_DATA_TYPE); + + umlModelElementEClass = createEClass(UML_MODEL_ELEMENT); + createEAttribute(umlModelElementEClass, UML_MODEL_ELEMENT__KIND); + createEAttribute(umlModelElementEClass, UML_MODEL_ELEMENT__NAME); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private boolean isInitialized = false; + + /** + * Complete the initialization of the package and its meta-model. This + * method is guarded to have no affect on any invocation but its first. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void initializePackageContents() { + if (isInitialized) return; + isInitialized = true; + + // Initialize package + setName(eNAME); + setNsPrefix(eNS_PREFIX); + setNsURI(eNS_URI); + + // Create type parameters + + // Set bounds for type parameters + + // Add supertypes to classes + attributeEClass.getESuperTypes().add(this.getUMLModelElement()); + associationEClass.getESuperTypes().add(this.getPackageElement()); + classEClass.getESuperTypes().add(this.getClassifier()); + classifierEClass.getESuperTypes().add(this.getPackageElement()); + packageEClass.getESuperTypes().add(this.getUMLModelElement()); + packageElementEClass.getESuperTypes().add(this.getUMLModelElement()); + primitiveDataTypeEClass.getESuperTypes().add(this.getClassifier()); + + // Initialize classes, features, and operations; add parameters + initEClass(attributeEClass, Attribute.class, "Attribute", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getAttribute_Owner(), this.getClass_(), this.getClass_Attributes(), "owner", null, 1, 1, Attribute.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getAttribute_Type(), this.getClassifier(), this.getClassifier_TypeOpposite(), "type", null, 1, 1, Attribute.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(associationEClass, Association.class, "Association", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getAssociation_Destination(), this.getClass_(), this.getClass_Reverse(), "destination", null, 1, 1, Association.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getAssociation_Source(), this.getClass_(), this.getClass_Forward(), "source", null, 1, 1, Association.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(classEClass, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, "Class", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getClass_Attributes(), this.getAttribute(), this.getAttribute_Owner(), "attributes", null, 0, -1, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getClass_Forward(), this.getAssociation(), this.getAssociation_Source(), "forward", null, 0, -1, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getClass_General(), this.getClass_(), this.getClass_GeneralOpposite(), "general", null, 0, -1, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getClass_GeneralOpposite(), this.getClass_(), this.getClass_General(), "generalOpposite", null, 0, -1, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getClass_Reverse(), this.getAssociation(), this.getAssociation_Destination(), "reverse", null, 0, -1, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED); + + initEClass(classifierEClass, Classifier.class, "Classifier", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getClassifier_TypeOpposite(), this.getAttribute(), this.getAttribute_Type(), "typeOpposite", null, 0, -1, Classifier.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(packageEClass, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package.class, "Package", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getPackage_Elements(), this.getPackageElement(), this.getPackageElement_Namespace(), "elements", null, 0, -1, org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(packageElementEClass, PackageElement.class, "PackageElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getPackageElement_Namespace(), this.getPackage(), this.getPackage_Elements(), "namespace", null, 1, 1, PackageElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(primitiveDataTypeEClass, PrimitiveDataType.class, "PrimitiveDataType", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(umlModelElementEClass, UMLModelElement.class, "UMLModelElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEAttribute(getUMLModelElement_Kind(), ecorePackage.getEString(), "kind", null, 0, 1, UMLModelElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEAttribute(getUMLModelElement_Name(), ecorePackage.getEString(), "name", null, 0, 1, UMLModelElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + // Create resource + createResource(eNS_URI); + } + +} //SimpleumlPackageImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/UMLModelElementImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/UMLModelElementImpl.java new file mode 100644 index 000000000..cacdcbd3b --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/impl/UMLModelElementImpl.java @@ -0,0 +1,225 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl; + +import org.eclipse.emf.common.notify.Notification; + +import org.eclipse.emf.ecore.EClass; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>UML Model Element</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.UMLModelElementImpl#getKind <em>Kind</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.UMLModelElementImpl#getName <em>Name</em>}</li> + * </ul> + * + * @generated + */ +public abstract class UMLModelElementImpl extends MinimalEObjectImpl.Container implements UMLModelElement { + /** + * The default value of the '{@link #getKind() <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getKind() + * @generated + * @ordered + */ + protected static final String KIND_EDEFAULT = null; + + /** + * The cached value of the '{@link #getKind() <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getKind() + * @generated + * @ordered + */ + protected String kind = KIND_EDEFAULT; + + /** + * The default value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected static final String NAME_EDEFAULT = null; + + /** + * The cached value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected String name = NAME_EDEFAULT; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected UMLModelElementImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return SimpleumlPackage.Literals.UML_MODEL_ELEMENT; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getKind() { + return kind; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setKind(String newKind) { + String oldKind = kind; + kind = newKind; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimpleumlPackage.UML_MODEL_ELEMENT__KIND, oldKind, kind)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getName() { + return name; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setName(String newName) { + String oldName = name; + name = newName; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, SimpleumlPackage.UML_MODEL_ELEMENT__NAME, oldName, name)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case SimpleumlPackage.UML_MODEL_ELEMENT__KIND: + return getKind(); + case SimpleumlPackage.UML_MODEL_ELEMENT__NAME: + return getName(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case SimpleumlPackage.UML_MODEL_ELEMENT__KIND: + setKind((String)newValue); + return; + case SimpleumlPackage.UML_MODEL_ELEMENT__NAME: + setName((String)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case SimpleumlPackage.UML_MODEL_ELEMENT__KIND: + setKind(KIND_EDEFAULT); + return; + case SimpleumlPackage.UML_MODEL_ELEMENT__NAME: + setName(NAME_EDEFAULT); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case SimpleumlPackage.UML_MODEL_ELEMENT__KIND: + return KIND_EDEFAULT == null ? kind != null : !KIND_EDEFAULT.equals(kind); + case SimpleumlPackage.UML_MODEL_ELEMENT__NAME: + return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuffer result = new StringBuffer(super.toString()); + result.append(" (kind: "); + result.append(kind); + result.append(", name: "); + result.append(name); + result.append(')'); + return result.toString(); + } + +} //UMLModelElementImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/util/SimpleumlAdapterFactory.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/util/SimpleumlAdapterFactory.java new file mode 100644 index 000000000..26ee1a2a5 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/util/SimpleumlAdapterFactory.java @@ -0,0 +1,260 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.util; + +import org.eclipse.emf.common.notify.Adapter; +import org.eclipse.emf.common.notify.Notifier; + +import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; + +import org.eclipse.emf.ecore.EObject; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement; + +/** + * <!-- begin-user-doc --> + * The <b>Adapter Factory</b> for the model. + * It provides an adapter <code>createXXX</code> method for each class of the model. + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage + * @generated + */ +public class SimpleumlAdapterFactory extends AdapterFactoryImpl { + /** + * The cached model package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected static SimpleumlPackage modelPackage; + + /** + * Creates an instance of the adapter factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SimpleumlAdapterFactory() { + if (modelPackage == null) { + modelPackage = SimpleumlPackage.eINSTANCE; + } + } + + /** + * Returns whether this factory is applicable for the type of the object. + * <!-- begin-user-doc --> + * This implementation returns <code>true</code> if the object is either the model's package or is an instance object of the model. + * <!-- end-user-doc --> + * @return whether this factory is applicable for the type of the object. + * @generated + */ + @Override + public boolean isFactoryForType(Object object) { + if (object == modelPackage) { + return true; + } + if (object instanceof EObject) { + return ((EObject)object).eClass().getEPackage() == modelPackage; + } + return false; + } + + /** + * The switch that delegates to the <code>createXXX</code> methods. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected SimpleumlSwitch<Adapter> modelSwitch = + new SimpleumlSwitch<Adapter>() { + @Override + public Adapter caseAttribute(Attribute object) { + return createAttributeAdapter(); + } + @Override + public Adapter caseAssociation(Association object) { + return createAssociationAdapter(); + } + @Override + public Adapter caseClass(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class object) { + return createClassAdapter(); + } + @Override + public Adapter caseClassifier(Classifier object) { + return createClassifierAdapter(); + } + @Override + public Adapter casePackage(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package object) { + return createPackageAdapter(); + } + @Override + public Adapter casePackageElement(PackageElement object) { + return createPackageElementAdapter(); + } + @Override + public Adapter casePrimitiveDataType(PrimitiveDataType object) { + return createPrimitiveDataTypeAdapter(); + } + @Override + public Adapter caseUMLModelElement(UMLModelElement object) { + return createUMLModelElementAdapter(); + } + @Override + public Adapter defaultCase(EObject object) { + return createEObjectAdapter(); + } + }; + + /** + * Creates an adapter for the <code>target</code>. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param target the object to adapt. + * @return the adapter for the <code>target</code>. + * @generated + */ + @Override + public Adapter createAdapter(Notifier target) { + return modelSwitch.doSwitch((EObject)target); + } + + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute <em>Attribute</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute + * @generated + */ + public Adapter createAttributeAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association <em>Association</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association + * @generated + */ + public Adapter createAssociationAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class <em>Class</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class + * @generated + */ + public Adapter createClassAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier <em>Classifier</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier + * @generated + */ + public Adapter createClassifierAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package <em>Package</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package + * @generated + */ + public Adapter createPackageAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement <em>Package Element</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement + * @generated + */ + public Adapter createPackageElementAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType <em>Primitive Data Type</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType + * @generated + */ + public Adapter createPrimitiveDataTypeAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement <em>UML Model Element</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement + * @generated + */ + public Adapter createUMLModelElementAdapter() { + return null; + } + + /** + * Creates a new adapter for the default case. + * <!-- begin-user-doc --> + * This default implementation returns null. + * <!-- end-user-doc --> + * @return the new adapter. + * @generated + */ + public Adapter createEObjectAdapter() { + return null; + } + +} //SimpleumlAdapterFactory diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/util/SimpleumlSwitch.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/util/SimpleumlSwitch.java new file mode 100644 index 000000000..dba5b1e3b --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml/util/SimpleumlSwitch.java @@ -0,0 +1,284 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.util; + +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.util.Switch; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Classifier; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PackageElement; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.UMLModelElement; + +/** + * <!-- begin-user-doc --> + * The <b>Switch</b> for the model's inheritance hierarchy. + * It supports the call {@link #doSwitch(EObject) doSwitch(object)} + * to invoke the <code>caseXXX</code> method for each class of the model, + * starting with the actual class of the object + * and proceeding up the inheritance hierarchy + * until a non-null result is returned, + * which is the result of the switch. + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage + * @generated + */ +public class SimpleumlSwitch<T> extends Switch<T> { + /** + * The cached model package + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected static SimpleumlPackage modelPackage; + + /** + * Creates an instance of the switch. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SimpleumlSwitch() { + if (modelPackage == null) { + modelPackage = SimpleumlPackage.eINSTANCE; + } + } + + /** + * Checks whether this is a switch for the given package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param ePackage the package in question. + * @return whether this is a switch for the given package. + * @generated + */ + @Override + protected boolean isSwitchFor(EPackage ePackage) { + return ePackage == modelPackage; + } + + /** + * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the first non-null result returned by a <code>caseXXX</code> call. + * @generated + */ + @Override + protected T doSwitch(int classifierID, EObject theEObject) { + switch (classifierID) { + case SimpleumlPackage.ATTRIBUTE: { + Attribute attribute = (Attribute)theEObject; + T result = caseAttribute(attribute); + if (result == null) result = caseUMLModelElement(attribute); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimpleumlPackage.ASSOCIATION: { + Association association = (Association)theEObject; + T result = caseAssociation(association); + if (result == null) result = casePackageElement(association); + if (result == null) result = caseUMLModelElement(association); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimpleumlPackage.CLASS: { + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class class_ = (org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)theEObject; + T result = caseClass(class_); + if (result == null) result = caseClassifier(class_); + if (result == null) result = casePackageElement(class_); + if (result == null) result = caseUMLModelElement(class_); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimpleumlPackage.CLASSIFIER: { + Classifier classifier = (Classifier)theEObject; + T result = caseClassifier(classifier); + if (result == null) result = casePackageElement(classifier); + if (result == null) result = caseUMLModelElement(classifier); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimpleumlPackage.PACKAGE: { + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package package_ = (org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package)theEObject; + T result = casePackage(package_); + if (result == null) result = caseUMLModelElement(package_); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimpleumlPackage.PACKAGE_ELEMENT: { + PackageElement packageElement = (PackageElement)theEObject; + T result = casePackageElement(packageElement); + if (result == null) result = caseUMLModelElement(packageElement); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimpleumlPackage.PRIMITIVE_DATA_TYPE: { + PrimitiveDataType primitiveDataType = (PrimitiveDataType)theEObject; + T result = casePrimitiveDataType(primitiveDataType); + if (result == null) result = caseClassifier(primitiveDataType); + if (result == null) result = casePackageElement(primitiveDataType); + if (result == null) result = caseUMLModelElement(primitiveDataType); + if (result == null) result = defaultCase(theEObject); + return result; + } + case SimpleumlPackage.UML_MODEL_ELEMENT: { + UMLModelElement umlModelElement = (UMLModelElement)theEObject; + T result = caseUMLModelElement(umlModelElement); + if (result == null) result = defaultCase(theEObject); + return result; + } + default: return defaultCase(theEObject); + } + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Attribute</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Attribute</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseAttribute(Attribute object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Association</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Association</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseAssociation(Association object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Class</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Class</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseClass(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Classifier</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Classifier</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseClassifier(Classifier object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Package</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Package</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T casePackage(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Package Element</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Package Element</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T casePackageElement(PackageElement object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Primitive Data Type</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Primitive Data Type</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T casePrimitiveDataType(PrimitiveDataType object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>UML Model Element</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>UML Model Element</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseUMLModelElement(UMLModelElement object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>EObject</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch, but this is the last case anyway. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>EObject</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) + * @generated + */ + @Override + public T defaultCase(EObject object) { + return null; + } + +} //SimpleumlSwitch diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/AssociationToForeignKey.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/AssociationToForeignKey.java new file mode 100644 index 000000000..dbedebe84 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/AssociationToForeignKey.java @@ -0,0 +1,145 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Association To Foreign Key</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getAssociation <em>Association</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getForeignKey <em>Foreign Key</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getReferenced <em>Referenced</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getAssociationToForeignKey() + * @model + * @generated + */ +public interface AssociationToForeignKey extends ToColumn, UmlToRdbmsModelElement { + /** + * Returns the value of the '<em><b>Association</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Association</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Association</em>' reference. + * @see #setAssociation(Association) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getAssociationToForeignKey_Association() + * @model annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper body='1'" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName body='middle'" + * @generated + */ + Association getAssociation(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getAssociation <em>Association</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Association</em>' reference. + * @see #getAssociation() + * @generated + */ + void setAssociation(Association value); + + /** + * Returns the value of the '<em><b>Foreign Key</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Foreign Key</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Foreign Key</em>' reference. + * @see #setForeignKey(ForeignKey) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getAssociationToForeignKey_ForeignKey() + * @model annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper body='1'" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName body='middle'" + * @generated + */ + ForeignKey getForeignKey(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getForeignKey <em>Foreign Key</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Foreign Key</em>' reference. + * @see #getForeignKey() + * @generated + */ + void setForeignKey(ForeignKey value); + + /** + * Returns the value of the '<em><b>Owner</b></em>' container reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getAssociationsToForeignKeys <em>Associations To Foreign Keys</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Owner</em>' container reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Owner</em>' container reference. + * @see #setOwner(ClassToTable) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getAssociationToForeignKey_Owner() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getAssociationsToForeignKeys + * @model opposite="associationsToForeignKeys" required="true" transient="false" + * @generated + */ + ClassToTable getOwner(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getOwner <em>Owner</em>}' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Owner</em>' container reference. + * @see #getOwner() + * @generated + */ + void setOwner(ClassToTable value); + + /** + * Returns the value of the '<em><b>Referenced</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Referenced</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Referenced</em>' reference. + * @see #setReferenced(ClassToTable) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getAssociationToForeignKey_Referenced() + * @model + * @generated + */ + ClassToTable getReferenced(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getReferenced <em>Referenced</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Referenced</em>' reference. + * @see #getReferenced() + * @generated + */ + void setReferenced(ClassToTable value); + +} // AssociationToForeignKey diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/AttributeToColumn.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/AttributeToColumn.java new file mode 100644 index 000000000..90bc3e83d --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/AttributeToColumn.java @@ -0,0 +1,57 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Attribute To Column</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn#getType <em>Type</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getAttributeToColumn() + * @model + * @generated + */ +public interface AttributeToColumn extends FromAttribute, ToColumn { + /** + * Returns the value of the '<em><b>Type</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Type</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Type</em>' reference. + * @see #setType(PrimitiveToName) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getAttributeToColumn_Type() + * @model + * @generated + */ + PrimitiveToName getType(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn#getType <em>Type</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Type</em>' reference. + * @see #getType() + * @generated + */ + void setType(PrimitiveToName value); + +} // AttributeToColumn diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/BooleanToBoolean.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/BooleanToBoolean.java new file mode 100644 index 000000000..538715ea5 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/BooleanToBoolean.java @@ -0,0 +1,25 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Boolean To Boolean</b></em>'. + * <!-- end-user-doc --> + * + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getBooleanToBoolean() + * @model + * @generated + */ +public interface BooleanToBoolean extends PrimitiveToName { +} // BooleanToBoolean diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/ClassToTable.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/ClassToTable.java new file mode 100644 index 000000000..08c160579 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/ClassToTable.java @@ -0,0 +1,166 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Class To Table</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getAssociationsToForeignKeys <em>Associations To Foreign Keys</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getPrimaryKey <em>Primary Key</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getTable <em>Table</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getUmlClass <em>Uml Class</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getClassToTable() + * @model + * @generated + */ +public interface ClassToTable extends FromAttributeOwner, ToColumn, UmlToRdbmsModelElement { + /** + * Returns the value of the '<em><b>Associations To Foreign Keys</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Associations To Foreign Keys</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Associations To Foreign Keys</em>' containment reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getClassToTable_AssociationsToForeignKeys() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getOwner + * @model opposite="owner" containment="true" + * @generated + */ + EList<AssociationToForeignKey> getAssociationsToForeignKeys(); + + /** + * Returns the value of the '<em><b>Owner</b></em>' container reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getClassesToTables <em>Classes To Tables</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Owner</em>' container reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Owner</em>' container reference. + * @see #setOwner(PackageToSchema) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getClassToTable_Owner() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getClassesToTables + * @model opposite="classesToTables" required="true" transient="false" + * @generated + */ + PackageToSchema getOwner(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getOwner <em>Owner</em>}' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Owner</em>' container reference. + * @see #getOwner() + * @generated + */ + void setOwner(PackageToSchema value); + + /** + * Returns the value of the '<em><b>Primary Key</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Primary Key</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Primary Key</em>' reference. + * @see #setPrimaryKey(Key) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getClassToTable_PrimaryKey() + * @model annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper body='1'" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName body='middle'" + * @generated + */ + Key getPrimaryKey(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getPrimaryKey <em>Primary Key</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Primary Key</em>' reference. + * @see #getPrimaryKey() + * @generated + */ + void setPrimaryKey(Key value); + + /** + * Returns the value of the '<em><b>Table</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Table</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Table</em>' reference. + * @see #setTable(Table) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getClassToTable_Table() + * @model annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper body='1'" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName body='middle'" + * @generated + */ + Table getTable(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getTable <em>Table</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Table</em>' reference. + * @see #getTable() + * @generated + */ + void setTable(Table value); + + /** + * Returns the value of the '<em><b>Uml Class</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Uml Class</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Uml Class</em>' reference. + * @see #setUmlClass(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getClassToTable_UmlClass() + * @model annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper body='1'" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName body='middle'" + * @generated + */ + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class getUmlClass(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getUmlClass <em>Uml Class</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Uml Class</em>' reference. + * @see #getUmlClass() + * @generated + */ + void setUmlClass(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class value); + +} // ClassToTable diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/FromAttribute.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/FromAttribute.java new file mode 100644 index 000000000..93141ee8f --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/FromAttribute.java @@ -0,0 +1,134 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>From Attribute</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getKind <em>Kind</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getAttribute <em>Attribute</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getLeafs <em>Leafs</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getOwner <em>Owner</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getFromAttribute() + * @model abstract="true" + * @generated + */ +public interface FromAttribute extends UmlToRdbmsModelElement { + /** + * Returns the value of the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Kind</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Kind</em>' attribute. + * @see #setKind(String) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getFromAttribute_Kind() + * @model + * @generated + */ + String getKind(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getKind <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Kind</em>' attribute. + * @see #getKind() + * @generated + */ + void setKind(String value); + + /** + * Returns the value of the '<em><b>Attribute</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Attribute</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Attribute</em>' reference. + * @see #setAttribute(Attribute) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getFromAttribute_Attribute() + * @model annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper body='1'" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName body='middle'" + * @generated + */ + Attribute getAttribute(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getAttribute <em>Attribute</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Attribute</em>' reference. + * @see #getAttribute() + * @generated + */ + void setAttribute(Attribute value); + + /** + * Returns the value of the '<em><b>Leafs</b></em>' reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn}. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Leafs</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Leafs</em>' reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getFromAttribute_Leafs() + * @model ordered="false" + * @generated + */ + EList<AttributeToColumn> getLeafs(); + + /** + * Returns the value of the '<em><b>Owner</b></em>' container reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner#getFromAttributes <em>From Attributes</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Owner</em>' container reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Owner</em>' container reference. + * @see #setOwner(FromAttributeOwner) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getFromAttribute_Owner() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner#getFromAttributes + * @model opposite="fromAttributes" required="true" transient="false" + * @generated + */ + FromAttributeOwner getOwner(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getOwner <em>Owner</em>}' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Owner</em>' container reference. + * @see #getOwner() + * @generated + */ + void setOwner(FromAttributeOwner value); + +} // FromAttribute diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/FromAttributeOwner.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/FromAttributeOwner.java new file mode 100644 index 000000000..0a520558a --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/FromAttributeOwner.java @@ -0,0 +1,52 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EObject; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>From Attribute Owner</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner#getFromAttributes <em>From Attributes</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getFromAttributeOwner() + * @model abstract="true" + * @generated + */ +public interface FromAttributeOwner extends EObject { + /** + * Returns the value of the '<em><b>From Attributes</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>From Attributes</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>From Attributes</em>' containment reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getFromAttributeOwner_FromAttributes() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getOwner + * @model opposite="owner" containment="true" ordered="false" + * @generated + */ + EList<FromAttribute> getFromAttributes(); + +} // FromAttributeOwner diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/IntegerToNumber.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/IntegerToNumber.java new file mode 100644 index 000000000..4af51eab3 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/IntegerToNumber.java @@ -0,0 +1,25 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Integer To Number</b></em>'. + * <!-- end-user-doc --> + * + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getIntegerToNumber() + * @model + * @generated + */ +public interface IntegerToNumber extends PrimitiveToName { +} // IntegerToNumber diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/NonLeafAttribute.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/NonLeafAttribute.java new file mode 100644 index 000000000..5bb88bfcd --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/NonLeafAttribute.java @@ -0,0 +1,25 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Non Leaf Attribute</b></em>'. + * <!-- end-user-doc --> + * + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getNonLeafAttribute() + * @model + * @generated + */ +public interface NonLeafAttribute extends FromAttributeOwner, FromAttribute { +} // NonLeafAttribute diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/PackageToSchema.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/PackageToSchema.java new file mode 100644 index 000000000..49e5ffb6f --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/PackageToSchema.java @@ -0,0 +1,129 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Package To Schema</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getClassesToTables <em>Classes To Tables</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getPrimitivesToNames <em>Primitives To Names</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getSchema <em>Schema</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getUmlPackage <em>Uml Package</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getPackageToSchema() + * @model + * @generated + */ +public interface PackageToSchema extends UmlToRdbmsModelElement { + /** + * Returns the value of the '<em><b>Classes To Tables</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Classes To Tables</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Classes To Tables</em>' containment reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getPackageToSchema_ClassesToTables() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getOwner + * @model opposite="owner" containment="true" required="true" ordered="false" + * @generated + */ + EList<ClassToTable> getClassesToTables(); + + /** + * Returns the value of the '<em><b>Primitives To Names</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName}. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Primitives To Names</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Primitives To Names</em>' containment reference list. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getPackageToSchema_PrimitivesToNames() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getOwner + * @model opposite="owner" containment="true" ordered="false" + * @generated + */ + EList<PrimitiveToName> getPrimitivesToNames(); + + /** + * Returns the value of the '<em><b>Schema</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Schema</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Schema</em>' reference. + * @see #setSchema(Schema) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getPackageToSchema_Schema() + * @model required="true" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper body='1'" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName body='middle'" + * @generated + */ + Schema getSchema(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getSchema <em>Schema</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Schema</em>' reference. + * @see #getSchema() + * @generated + */ + void setSchema(Schema value); + + /** + * Returns the value of the '<em><b>Uml Package</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Uml Package</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Uml Package</em>' reference. + * @see #setUmlPackage(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getPackageToSchema_UmlPackage() + * @model required="true" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper body='1'" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName body='middle'" + * @generated + */ + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package getUmlPackage(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getUmlPackage <em>Uml Package</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Uml Package</em>' reference. + * @see #getUmlPackage() + * @generated + */ + void setUmlPackage(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package value); + +} // PackageToSchema diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/PrimitiveToName.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/PrimitiveToName.java new file mode 100644 index 000000000..351c636d8 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/PrimitiveToName.java @@ -0,0 +1,116 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Primitive To Name</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getTypeName <em>Type Name</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getPrimitive <em>Primitive</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getPrimitiveToName() + * @model abstract="true" + * @generated + */ +public interface PrimitiveToName extends UmlToRdbmsModelElement { + /** + * Returns the value of the '<em><b>Type Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Type Name</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Type Name</em>' attribute. + * @see #setTypeName(String) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getPrimitiveToName_TypeName() + * @model required="true" + * @generated + */ + String getTypeName(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getTypeName <em>Type Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Type Name</em>' attribute. + * @see #getTypeName() + * @generated + */ + void setTypeName(String value); + + /** + * Returns the value of the '<em><b>Owner</b></em>' container reference. + * It is bidirectional and its opposite is '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getPrimitivesToNames <em>Primitives To Names</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Owner</em>' container reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Owner</em>' container reference. + * @see #setOwner(PackageToSchema) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getPrimitiveToName_Owner() + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getPrimitivesToNames + * @model opposite="primitivesToNames" required="true" transient="false" + * @generated + */ + PackageToSchema getOwner(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getOwner <em>Owner</em>}' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Owner</em>' container reference. + * @see #getOwner() + * @generated + */ + void setOwner(PackageToSchema value); + + /** + * Returns the value of the '<em><b>Primitive</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Primitive</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Primitive</em>' reference. + * @see #setPrimitive(PrimitiveDataType) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getPrimitiveToName_Primitive() + * @model required="true" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper body='1'" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName body='middle'" + * @generated + */ + PrimitiveDataType getPrimitive(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getPrimitive <em>Primitive</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Primitive</em>' reference. + * @see #getPrimitive() + * @generated + */ + void setPrimitive(PrimitiveDataType value); + +} // PrimitiveToName diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/Simpleuml2rdbmsFactory.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/Simpleuml2rdbmsFactory.java new file mode 100644 index 000000000..44d83e4df --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/Simpleuml2rdbmsFactory.java @@ -0,0 +1,113 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + +import org.eclipse.emf.ecore.EFactory; + +/** + * <!-- begin-user-doc --> + * The <b>Factory</b> for the model. + * It provides a create method for each non-abstract class of the model. + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage + * @generated + */ +public interface Simpleuml2rdbmsFactory extends EFactory { + /** + * The singleton instance of the factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + Simpleuml2rdbmsFactory eINSTANCE = org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsFactoryImpl.init(); + + /** + * Returns a new object of class '<em>Attribute To Column</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Attribute To Column</em>'. + * @generated + */ + AttributeToColumn createAttributeToColumn(); + + /** + * Returns a new object of class '<em>Association To Foreign Key</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Association To Foreign Key</em>'. + * @generated + */ + AssociationToForeignKey createAssociationToForeignKey(); + + /** + * Returns a new object of class '<em>Boolean To Boolean</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Boolean To Boolean</em>'. + * @generated + */ + BooleanToBoolean createBooleanToBoolean(); + + /** + * Returns a new object of class '<em>Class To Table</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Class To Table</em>'. + * @generated + */ + ClassToTable createClassToTable(); + + /** + * Returns a new object of class '<em>Integer To Number</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Integer To Number</em>'. + * @generated + */ + IntegerToNumber createIntegerToNumber(); + + /** + * Returns a new object of class '<em>Non Leaf Attribute</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Non Leaf Attribute</em>'. + * @generated + */ + NonLeafAttribute createNonLeafAttribute(); + + /** + * Returns a new object of class '<em>Package To Schema</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Package To Schema</em>'. + * @generated + */ + PackageToSchema createPackageToSchema(); + + /** + * Returns a new object of class '<em>String To Varchar</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>String To Varchar</em>'. + * @generated + */ + StringToVarchar createStringToVarchar(); + + /** + * Returns the package supported by this factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the package supported by this factory. + * @generated + */ + Simpleuml2rdbmsPackage getSimpleuml2rdbmsPackage(); + +} //Simpleuml2rdbmsFactory diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/Simpleuml2rdbmsPackage.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/Simpleuml2rdbmsPackage.java new file mode 100644 index 000000000..f677cb037 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/Simpleuml2rdbmsPackage.java @@ -0,0 +1,1677 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + +import org.eclipse.emf.ecore.EAttribute; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +/** + * <!-- begin-user-doc --> + * The <b>Package</b> for the model. + * It contains accessors for the meta objects to represent + * <ul> + * <li>each class,</li> + * <li>each feature of each class,</li> + * <li>each operation of each class,</li> + * <li>each enum,</li> + * <li>and each data type</li> + * </ul> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsFactory + * @model kind="package" + * @generated + */ +public interface Simpleuml2rdbmsPackage extends EPackage { + /** + * The package name. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNAME = "simpleuml2rdbms"; + + /** + * The package namespace URI. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNS_URI = "http://www.eclipse.org/qvtd/examples/qvtcore/UML2RDBMS/1.0/SimpleUMLtoRDBMS"; + + /** + * The package namespace name. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNS_PREFIX = "simpleuml2rdbms"; + + /** + * The singleton instance of the package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + Simpleuml2rdbmsPackage eINSTANCE = org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl.init(); + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.UmlToRdbmsModelElementImpl <em>Uml To Rdbms Model Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.UmlToRdbmsModelElementImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getUmlToRdbmsModelElement() + * @generated + */ + int UML_TO_RDBMS_MODEL_ELEMENT = 12; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int UML_TO_RDBMS_MODEL_ELEMENT__NAME = 0; + + /** + * The number of structural features of the '<em>Uml To Rdbms Model Element</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT = 1; + + /** + * The number of operations of the '<em>Uml To Rdbms Model Element</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int UML_TO_RDBMS_MODEL_ELEMENT_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeImpl <em>From Attribute</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getFromAttribute() + * @generated + */ + int FROM_ATTRIBUTE = 4; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FROM_ATTRIBUTE__NAME = UML_TO_RDBMS_MODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FROM_ATTRIBUTE__KIND = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Attribute</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FROM_ATTRIBUTE__ATTRIBUTE = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Leafs</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FROM_ATTRIBUTE__LEAFS = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 2; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FROM_ATTRIBUTE__OWNER = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 3; + + /** + * The number of structural features of the '<em>From Attribute</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FROM_ATTRIBUTE_FEATURE_COUNT = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 4; + + /** + * The number of operations of the '<em>From Attribute</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FROM_ATTRIBUTE_OPERATION_COUNT = UML_TO_RDBMS_MODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AttributeToColumnImpl <em>Attribute To Column</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AttributeToColumnImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getAttributeToColumn() + * @generated + */ + int ATTRIBUTE_TO_COLUMN = 0; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_TO_COLUMN__NAME = FROM_ATTRIBUTE__NAME; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_TO_COLUMN__KIND = FROM_ATTRIBUTE__KIND; + + /** + * The feature id for the '<em><b>Attribute</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_TO_COLUMN__ATTRIBUTE = FROM_ATTRIBUTE__ATTRIBUTE; + + /** + * The feature id for the '<em><b>Leafs</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_TO_COLUMN__LEAFS = FROM_ATTRIBUTE__LEAFS; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_TO_COLUMN__OWNER = FROM_ATTRIBUTE__OWNER; + + /** + * The feature id for the '<em><b>Column</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_TO_COLUMN__COLUMN = FROM_ATTRIBUTE_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Type</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_TO_COLUMN__TYPE = FROM_ATTRIBUTE_FEATURE_COUNT + 1; + + /** + * The number of structural features of the '<em>Attribute To Column</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_TO_COLUMN_FEATURE_COUNT = FROM_ATTRIBUTE_FEATURE_COUNT + 2; + + /** + * The number of operations of the '<em>Attribute To Column</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ATTRIBUTE_TO_COLUMN_OPERATION_COUNT = FROM_ATTRIBUTE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ToColumnImpl <em>To Column</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ToColumnImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getToColumn() + * @generated + */ + int TO_COLUMN = 11; + + /** + * The feature id for the '<em><b>Column</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TO_COLUMN__COLUMN = 0; + + /** + * The number of structural features of the '<em>To Column</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TO_COLUMN_FEATURE_COUNT = 1; + + /** + * The number of operations of the '<em>To Column</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int TO_COLUMN_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AssociationToForeignKeyImpl <em>Association To Foreign Key</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AssociationToForeignKeyImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getAssociationToForeignKey() + * @generated + */ + int ASSOCIATION_TO_FOREIGN_KEY = 1; + + /** + * The feature id for the '<em><b>Column</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION_TO_FOREIGN_KEY__COLUMN = TO_COLUMN__COLUMN; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION_TO_FOREIGN_KEY__NAME = TO_COLUMN_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Association</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION_TO_FOREIGN_KEY__ASSOCIATION = TO_COLUMN_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Foreign Key</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION_TO_FOREIGN_KEY__FOREIGN_KEY = TO_COLUMN_FEATURE_COUNT + 2; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION_TO_FOREIGN_KEY__OWNER = TO_COLUMN_FEATURE_COUNT + 3; + + /** + * The feature id for the '<em><b>Referenced</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION_TO_FOREIGN_KEY__REFERENCED = TO_COLUMN_FEATURE_COUNT + 4; + + /** + * The number of structural features of the '<em>Association To Foreign Key</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION_TO_FOREIGN_KEY_FEATURE_COUNT = TO_COLUMN_FEATURE_COUNT + 5; + + /** + * The number of operations of the '<em>Association To Foreign Key</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSOCIATION_TO_FOREIGN_KEY_OPERATION_COUNT = TO_COLUMN_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PrimitiveToNameImpl <em>Primitive To Name</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PrimitiveToNameImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getPrimitiveToName() + * @generated + */ + int PRIMITIVE_TO_NAME = 9; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_TO_NAME__NAME = UML_TO_RDBMS_MODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Type Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_TO_NAME__TYPE_NAME = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_TO_NAME__OWNER = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Primitive</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_TO_NAME__PRIMITIVE = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 2; + + /** + * The number of structural features of the '<em>Primitive To Name</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_TO_NAME_FEATURE_COUNT = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 3; + + /** + * The number of operations of the '<em>Primitive To Name</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PRIMITIVE_TO_NAME_OPERATION_COUNT = UML_TO_RDBMS_MODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.BooleanToBooleanImpl <em>Boolean To Boolean</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.BooleanToBooleanImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getBooleanToBoolean() + * @generated + */ + int BOOLEAN_TO_BOOLEAN = 2; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int BOOLEAN_TO_BOOLEAN__NAME = PRIMITIVE_TO_NAME__NAME; + + /** + * The feature id for the '<em><b>Type Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int BOOLEAN_TO_BOOLEAN__TYPE_NAME = PRIMITIVE_TO_NAME__TYPE_NAME; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int BOOLEAN_TO_BOOLEAN__OWNER = PRIMITIVE_TO_NAME__OWNER; + + /** + * The feature id for the '<em><b>Primitive</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int BOOLEAN_TO_BOOLEAN__PRIMITIVE = PRIMITIVE_TO_NAME__PRIMITIVE; + + /** + * The number of structural features of the '<em>Boolean To Boolean</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int BOOLEAN_TO_BOOLEAN_FEATURE_COUNT = PRIMITIVE_TO_NAME_FEATURE_COUNT + 0; + + /** + * The number of operations of the '<em>Boolean To Boolean</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int BOOLEAN_TO_BOOLEAN_OPERATION_COUNT = PRIMITIVE_TO_NAME_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeOwnerImpl <em>From Attribute Owner</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeOwnerImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getFromAttributeOwner() + * @generated + */ + int FROM_ATTRIBUTE_OWNER = 5; + + /** + * The feature id for the '<em><b>From Attributes</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES = 0; + + /** + * The number of structural features of the '<em>From Attribute Owner</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FROM_ATTRIBUTE_OWNER_FEATURE_COUNT = 1; + + /** + * The number of operations of the '<em>From Attribute Owner</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int FROM_ATTRIBUTE_OWNER_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl <em>Class To Table</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getClassToTable() + * @generated + */ + int CLASS_TO_TABLE = 3; + + /** + * The feature id for the '<em><b>From Attributes</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_TO_TABLE__FROM_ATTRIBUTES = FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES; + + /** + * The feature id for the '<em><b>Column</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_TO_TABLE__COLUMN = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_TO_TABLE__NAME = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Associations To Foreign Keys</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 2; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_TO_TABLE__OWNER = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 3; + + /** + * The feature id for the '<em><b>Primary Key</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_TO_TABLE__PRIMARY_KEY = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 4; + + /** + * The feature id for the '<em><b>Table</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_TO_TABLE__TABLE = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 5; + + /** + * The feature id for the '<em><b>Uml Class</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_TO_TABLE__UML_CLASS = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 6; + + /** + * The number of structural features of the '<em>Class To Table</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_TO_TABLE_FEATURE_COUNT = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 7; + + /** + * The number of operations of the '<em>Class To Table</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CLASS_TO_TABLE_OPERATION_COUNT = FROM_ATTRIBUTE_OWNER_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.IntegerToNumberImpl <em>Integer To Number</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.IntegerToNumberImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getIntegerToNumber() + * @generated + */ + int INTEGER_TO_NUMBER = 6; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int INTEGER_TO_NUMBER__NAME = PRIMITIVE_TO_NAME__NAME; + + /** + * The feature id for the '<em><b>Type Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int INTEGER_TO_NUMBER__TYPE_NAME = PRIMITIVE_TO_NAME__TYPE_NAME; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int INTEGER_TO_NUMBER__OWNER = PRIMITIVE_TO_NAME__OWNER; + + /** + * The feature id for the '<em><b>Primitive</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int INTEGER_TO_NUMBER__PRIMITIVE = PRIMITIVE_TO_NAME__PRIMITIVE; + + /** + * The number of structural features of the '<em>Integer To Number</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int INTEGER_TO_NUMBER_FEATURE_COUNT = PRIMITIVE_TO_NAME_FEATURE_COUNT + 0; + + /** + * The number of operations of the '<em>Integer To Number</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int INTEGER_TO_NUMBER_OPERATION_COUNT = PRIMITIVE_TO_NAME_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.NonLeafAttributeImpl <em>Non Leaf Attribute</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.NonLeafAttributeImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getNonLeafAttribute() + * @generated + */ + int NON_LEAF_ATTRIBUTE = 7; + + /** + * The feature id for the '<em><b>From Attributes</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int NON_LEAF_ATTRIBUTE__FROM_ATTRIBUTES = FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int NON_LEAF_ATTRIBUTE__NAME = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Kind</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int NON_LEAF_ATTRIBUTE__KIND = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Attribute</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int NON_LEAF_ATTRIBUTE__ATTRIBUTE = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 2; + + /** + * The feature id for the '<em><b>Leafs</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int NON_LEAF_ATTRIBUTE__LEAFS = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 3; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int NON_LEAF_ATTRIBUTE__OWNER = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 4; + + /** + * The number of structural features of the '<em>Non Leaf Attribute</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int NON_LEAF_ATTRIBUTE_FEATURE_COUNT = FROM_ATTRIBUTE_OWNER_FEATURE_COUNT + 5; + + /** + * The number of operations of the '<em>Non Leaf Attribute</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int NON_LEAF_ATTRIBUTE_OPERATION_COUNT = FROM_ATTRIBUTE_OWNER_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PackageToSchemaImpl <em>Package To Schema</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PackageToSchemaImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getPackageToSchema() + * @generated + */ + int PACKAGE_TO_SCHEMA = 8; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_TO_SCHEMA__NAME = UML_TO_RDBMS_MODEL_ELEMENT__NAME; + + /** + * The feature id for the '<em><b>Classes To Tables</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Primitives To Names</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Schema</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_TO_SCHEMA__SCHEMA = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 2; + + /** + * The feature id for the '<em><b>Uml Package</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_TO_SCHEMA__UML_PACKAGE = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 3; + + /** + * The number of structural features of the '<em>Package To Schema</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_TO_SCHEMA_FEATURE_COUNT = UML_TO_RDBMS_MODEL_ELEMENT_FEATURE_COUNT + 4; + + /** + * The number of operations of the '<em>Package To Schema</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int PACKAGE_TO_SCHEMA_OPERATION_COUNT = UML_TO_RDBMS_MODEL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.StringToVarcharImpl <em>String To Varchar</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.StringToVarcharImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getStringToVarchar() + * @generated + */ + int STRING_TO_VARCHAR = 10; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int STRING_TO_VARCHAR__NAME = PRIMITIVE_TO_NAME__NAME; + + /** + * The feature id for the '<em><b>Type Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int STRING_TO_VARCHAR__TYPE_NAME = PRIMITIVE_TO_NAME__TYPE_NAME; + + /** + * The feature id for the '<em><b>Owner</b></em>' container reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int STRING_TO_VARCHAR__OWNER = PRIMITIVE_TO_NAME__OWNER; + + /** + * The feature id for the '<em><b>Primitive</b></em>' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int STRING_TO_VARCHAR__PRIMITIVE = PRIMITIVE_TO_NAME__PRIMITIVE; + + /** + * The number of structural features of the '<em>String To Varchar</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int STRING_TO_VARCHAR_FEATURE_COUNT = PRIMITIVE_TO_NAME_FEATURE_COUNT + 0; + + /** + * The number of operations of the '<em>String To Varchar</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int STRING_TO_VARCHAR_OPERATION_COUNT = PRIMITIVE_TO_NAME_OPERATION_COUNT + 0; + + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn <em>Attribute To Column</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Attribute To Column</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn + * @generated + */ + EClass getAttributeToColumn(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn#getType <em>Type</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Type</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn#getType() + * @see #getAttributeToColumn() + * @generated + */ + EReference getAttributeToColumn_Type(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey <em>Association To Foreign Key</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Association To Foreign Key</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey + * @generated + */ + EClass getAssociationToForeignKey(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getAssociation <em>Association</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Association</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getAssociation() + * @see #getAssociationToForeignKey() + * @generated + */ + EReference getAssociationToForeignKey_Association(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getForeignKey <em>Foreign Key</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Foreign Key</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getForeignKey() + * @see #getAssociationToForeignKey() + * @generated + */ + EReference getAssociationToForeignKey_ForeignKey(); + + /** + * Returns the meta object for the container reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the container reference '<em>Owner</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getOwner() + * @see #getAssociationToForeignKey() + * @generated + */ + EReference getAssociationToForeignKey_Owner(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getReferenced <em>Referenced</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Referenced</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey#getReferenced() + * @see #getAssociationToForeignKey() + * @generated + */ + EReference getAssociationToForeignKey_Referenced(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.BooleanToBoolean <em>Boolean To Boolean</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Boolean To Boolean</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.BooleanToBoolean + * @generated + */ + EClass getBooleanToBoolean(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable <em>Class To Table</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Class To Table</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable + * @generated + */ + EClass getClassToTable(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getAssociationsToForeignKeys <em>Associations To Foreign Keys</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Associations To Foreign Keys</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getAssociationsToForeignKeys() + * @see #getClassToTable() + * @generated + */ + EReference getClassToTable_AssociationsToForeignKeys(); + + /** + * Returns the meta object for the container reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the container reference '<em>Owner</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getOwner() + * @see #getClassToTable() + * @generated + */ + EReference getClassToTable_Owner(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getPrimaryKey <em>Primary Key</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Primary Key</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getPrimaryKey() + * @see #getClassToTable() + * @generated + */ + EReference getClassToTable_PrimaryKey(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getTable <em>Table</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Table</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getTable() + * @see #getClassToTable() + * @generated + */ + EReference getClassToTable_Table(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getUmlClass <em>Uml Class</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Uml Class</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable#getUmlClass() + * @see #getClassToTable() + * @generated + */ + EReference getClassToTable_UmlClass(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute <em>From Attribute</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>From Attribute</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute + * @generated + */ + EClass getFromAttribute(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getKind <em>Kind</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Kind</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getKind() + * @see #getFromAttribute() + * @generated + */ + EAttribute getFromAttribute_Kind(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getAttribute <em>Attribute</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Attribute</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getAttribute() + * @see #getFromAttribute() + * @generated + */ + EReference getFromAttribute_Attribute(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getLeafs <em>Leafs</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Leafs</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getLeafs() + * @see #getFromAttribute() + * @generated + */ + EReference getFromAttribute_Leafs(); + + /** + * Returns the meta object for the container reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the container reference '<em>Owner</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute#getOwner() + * @see #getFromAttribute() + * @generated + */ + EReference getFromAttribute_Owner(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner <em>From Attribute Owner</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>From Attribute Owner</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner + * @generated + */ + EClass getFromAttributeOwner(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner#getFromAttributes <em>From Attributes</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>From Attributes</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner#getFromAttributes() + * @see #getFromAttributeOwner() + * @generated + */ + EReference getFromAttributeOwner_FromAttributes(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.IntegerToNumber <em>Integer To Number</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Integer To Number</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.IntegerToNumber + * @generated + */ + EClass getIntegerToNumber(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.NonLeafAttribute <em>Non Leaf Attribute</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Non Leaf Attribute</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.NonLeafAttribute + * @generated + */ + EClass getNonLeafAttribute(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema <em>Package To Schema</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Package To Schema</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema + * @generated + */ + EClass getPackageToSchema(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getClassesToTables <em>Classes To Tables</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Classes To Tables</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getClassesToTables() + * @see #getPackageToSchema() + * @generated + */ + EReference getPackageToSchema_ClassesToTables(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getPrimitivesToNames <em>Primitives To Names</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Primitives To Names</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getPrimitivesToNames() + * @see #getPackageToSchema() + * @generated + */ + EReference getPackageToSchema_PrimitivesToNames(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getSchema <em>Schema</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Schema</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getSchema() + * @see #getPackageToSchema() + * @generated + */ + EReference getPackageToSchema_Schema(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getUmlPackage <em>Uml Package</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Uml Package</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema#getUmlPackage() + * @see #getPackageToSchema() + * @generated + */ + EReference getPackageToSchema_UmlPackage(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName <em>Primitive To Name</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Primitive To Name</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName + * @generated + */ + EClass getPrimitiveToName(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getTypeName <em>Type Name</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Type Name</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getTypeName() + * @see #getPrimitiveToName() + * @generated + */ + EAttribute getPrimitiveToName_TypeName(); + + /** + * Returns the meta object for the container reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getOwner <em>Owner</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the container reference '<em>Owner</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getOwner() + * @see #getPrimitiveToName() + * @generated + */ + EReference getPrimitiveToName_Owner(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getPrimitive <em>Primitive</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Primitive</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName#getPrimitive() + * @see #getPrimitiveToName() + * @generated + */ + EReference getPrimitiveToName_Primitive(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.StringToVarchar <em>String To Varchar</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>String To Varchar</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.StringToVarchar + * @generated + */ + EClass getStringToVarchar(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn <em>To Column</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>To Column</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn + * @generated + */ + EClass getToColumn(); + + /** + * Returns the meta object for the reference '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn#getColumn <em>Column</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference '<em>Column</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn#getColumn() + * @see #getToColumn() + * @generated + */ + EReference getToColumn_Column(); + + /** + * Returns the meta object for class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement <em>Uml To Rdbms Model Element</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Uml To Rdbms Model Element</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement + * @generated + */ + EClass getUmlToRdbmsModelElement(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement#getName <em>Name</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Name</em>'. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement#getName() + * @see #getUmlToRdbmsModelElement() + * @generated + */ + EAttribute getUmlToRdbmsModelElement_Name(); + + /** + * Returns the factory that creates the instances of the model. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the factory that creates the instances of the model. + * @generated + */ + Simpleuml2rdbmsFactory getSimpleuml2rdbmsFactory(); + + /** + * <!-- begin-user-doc --> + * Defines literals for the meta objects that represent + * <ul> + * <li>each class,</li> + * <li>each feature of each class,</li> + * <li>each operation of each class,</li> + * <li>each enum,</li> + * <li>and each data type</li> + * </ul> + * <!-- end-user-doc --> + * @generated + */ + interface Literals { + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AttributeToColumnImpl <em>Attribute To Column</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AttributeToColumnImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getAttributeToColumn() + * @generated + */ + EClass ATTRIBUTE_TO_COLUMN = eINSTANCE.getAttributeToColumn(); + + /** + * The meta object literal for the '<em><b>Type</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ATTRIBUTE_TO_COLUMN__TYPE = eINSTANCE.getAttributeToColumn_Type(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AssociationToForeignKeyImpl <em>Association To Foreign Key</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AssociationToForeignKeyImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getAssociationToForeignKey() + * @generated + */ + EClass ASSOCIATION_TO_FOREIGN_KEY = eINSTANCE.getAssociationToForeignKey(); + + /** + * The meta object literal for the '<em><b>Association</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ASSOCIATION_TO_FOREIGN_KEY__ASSOCIATION = eINSTANCE.getAssociationToForeignKey_Association(); + + /** + * The meta object literal for the '<em><b>Foreign Key</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ASSOCIATION_TO_FOREIGN_KEY__FOREIGN_KEY = eINSTANCE.getAssociationToForeignKey_ForeignKey(); + + /** + * The meta object literal for the '<em><b>Owner</b></em>' container reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ASSOCIATION_TO_FOREIGN_KEY__OWNER = eINSTANCE.getAssociationToForeignKey_Owner(); + + /** + * The meta object literal for the '<em><b>Referenced</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ASSOCIATION_TO_FOREIGN_KEY__REFERENCED = eINSTANCE.getAssociationToForeignKey_Referenced(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.BooleanToBooleanImpl <em>Boolean To Boolean</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.BooleanToBooleanImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getBooleanToBoolean() + * @generated + */ + EClass BOOLEAN_TO_BOOLEAN = eINSTANCE.getBooleanToBoolean(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl <em>Class To Table</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getClassToTable() + * @generated + */ + EClass CLASS_TO_TABLE = eINSTANCE.getClassToTable(); + + /** + * The meta object literal for the '<em><b>Associations To Foreign Keys</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS = eINSTANCE.getClassToTable_AssociationsToForeignKeys(); + + /** + * The meta object literal for the '<em><b>Owner</b></em>' container reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASS_TO_TABLE__OWNER = eINSTANCE.getClassToTable_Owner(); + + /** + * The meta object literal for the '<em><b>Primary Key</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASS_TO_TABLE__PRIMARY_KEY = eINSTANCE.getClassToTable_PrimaryKey(); + + /** + * The meta object literal for the '<em><b>Table</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASS_TO_TABLE__TABLE = eINSTANCE.getClassToTable_Table(); + + /** + * The meta object literal for the '<em><b>Uml Class</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference CLASS_TO_TABLE__UML_CLASS = eINSTANCE.getClassToTable_UmlClass(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeImpl <em>From Attribute</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getFromAttribute() + * @generated + */ + EClass FROM_ATTRIBUTE = eINSTANCE.getFromAttribute(); + + /** + * The meta object literal for the '<em><b>Kind</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute FROM_ATTRIBUTE__KIND = eINSTANCE.getFromAttribute_Kind(); + + /** + * The meta object literal for the '<em><b>Attribute</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference FROM_ATTRIBUTE__ATTRIBUTE = eINSTANCE.getFromAttribute_Attribute(); + + /** + * The meta object literal for the '<em><b>Leafs</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference FROM_ATTRIBUTE__LEAFS = eINSTANCE.getFromAttribute_Leafs(); + + /** + * The meta object literal for the '<em><b>Owner</b></em>' container reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference FROM_ATTRIBUTE__OWNER = eINSTANCE.getFromAttribute_Owner(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeOwnerImpl <em>From Attribute Owner</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeOwnerImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getFromAttributeOwner() + * @generated + */ + EClass FROM_ATTRIBUTE_OWNER = eINSTANCE.getFromAttributeOwner(); + + /** + * The meta object literal for the '<em><b>From Attributes</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES = eINSTANCE.getFromAttributeOwner_FromAttributes(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.IntegerToNumberImpl <em>Integer To Number</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.IntegerToNumberImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getIntegerToNumber() + * @generated + */ + EClass INTEGER_TO_NUMBER = eINSTANCE.getIntegerToNumber(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.NonLeafAttributeImpl <em>Non Leaf Attribute</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.NonLeafAttributeImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getNonLeafAttribute() + * @generated + */ + EClass NON_LEAF_ATTRIBUTE = eINSTANCE.getNonLeafAttribute(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PackageToSchemaImpl <em>Package To Schema</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PackageToSchemaImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getPackageToSchema() + * @generated + */ + EClass PACKAGE_TO_SCHEMA = eINSTANCE.getPackageToSchema(); + + /** + * The meta object literal for the '<em><b>Classes To Tables</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES = eINSTANCE.getPackageToSchema_ClassesToTables(); + + /** + * The meta object literal for the '<em><b>Primitives To Names</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES = eINSTANCE.getPackageToSchema_PrimitivesToNames(); + + /** + * The meta object literal for the '<em><b>Schema</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference PACKAGE_TO_SCHEMA__SCHEMA = eINSTANCE.getPackageToSchema_Schema(); + + /** + * The meta object literal for the '<em><b>Uml Package</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference PACKAGE_TO_SCHEMA__UML_PACKAGE = eINSTANCE.getPackageToSchema_UmlPackage(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PrimitiveToNameImpl <em>Primitive To Name</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PrimitiveToNameImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getPrimitiveToName() + * @generated + */ + EClass PRIMITIVE_TO_NAME = eINSTANCE.getPrimitiveToName(); + + /** + * The meta object literal for the '<em><b>Type Name</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute PRIMITIVE_TO_NAME__TYPE_NAME = eINSTANCE.getPrimitiveToName_TypeName(); + + /** + * The meta object literal for the '<em><b>Owner</b></em>' container reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference PRIMITIVE_TO_NAME__OWNER = eINSTANCE.getPrimitiveToName_Owner(); + + /** + * The meta object literal for the '<em><b>Primitive</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference PRIMITIVE_TO_NAME__PRIMITIVE = eINSTANCE.getPrimitiveToName_Primitive(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.StringToVarcharImpl <em>String To Varchar</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.StringToVarcharImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getStringToVarchar() + * @generated + */ + EClass STRING_TO_VARCHAR = eINSTANCE.getStringToVarchar(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ToColumnImpl <em>To Column</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ToColumnImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getToColumn() + * @generated + */ + EClass TO_COLUMN = eINSTANCE.getToColumn(); + + /** + * The meta object literal for the '<em><b>Column</b></em>' reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference TO_COLUMN__COLUMN = eINSTANCE.getToColumn_Column(); + + /** + * The meta object literal for the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.UmlToRdbmsModelElementImpl <em>Uml To Rdbms Model Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.UmlToRdbmsModelElementImpl + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.Simpleuml2rdbmsPackageImpl#getUmlToRdbmsModelElement() + * @generated + */ + EClass UML_TO_RDBMS_MODEL_ELEMENT = eINSTANCE.getUmlToRdbmsModelElement(); + + /** + * The meta object literal for the '<em><b>Name</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute UML_TO_RDBMS_MODEL_ELEMENT__NAME = eINSTANCE.getUmlToRdbmsModelElement_Name(); + + } + +} //Simpleuml2rdbmsPackage diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/StringToVarchar.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/StringToVarchar.java new file mode 100644 index 000000000..243b8cf49 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/StringToVarchar.java @@ -0,0 +1,25 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>String To Varchar</b></em>'. + * <!-- end-user-doc --> + * + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getStringToVarchar() + * @model + * @generated + */ +public interface StringToVarchar extends PrimitiveToName { +} // StringToVarchar diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/ToColumn.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/ToColumn.java new file mode 100644 index 000000000..f5d057633 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/ToColumn.java @@ -0,0 +1,62 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + +import org.eclipse.emf.ecore.EObject; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>To Column</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn#getColumn <em>Column</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getToColumn() + * @model abstract="true" + * @generated + */ +public interface ToColumn extends EObject { + /** + * Returns the value of the '<em><b>Column</b></em>' reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Column</em>' reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Column</em>' reference. + * @see #setColumn(Column) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getToColumn_Column() + * @model required="true" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper body='1'" + * annotation="http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName body='middle'" + * @generated + */ + Column getColumn(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn#getColumn <em>Column</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Column</em>' reference. + * @see #getColumn() + * @generated + */ + void setColumn(Column value); + +} // ToColumn diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/UmlToRdbmsModelElement.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/UmlToRdbmsModelElement.java new file mode 100644 index 000000000..428800d88 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/UmlToRdbmsModelElement.java @@ -0,0 +1,58 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms; + +import org.eclipse.emf.ecore.EObject; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Uml To Rdbms Model Element</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement#getName <em>Name</em>}</li> + * </ul> + * + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getUmlToRdbmsModelElement() + * @model abstract="true" + * @generated + */ +public interface UmlToRdbmsModelElement extends EObject { + /** + * Returns the value of the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Name</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Name</em>' attribute. + * @see #setName(String) + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#getUmlToRdbmsModelElement_Name() + * @model + * @generated + */ + String getName(); + + /** + * Sets the value of the '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement#getName <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Name</em>' attribute. + * @see #getName() + * @generated + */ + void setName(String value); + +} // UmlToRdbmsModelElement diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/AssociationToForeignKeyImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/AssociationToForeignKeyImpl.java new file mode 100644 index 000000000..2dfc461e4 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/AssociationToForeignKeyImpl.java @@ -0,0 +1,488 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EcoreUtil; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.ForeignKey; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Association; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Association To Foreign Key</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AssociationToForeignKeyImpl#getName <em>Name</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AssociationToForeignKeyImpl#getAssociation <em>Association</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AssociationToForeignKeyImpl#getForeignKey <em>Foreign Key</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AssociationToForeignKeyImpl#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AssociationToForeignKeyImpl#getReferenced <em>Referenced</em>}</li> + * </ul> + * + * @generated + */ +public class AssociationToForeignKeyImpl extends ToColumnImpl implements AssociationToForeignKey { + /** + * The default value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected static final String NAME_EDEFAULT = null; + + /** + * The cached value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected String name = NAME_EDEFAULT; + + /** + * The cached value of the '{@link #getAssociation() <em>Association</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getAssociation() + * @generated + * @ordered + */ + protected Association association; + + /** + * The cached value of the '{@link #getForeignKey() <em>Foreign Key</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getForeignKey() + * @generated + * @ordered + */ + protected ForeignKey foreignKey; + + /** + * The cached value of the '{@link #getReferenced() <em>Referenced</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getReferenced() + * @generated + * @ordered + */ + protected ClassToTable referenced; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected AssociationToForeignKeyImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.ASSOCIATION_TO_FOREIGN_KEY; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getName() { + return name; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setName(String newName) { + String oldName = name; + name = newName; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__NAME, oldName, name)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Association getAssociation() { + if (association != null && association.eIsProxy()) { + InternalEObject oldAssociation = (InternalEObject)association; + association = (Association)eResolveProxy(oldAssociation); + if (association != oldAssociation) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__ASSOCIATION, oldAssociation, association)); + } + } + return association; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Association basicGetAssociation() { + return association; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setAssociation(Association newAssociation) { + Association oldAssociation = association; + association = newAssociation; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__ASSOCIATION, oldAssociation, association)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ForeignKey getForeignKey() { + if (foreignKey != null && foreignKey.eIsProxy()) { + InternalEObject oldForeignKey = (InternalEObject)foreignKey; + foreignKey = (ForeignKey)eResolveProxy(oldForeignKey); + if (foreignKey != oldForeignKey) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__FOREIGN_KEY, oldForeignKey, foreignKey)); + } + } + return foreignKey; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ForeignKey basicGetForeignKey() { + return foreignKey; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setForeignKey(ForeignKey newForeignKey) { + ForeignKey oldForeignKey = foreignKey; + foreignKey = newForeignKey; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__FOREIGN_KEY, oldForeignKey, foreignKey)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ClassToTable getOwner() { + if (eContainerFeatureID() != Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER) return null; + return (ClassToTable)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetOwner(ClassToTable newOwner, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newOwner, Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setOwner(ClassToTable newOwner) { + if (newOwner != eInternalContainer() || (eContainerFeatureID() != Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER && newOwner != null)) { + if (EcoreUtil.isAncestor(this, newOwner)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newOwner != null) + msgs = ((InternalEObject)newOwner).eInverseAdd(this, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS, ClassToTable.class, msgs); + msgs = basicSetOwner(newOwner, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER, newOwner, newOwner)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ClassToTable getReferenced() { + if (referenced != null && referenced.eIsProxy()) { + InternalEObject oldReferenced = (InternalEObject)referenced; + referenced = (ClassToTable)eResolveProxy(oldReferenced); + if (referenced != oldReferenced) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__REFERENCED, oldReferenced, referenced)); + } + } + return referenced; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ClassToTable basicGetReferenced() { + return referenced; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setReferenced(ClassToTable newReferenced) { + ClassToTable oldReferenced = referenced; + referenced = newReferenced; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__REFERENCED, oldReferenced, referenced)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetOwner((ClassToTable)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER: + return basicSetOwner(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER: + return eInternalContainer().eInverseRemove(this, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS, ClassToTable.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__NAME: + return getName(); + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__ASSOCIATION: + if (resolve) return getAssociation(); + return basicGetAssociation(); + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__FOREIGN_KEY: + if (resolve) return getForeignKey(); + return basicGetForeignKey(); + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER: + return getOwner(); + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__REFERENCED: + if (resolve) return getReferenced(); + return basicGetReferenced(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__NAME: + setName((String)newValue); + return; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__ASSOCIATION: + setAssociation((Association)newValue); + return; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__FOREIGN_KEY: + setForeignKey((ForeignKey)newValue); + return; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER: + setOwner((ClassToTable)newValue); + return; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__REFERENCED: + setReferenced((ClassToTable)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__NAME: + setName(NAME_EDEFAULT); + return; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__ASSOCIATION: + setAssociation((Association)null); + return; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__FOREIGN_KEY: + setForeignKey((ForeignKey)null); + return; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER: + setOwner((ClassToTable)null); + return; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__REFERENCED: + setReferenced((ClassToTable)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__NAME: + return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__ASSOCIATION: + return association != null; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__FOREIGN_KEY: + return foreignKey != null; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER: + return getOwner() != null; + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__REFERENCED: + return referenced != null; + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) { + if (baseClass == UmlToRdbmsModelElement.class) { + switch (derivedFeatureID) { + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__NAME: return Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME; + default: return -1; + } + } + return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public int eDerivedStructuralFeatureID(int baseFeatureID, Class<?> baseClass) { + if (baseClass == UmlToRdbmsModelElement.class) { + switch (baseFeatureID) { + case Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME: return Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__NAME; + default: return -1; + } + } + return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuffer result = new StringBuffer(super.toString()); + result.append(" (name: "); + result.append(name); + result.append(')'); + return result.toString(); + } + +} //AssociationToForeignKeyImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/AttributeToColumnImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/AttributeToColumnImpl.java new file mode 100644 index 000000000..5d3294c31 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/AttributeToColumnImpl.java @@ -0,0 +1,259 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import org.eclipse.emf.common.notify.Notification; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Attribute To Column</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AttributeToColumnImpl#getColumn <em>Column</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.AttributeToColumnImpl#getType <em>Type</em>}</li> + * </ul> + * + * @generated + */ +public class AttributeToColumnImpl extends FromAttributeImpl implements AttributeToColumn { + /** + * The cached value of the '{@link #getColumn() <em>Column</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getColumn() + * @generated + * @ordered + */ + protected Column column; + + /** + * The cached value of the '{@link #getType() <em>Type</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getType() + * @generated + * @ordered + */ + protected PrimitiveToName type; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected AttributeToColumnImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.ATTRIBUTE_TO_COLUMN; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Column getColumn() { + if (column != null && column.eIsProxy()) { + InternalEObject oldColumn = (InternalEObject)column; + column = (Column)eResolveProxy(oldColumn); + if (column != oldColumn) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__COLUMN, oldColumn, column)); + } + } + return column; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Column basicGetColumn() { + return column; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setColumn(Column newColumn) { + Column oldColumn = column; + column = newColumn; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__COLUMN, oldColumn, column)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public PrimitiveToName getType() { + if (type != null && type.eIsProxy()) { + InternalEObject oldType = (InternalEObject)type; + type = (PrimitiveToName)eResolveProxy(oldType); + if (type != oldType) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__TYPE, oldType, type)); + } + } + return type; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public PrimitiveToName basicGetType() { + return type; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setType(PrimitiveToName newType) { + PrimitiveToName oldType = type; + type = newType; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__TYPE, oldType, type)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__COLUMN: + if (resolve) return getColumn(); + return basicGetColumn(); + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__TYPE: + if (resolve) return getType(); + return basicGetType(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__COLUMN: + setColumn((Column)newValue); + return; + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__TYPE: + setType((PrimitiveToName)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__COLUMN: + setColumn((Column)null); + return; + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__TYPE: + setType((PrimitiveToName)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__COLUMN: + return column != null; + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__TYPE: + return type != null; + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) { + if (baseClass == ToColumn.class) { + switch (derivedFeatureID) { + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__COLUMN: return Simpleuml2rdbmsPackage.TO_COLUMN__COLUMN; + default: return -1; + } + } + return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public int eDerivedStructuralFeatureID(int baseFeatureID, Class<?> baseClass) { + if (baseClass == ToColumn.class) { + switch (baseFeatureID) { + case Simpleuml2rdbmsPackage.TO_COLUMN__COLUMN: return Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN__COLUMN; + default: return -1; + } + } + return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); + } + +} //AttributeToColumnImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/BooleanToBooleanImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/BooleanToBooleanImpl.java new file mode 100644 index 000000000..697bd0867 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/BooleanToBooleanImpl.java @@ -0,0 +1,45 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import org.eclipse.emf.ecore.EClass; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.BooleanToBoolean; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Boolean To Boolean</b></em>'. + * <!-- end-user-doc --> + * + * @generated + */ +public class BooleanToBooleanImpl extends PrimitiveToNameImpl implements BooleanToBoolean { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected BooleanToBooleanImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.BOOLEAN_TO_BOOLEAN; + } + +} //BooleanToBooleanImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/ClassToTableImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/ClassToTableImpl.java new file mode 100644 index 000000000..a28c5b326 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/ClassToTableImpl.java @@ -0,0 +1,608 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.EcoreUtil; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Key; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Table; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Class To Table</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl#getColumn <em>Column</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl#getName <em>Name</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl#getAssociationsToForeignKeys <em>Associations To Foreign Keys</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl#getPrimaryKey <em>Primary Key</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl#getTable <em>Table</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ClassToTableImpl#getUmlClass <em>Uml Class</em>}</li> + * </ul> + * + * @generated + */ +public class ClassToTableImpl extends FromAttributeOwnerImpl implements ClassToTable { + /** + * The cached value of the '{@link #getColumn() <em>Column</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getColumn() + * @generated + * @ordered + */ + protected Column column; + + /** + * The default value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected static final String NAME_EDEFAULT = null; + + /** + * The cached value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected String name = NAME_EDEFAULT; + + /** + * The cached value of the '{@link #getAssociationsToForeignKeys() <em>Associations To Foreign Keys</em>}' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getAssociationsToForeignKeys() + * @generated + * @ordered + */ + protected EList<AssociationToForeignKey> associationsToForeignKeys; + + /** + * The cached value of the '{@link #getPrimaryKey() <em>Primary Key</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getPrimaryKey() + * @generated + * @ordered + */ + protected Key primaryKey; + + /** + * The cached value of the '{@link #getTable() <em>Table</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getTable() + * @generated + * @ordered + */ + protected Table table; + + /** + * The cached value of the '{@link #getUmlClass() <em>Uml Class</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getUmlClass() + * @generated + * @ordered + */ + protected org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class umlClass; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ClassToTableImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.CLASS_TO_TABLE; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Column getColumn() { + if (column != null && column.eIsProxy()) { + InternalEObject oldColumn = (InternalEObject)column; + column = (Column)eResolveProxy(oldColumn); + if (column != oldColumn) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__COLUMN, oldColumn, column)); + } + } + return column; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Column basicGetColumn() { + return column; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setColumn(Column newColumn) { + Column oldColumn = column; + column = newColumn; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__COLUMN, oldColumn, column)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getName() { + return name; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setName(String newName) { + String oldName = name; + name = newName; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__NAME, oldName, name)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<AssociationToForeignKey> getAssociationsToForeignKeys() { + if (associationsToForeignKeys == null) { + associationsToForeignKeys = new EObjectContainmentWithInverseEList<AssociationToForeignKey>(AssociationToForeignKey.class, this, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS, Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY__OWNER); + } + return associationsToForeignKeys; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public PackageToSchema getOwner() { + if (eContainerFeatureID() != Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER) return null; + return (PackageToSchema)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetOwner(PackageToSchema newOwner, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newOwner, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setOwner(PackageToSchema newOwner) { + if (newOwner != eInternalContainer() || (eContainerFeatureID() != Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER && newOwner != null)) { + if (EcoreUtil.isAncestor(this, newOwner)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newOwner != null) + msgs = ((InternalEObject)newOwner).eInverseAdd(this, Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES, PackageToSchema.class, msgs); + msgs = basicSetOwner(newOwner, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER, newOwner, newOwner)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Key getPrimaryKey() { + if (primaryKey != null && primaryKey.eIsProxy()) { + InternalEObject oldPrimaryKey = (InternalEObject)primaryKey; + primaryKey = (Key)eResolveProxy(oldPrimaryKey); + if (primaryKey != oldPrimaryKey) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__PRIMARY_KEY, oldPrimaryKey, primaryKey)); + } + } + return primaryKey; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Key basicGetPrimaryKey() { + return primaryKey; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setPrimaryKey(Key newPrimaryKey) { + Key oldPrimaryKey = primaryKey; + primaryKey = newPrimaryKey; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__PRIMARY_KEY, oldPrimaryKey, primaryKey)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Table getTable() { + if (table != null && table.eIsProxy()) { + InternalEObject oldTable = (InternalEObject)table; + table = (Table)eResolveProxy(oldTable); + if (table != oldTable) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__TABLE, oldTable, table)); + } + } + return table; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Table basicGetTable() { + return table; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setTable(Table newTable) { + Table oldTable = table; + table = newTable; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__TABLE, oldTable, table)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class getUmlClass() { + if (umlClass != null && umlClass.eIsProxy()) { + InternalEObject oldUmlClass = (InternalEObject)umlClass; + umlClass = (org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)eResolveProxy(oldUmlClass); + if (umlClass != oldUmlClass) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__UML_CLASS, oldUmlClass, umlClass)); + } + } + return umlClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class basicGetUmlClass() { + return umlClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setUmlClass(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class newUmlClass) { + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class oldUmlClass = umlClass; + umlClass = newUmlClass; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__UML_CLASS, oldUmlClass, umlClass)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getAssociationsToForeignKeys()).basicAdd(otherEnd, msgs); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetOwner((PackageToSchema)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS: + return ((InternalEList<?>)getAssociationsToForeignKeys()).basicRemove(otherEnd, msgs); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER: + return basicSetOwner(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER: + return eInternalContainer().eInverseRemove(this, Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES, PackageToSchema.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__COLUMN: + if (resolve) return getColumn(); + return basicGetColumn(); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__NAME: + return getName(); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS: + return getAssociationsToForeignKeys(); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER: + return getOwner(); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__PRIMARY_KEY: + if (resolve) return getPrimaryKey(); + return basicGetPrimaryKey(); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__TABLE: + if (resolve) return getTable(); + return basicGetTable(); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__UML_CLASS: + if (resolve) return getUmlClass(); + return basicGetUmlClass(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__COLUMN: + setColumn((Column)newValue); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__NAME: + setName((String)newValue); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS: + getAssociationsToForeignKeys().clear(); + getAssociationsToForeignKeys().addAll((Collection<? extends AssociationToForeignKey>)newValue); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER: + setOwner((PackageToSchema)newValue); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__PRIMARY_KEY: + setPrimaryKey((Key)newValue); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__TABLE: + setTable((Table)newValue); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__UML_CLASS: + setUmlClass((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__COLUMN: + setColumn((Column)null); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__NAME: + setName(NAME_EDEFAULT); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS: + getAssociationsToForeignKeys().clear(); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER: + setOwner((PackageToSchema)null); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__PRIMARY_KEY: + setPrimaryKey((Key)null); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__TABLE: + setTable((Table)null); + return; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__UML_CLASS: + setUmlClass((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Class)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__COLUMN: + return column != null; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__NAME: + return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS: + return associationsToForeignKeys != null && !associationsToForeignKeys.isEmpty(); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER: + return getOwner() != null; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__PRIMARY_KEY: + return primaryKey != null; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__TABLE: + return table != null; + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__UML_CLASS: + return umlClass != null; + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) { + if (baseClass == ToColumn.class) { + switch (derivedFeatureID) { + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__COLUMN: return Simpleuml2rdbmsPackage.TO_COLUMN__COLUMN; + default: return -1; + } + } + if (baseClass == UmlToRdbmsModelElement.class) { + switch (derivedFeatureID) { + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE__NAME: return Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME; + default: return -1; + } + } + return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public int eDerivedStructuralFeatureID(int baseFeatureID, Class<?> baseClass) { + if (baseClass == ToColumn.class) { + switch (baseFeatureID) { + case Simpleuml2rdbmsPackage.TO_COLUMN__COLUMN: return Simpleuml2rdbmsPackage.CLASS_TO_TABLE__COLUMN; + default: return -1; + } + } + if (baseClass == UmlToRdbmsModelElement.class) { + switch (baseFeatureID) { + case Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME: return Simpleuml2rdbmsPackage.CLASS_TO_TABLE__NAME; + default: return -1; + } + } + return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuffer result = new StringBuffer(super.toString()); + result.append(" (name: "); + result.append(name); + result.append(')'); + return result.toString(); + } + +} //ClassToTableImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/FromAttributeImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/FromAttributeImpl.java new file mode 100644 index 000000000..622a24ef6 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/FromAttributeImpl.java @@ -0,0 +1,374 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EObjectResolvingEList; +import org.eclipse.emf.ecore.util.EcoreUtil; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>From Attribute</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeImpl#getKind <em>Kind</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeImpl#getAttribute <em>Attribute</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeImpl#getLeafs <em>Leafs</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeImpl#getOwner <em>Owner</em>}</li> + * </ul> + * + * @generated + */ +public abstract class FromAttributeImpl extends UmlToRdbmsModelElementImpl implements FromAttribute { + /** + * The default value of the '{@link #getKind() <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getKind() + * @generated + * @ordered + */ + protected static final String KIND_EDEFAULT = null; + + /** + * The cached value of the '{@link #getKind() <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getKind() + * @generated + * @ordered + */ + protected String kind = KIND_EDEFAULT; + + /** + * The cached value of the '{@link #getAttribute() <em>Attribute</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getAttribute() + * @generated + * @ordered + */ + protected Attribute attribute; + + /** + * The cached value of the '{@link #getLeafs() <em>Leafs</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getLeafs() + * @generated + * @ordered + */ + protected EList<AttributeToColumn> leafs; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected FromAttributeImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.FROM_ATTRIBUTE; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getKind() { + return kind; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setKind(String newKind) { + String oldKind = kind; + kind = newKind; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__KIND, oldKind, kind)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Attribute getAttribute() { + if (attribute != null && attribute.eIsProxy()) { + InternalEObject oldAttribute = (InternalEObject)attribute; + attribute = (Attribute)eResolveProxy(oldAttribute); + if (attribute != oldAttribute) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__ATTRIBUTE, oldAttribute, attribute)); + } + } + return attribute; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Attribute basicGetAttribute() { + return attribute; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setAttribute(Attribute newAttribute) { + Attribute oldAttribute = attribute; + attribute = newAttribute; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__ATTRIBUTE, oldAttribute, attribute)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<AttributeToColumn> getLeafs() { + if (leafs == null) { + leafs = new EObjectResolvingEList<AttributeToColumn>(AttributeToColumn.class, this, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__LEAFS); + } + return leafs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public FromAttributeOwner getOwner() { + if (eContainerFeatureID() != Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER) return null; + return (FromAttributeOwner)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetOwner(FromAttributeOwner newOwner, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newOwner, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setOwner(FromAttributeOwner newOwner) { + if (newOwner != eInternalContainer() || (eContainerFeatureID() != Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER && newOwner != null)) { + if (EcoreUtil.isAncestor(this, newOwner)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newOwner != null) + msgs = ((InternalEObject)newOwner).eInverseAdd(this, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES, FromAttributeOwner.class, msgs); + msgs = basicSetOwner(newOwner, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER, newOwner, newOwner)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetOwner((FromAttributeOwner)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER: + return basicSetOwner(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER: + return eInternalContainer().eInverseRemove(this, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES, FromAttributeOwner.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__KIND: + return getKind(); + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__ATTRIBUTE: + if (resolve) return getAttribute(); + return basicGetAttribute(); + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__LEAFS: + return getLeafs(); + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER: + return getOwner(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__KIND: + setKind((String)newValue); + return; + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__ATTRIBUTE: + setAttribute((Attribute)newValue); + return; + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__LEAFS: + getLeafs().clear(); + getLeafs().addAll((Collection<? extends AttributeToColumn>)newValue); + return; + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER: + setOwner((FromAttributeOwner)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__KIND: + setKind(KIND_EDEFAULT); + return; + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__ATTRIBUTE: + setAttribute((Attribute)null); + return; + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__LEAFS: + getLeafs().clear(); + return; + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER: + setOwner((FromAttributeOwner)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__KIND: + return KIND_EDEFAULT == null ? kind != null : !KIND_EDEFAULT.equals(kind); + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__ATTRIBUTE: + return attribute != null; + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__LEAFS: + return leafs != null && !leafs.isEmpty(); + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER: + return getOwner() != null; + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuffer result = new StringBuffer(super.toString()); + result.append(" (kind: "); + result.append(kind); + result.append(')'); + return result.toString(); + } + +} //FromAttributeImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/FromAttributeOwnerImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/FromAttributeOwnerImpl.java new file mode 100644 index 000000000..697170410 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/FromAttributeOwnerImpl.java @@ -0,0 +1,175 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>From Attribute Owner</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.FromAttributeOwnerImpl#getFromAttributes <em>From Attributes</em>}</li> + * </ul> + * + * @generated + */ +public abstract class FromAttributeOwnerImpl extends MinimalEObjectImpl.Container implements FromAttributeOwner { + /** + * The cached value of the '{@link #getFromAttributes() <em>From Attributes</em>}' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getFromAttributes() + * @generated + * @ordered + */ + protected EList<FromAttribute> fromAttributes; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected FromAttributeOwnerImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.FROM_ATTRIBUTE_OWNER; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<FromAttribute> getFromAttributes() { + if (fromAttributes == null) { + fromAttributes = new EObjectContainmentWithInverseEList<FromAttribute>(FromAttribute.class, this, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER); + } + return fromAttributes; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getFromAttributes()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES: + return ((InternalEList<?>)getFromAttributes()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES: + return getFromAttributes(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES: + getFromAttributes().clear(); + getFromAttributes().addAll((Collection<? extends FromAttribute>)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES: + getFromAttributes().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES: + return fromAttributes != null && !fromAttributes.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //FromAttributeOwnerImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/IntegerToNumberImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/IntegerToNumberImpl.java new file mode 100644 index 000000000..821637dcf --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/IntegerToNumberImpl.java @@ -0,0 +1,45 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import org.eclipse.emf.ecore.EClass; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.IntegerToNumber; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Integer To Number</b></em>'. + * <!-- end-user-doc --> + * + * @generated + */ +public class IntegerToNumberImpl extends PrimitiveToNameImpl implements IntegerToNumber { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IntegerToNumberImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.INTEGER_TO_NUMBER; + } + +} //IntegerToNumberImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/NonLeafAttributeImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/NonLeafAttributeImpl.java new file mode 100644 index 000000000..2eba8fc2a --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/NonLeafAttributeImpl.java @@ -0,0 +1,480 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EObjectResolvingEList; +import org.eclipse.emf.ecore.util.EcoreUtil; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Attribute; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.NonLeafAttribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Non Leaf Attribute</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.NonLeafAttributeImpl#getName <em>Name</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.NonLeafAttributeImpl#getKind <em>Kind</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.NonLeafAttributeImpl#getAttribute <em>Attribute</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.NonLeafAttributeImpl#getLeafs <em>Leafs</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.NonLeafAttributeImpl#getOwner <em>Owner</em>}</li> + * </ul> + * + * @generated + */ +public class NonLeafAttributeImpl extends FromAttributeOwnerImpl implements NonLeafAttribute { + /** + * The default value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected static final String NAME_EDEFAULT = null; + + /** + * The cached value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected String name = NAME_EDEFAULT; + + /** + * The default value of the '{@link #getKind() <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getKind() + * @generated + * @ordered + */ + protected static final String KIND_EDEFAULT = null; + + /** + * The cached value of the '{@link #getKind() <em>Kind</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getKind() + * @generated + * @ordered + */ + protected String kind = KIND_EDEFAULT; + + /** + * The cached value of the '{@link #getAttribute() <em>Attribute</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getAttribute() + * @generated + * @ordered + */ + protected Attribute attribute; + + /** + * The cached value of the '{@link #getLeafs() <em>Leafs</em>}' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getLeafs() + * @generated + * @ordered + */ + protected EList<AttributeToColumn> leafs; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected NonLeafAttributeImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.NON_LEAF_ATTRIBUTE; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getName() { + return name; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setName(String newName) { + String oldName = name; + name = newName; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__NAME, oldName, name)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getKind() { + return kind; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setKind(String newKind) { + String oldKind = kind; + kind = newKind; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__KIND, oldKind, kind)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Attribute getAttribute() { + if (attribute != null && attribute.eIsProxy()) { + InternalEObject oldAttribute = (InternalEObject)attribute; + attribute = (Attribute)eResolveProxy(oldAttribute); + if (attribute != oldAttribute) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__ATTRIBUTE, oldAttribute, attribute)); + } + } + return attribute; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Attribute basicGetAttribute() { + return attribute; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setAttribute(Attribute newAttribute) { + Attribute oldAttribute = attribute; + attribute = newAttribute; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__ATTRIBUTE, oldAttribute, attribute)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<AttributeToColumn> getLeafs() { + if (leafs == null) { + leafs = new EObjectResolvingEList<AttributeToColumn>(AttributeToColumn.class, this, Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__LEAFS); + } + return leafs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public FromAttributeOwner getOwner() { + if (eContainerFeatureID() != Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER) return null; + return (FromAttributeOwner)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetOwner(FromAttributeOwner newOwner, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newOwner, Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setOwner(FromAttributeOwner newOwner) { + if (newOwner != eInternalContainer() || (eContainerFeatureID() != Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER && newOwner != null)) { + if (EcoreUtil.isAncestor(this, newOwner)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newOwner != null) + msgs = ((InternalEObject)newOwner).eInverseAdd(this, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES, FromAttributeOwner.class, msgs); + msgs = basicSetOwner(newOwner, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER, newOwner, newOwner)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetOwner((FromAttributeOwner)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER: + return basicSetOwner(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER: + return eInternalContainer().eInverseRemove(this, Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES, FromAttributeOwner.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__NAME: + return getName(); + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__KIND: + return getKind(); + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__ATTRIBUTE: + if (resolve) return getAttribute(); + return basicGetAttribute(); + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__LEAFS: + return getLeafs(); + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER: + return getOwner(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__NAME: + setName((String)newValue); + return; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__KIND: + setKind((String)newValue); + return; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__ATTRIBUTE: + setAttribute((Attribute)newValue); + return; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__LEAFS: + getLeafs().clear(); + getLeafs().addAll((Collection<? extends AttributeToColumn>)newValue); + return; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER: + setOwner((FromAttributeOwner)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__NAME: + setName(NAME_EDEFAULT); + return; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__KIND: + setKind(KIND_EDEFAULT); + return; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__ATTRIBUTE: + setAttribute((Attribute)null); + return; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__LEAFS: + getLeafs().clear(); + return; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER: + setOwner((FromAttributeOwner)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__NAME: + return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__KIND: + return KIND_EDEFAULT == null ? kind != null : !KIND_EDEFAULT.equals(kind); + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__ATTRIBUTE: + return attribute != null; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__LEAFS: + return leafs != null && !leafs.isEmpty(); + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER: + return getOwner() != null; + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) { + if (baseClass == UmlToRdbmsModelElement.class) { + switch (derivedFeatureID) { + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__NAME: return Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME; + default: return -1; + } + } + if (baseClass == FromAttribute.class) { + switch (derivedFeatureID) { + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__KIND: return Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__KIND; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__ATTRIBUTE: return Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__ATTRIBUTE; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__LEAFS: return Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__LEAFS; + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER: return Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER; + default: return -1; + } + } + return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public int eDerivedStructuralFeatureID(int baseFeatureID, Class<?> baseClass) { + if (baseClass == UmlToRdbmsModelElement.class) { + switch (baseFeatureID) { + case Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME: return Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__NAME; + default: return -1; + } + } + if (baseClass == FromAttribute.class) { + switch (baseFeatureID) { + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__KIND: return Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__KIND; + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__ATTRIBUTE: return Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__ATTRIBUTE; + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__LEAFS: return Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__LEAFS; + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE__OWNER: return Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE__OWNER; + default: return -1; + } + } + return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuffer result = new StringBuffer(super.toString()); + result.append(" (name: "); + result.append(name); + result.append(", kind: "); + result.append(kind); + result.append(')'); + return result.toString(); + } + +} //NonLeafAttributeImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/PackageToSchemaImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/PackageToSchemaImpl.java new file mode 100644 index 000000000..bbf38df14 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/PackageToSchemaImpl.java @@ -0,0 +1,337 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.InternalEList; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Schema; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Package To Schema</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PackageToSchemaImpl#getClassesToTables <em>Classes To Tables</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PackageToSchemaImpl#getPrimitivesToNames <em>Primitives To Names</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PackageToSchemaImpl#getSchema <em>Schema</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PackageToSchemaImpl#getUmlPackage <em>Uml Package</em>}</li> + * </ul> + * + * @generated + */ +public class PackageToSchemaImpl extends UmlToRdbmsModelElementImpl implements PackageToSchema { + /** + * The cached value of the '{@link #getClassesToTables() <em>Classes To Tables</em>}' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getClassesToTables() + * @generated + * @ordered + */ + protected EList<ClassToTable> classesToTables; + + /** + * The cached value of the '{@link #getPrimitivesToNames() <em>Primitives To Names</em>}' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getPrimitivesToNames() + * @generated + * @ordered + */ + protected EList<PrimitiveToName> primitivesToNames; + + /** + * The cached value of the '{@link #getSchema() <em>Schema</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getSchema() + * @generated + * @ordered + */ + protected Schema schema; + + /** + * The cached value of the '{@link #getUmlPackage() <em>Uml Package</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getUmlPackage() + * @generated + * @ordered + */ + protected org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package umlPackage; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected PackageToSchemaImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.PACKAGE_TO_SCHEMA; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<ClassToTable> getClassesToTables() { + if (classesToTables == null) { + classesToTables = new EObjectContainmentWithInverseEList<ClassToTable>(ClassToTable.class, this, Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES, Simpleuml2rdbmsPackage.CLASS_TO_TABLE__OWNER); + } + return classesToTables; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EList<PrimitiveToName> getPrimitivesToNames() { + if (primitivesToNames == null) { + primitivesToNames = new EObjectContainmentWithInverseEList<PrimitiveToName>(PrimitiveToName.class, this, Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES, Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER); + } + return primitivesToNames; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Schema getSchema() { + if (schema != null && schema.eIsProxy()) { + InternalEObject oldSchema = (InternalEObject)schema; + schema = (Schema)eResolveProxy(oldSchema); + if (schema != oldSchema) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__SCHEMA, oldSchema, schema)); + } + } + return schema; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Schema basicGetSchema() { + return schema; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setSchema(Schema newSchema) { + Schema oldSchema = schema; + schema = newSchema; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__SCHEMA, oldSchema, schema)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package getUmlPackage() { + if (umlPackage != null && umlPackage.eIsProxy()) { + InternalEObject oldUmlPackage = (InternalEObject)umlPackage; + umlPackage = (org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package)eResolveProxy(oldUmlPackage); + if (umlPackage != oldUmlPackage) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__UML_PACKAGE, oldUmlPackage, umlPackage)); + } + } + return umlPackage; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package basicGetUmlPackage() { + return umlPackage; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setUmlPackage(org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package newUmlPackage) { + org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package oldUmlPackage = umlPackage; + umlPackage = newUmlPackage; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__UML_PACKAGE, oldUmlPackage, umlPackage)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getClassesToTables()).basicAdd(otherEnd, msgs); + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES: + return ((InternalEList<InternalEObject>)(InternalEList<?>)getPrimitivesToNames()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES: + return ((InternalEList<?>)getClassesToTables()).basicRemove(otherEnd, msgs); + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES: + return ((InternalEList<?>)getPrimitivesToNames()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES: + return getClassesToTables(); + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES: + return getPrimitivesToNames(); + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__SCHEMA: + if (resolve) return getSchema(); + return basicGetSchema(); + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__UML_PACKAGE: + if (resolve) return getUmlPackage(); + return basicGetUmlPackage(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES: + getClassesToTables().clear(); + getClassesToTables().addAll((Collection<? extends ClassToTable>)newValue); + return; + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES: + getPrimitivesToNames().clear(); + getPrimitivesToNames().addAll((Collection<? extends PrimitiveToName>)newValue); + return; + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__SCHEMA: + setSchema((Schema)newValue); + return; + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__UML_PACKAGE: + setUmlPackage((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES: + getClassesToTables().clear(); + return; + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES: + getPrimitivesToNames().clear(); + return; + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__SCHEMA: + setSchema((Schema)null); + return; + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__UML_PACKAGE: + setUmlPackage((org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.Package)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES: + return classesToTables != null && !classesToTables.isEmpty(); + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES: + return primitivesToNames != null && !primitivesToNames.isEmpty(); + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__SCHEMA: + return schema != null; + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__UML_PACKAGE: + return umlPackage != null; + } + return super.eIsSet(featureID); + } + +} //PackageToSchemaImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/PrimitiveToNameImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/PrimitiveToNameImpl.java new file mode 100644 index 000000000..f8d41ed39 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/PrimitiveToNameImpl.java @@ -0,0 +1,333 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +import org.eclipse.emf.ecore.util.EcoreUtil; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.PrimitiveDataType; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Primitive To Name</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PrimitiveToNameImpl#getTypeName <em>Type Name</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PrimitiveToNameImpl#getOwner <em>Owner</em>}</li> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.PrimitiveToNameImpl#getPrimitive <em>Primitive</em>}</li> + * </ul> + * + * @generated + */ +public abstract class PrimitiveToNameImpl extends UmlToRdbmsModelElementImpl implements PrimitiveToName { + /** + * The default value of the '{@link #getTypeName() <em>Type Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getTypeName() + * @generated + * @ordered + */ + protected static final String TYPE_NAME_EDEFAULT = null; + + /** + * The cached value of the '{@link #getTypeName() <em>Type Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getTypeName() + * @generated + * @ordered + */ + protected String typeName = TYPE_NAME_EDEFAULT; + + /** + * The cached value of the '{@link #getPrimitive() <em>Primitive</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getPrimitive() + * @generated + * @ordered + */ + protected PrimitiveDataType primitive; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected PrimitiveToNameImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.PRIMITIVE_TO_NAME; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getTypeName() { + return typeName; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setTypeName(String newTypeName) { + String oldTypeName = typeName; + typeName = newTypeName; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__TYPE_NAME, oldTypeName, typeName)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public PackageToSchema getOwner() { + if (eContainerFeatureID() != Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER) return null; + return (PackageToSchema)eInternalContainer(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NotificationChain basicSetOwner(PackageToSchema newOwner, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newOwner, Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER, msgs); + return msgs; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setOwner(PackageToSchema newOwner) { + if (newOwner != eInternalContainer() || (eContainerFeatureID() != Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER && newOwner != null)) { + if (EcoreUtil.isAncestor(this, newOwner)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newOwner != null) + msgs = ((InternalEObject)newOwner).eInverseAdd(this, Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES, PackageToSchema.class, msgs); + msgs = basicSetOwner(newOwner, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER, newOwner, newOwner)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public PrimitiveDataType getPrimitive() { + if (primitive != null && primitive.eIsProxy()) { + InternalEObject oldPrimitive = (InternalEObject)primitive; + primitive = (PrimitiveDataType)eResolveProxy(oldPrimitive); + if (primitive != oldPrimitive) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__PRIMITIVE, oldPrimitive, primitive)); + } + } + return primitive; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public PrimitiveDataType basicGetPrimitive() { + return primitive; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setPrimitive(PrimitiveDataType newPrimitive) { + PrimitiveDataType oldPrimitive = primitive; + primitive = newPrimitive; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__PRIMITIVE, oldPrimitive, primitive)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetOwner((PackageToSchema)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER: + return basicSetOwner(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER: + return eInternalContainer().eInverseRemove(this, Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES, PackageToSchema.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__TYPE_NAME: + return getTypeName(); + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER: + return getOwner(); + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__PRIMITIVE: + if (resolve) return getPrimitive(); + return basicGetPrimitive(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__TYPE_NAME: + setTypeName((String)newValue); + return; + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER: + setOwner((PackageToSchema)newValue); + return; + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__PRIMITIVE: + setPrimitive((PrimitiveDataType)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__TYPE_NAME: + setTypeName(TYPE_NAME_EDEFAULT); + return; + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER: + setOwner((PackageToSchema)null); + return; + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__PRIMITIVE: + setPrimitive((PrimitiveDataType)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__TYPE_NAME: + return TYPE_NAME_EDEFAULT == null ? typeName != null : !TYPE_NAME_EDEFAULT.equals(typeName); + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__OWNER: + return getOwner() != null; + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME__PRIMITIVE: + return primitive != null; + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuffer result = new StringBuffer(super.toString()); + result.append(" (typeName: "); + result.append(typeName); + result.append(')'); + return result.toString(); + } + +} //PrimitiveToNameImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/Simpleuml2rdbmsFactoryImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/Simpleuml2rdbmsFactoryImpl.java new file mode 100644 index 000000000..b99d05bd2 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/Simpleuml2rdbmsFactoryImpl.java @@ -0,0 +1,180 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.impl.EFactoryImpl; + +import org.eclipse.emf.ecore.plugin.EcorePlugin; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.*; + +/** + * <!-- begin-user-doc --> + * An implementation of the model <b>Factory</b>. + * <!-- end-user-doc --> + * @generated + */ +public class Simpleuml2rdbmsFactoryImpl extends EFactoryImpl implements Simpleuml2rdbmsFactory { + /** + * Creates the default factory implementation. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public static Simpleuml2rdbmsFactory init() { + try { + Simpleuml2rdbmsFactory theSimpleuml2rdbmsFactory = (Simpleuml2rdbmsFactory)EPackage.Registry.INSTANCE.getEFactory(Simpleuml2rdbmsPackage.eNS_URI); + if (theSimpleuml2rdbmsFactory != null) { + return theSimpleuml2rdbmsFactory; + } + } + catch (Exception exception) { + EcorePlugin.INSTANCE.log(exception); + } + return new Simpleuml2rdbmsFactoryImpl(); + } + + /** + * Creates an instance of the factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Simpleuml2rdbmsFactoryImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public EObject create(EClass eClass) { + switch (eClass.getClassifierID()) { + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN: return createAttributeToColumn(); + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY: return createAssociationToForeignKey(); + case Simpleuml2rdbmsPackage.BOOLEAN_TO_BOOLEAN: return createBooleanToBoolean(); + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE: return createClassToTable(); + case Simpleuml2rdbmsPackage.INTEGER_TO_NUMBER: return createIntegerToNumber(); + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE: return createNonLeafAttribute(); + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA: return createPackageToSchema(); + case Simpleuml2rdbmsPackage.STRING_TO_VARCHAR: return createStringToVarchar(); + default: + throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public AttributeToColumn createAttributeToColumn() { + AttributeToColumnImpl attributeToColumn = new AttributeToColumnImpl(); + return attributeToColumn; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public AssociationToForeignKey createAssociationToForeignKey() { + AssociationToForeignKeyImpl associationToForeignKey = new AssociationToForeignKeyImpl(); + return associationToForeignKey; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public BooleanToBoolean createBooleanToBoolean() { + BooleanToBooleanImpl booleanToBoolean = new BooleanToBooleanImpl(); + return booleanToBoolean; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ClassToTable createClassToTable() { + ClassToTableImpl classToTable = new ClassToTableImpl(); + return classToTable; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public IntegerToNumber createIntegerToNumber() { + IntegerToNumberImpl integerToNumber = new IntegerToNumberImpl(); + return integerToNumber; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public NonLeafAttribute createNonLeafAttribute() { + NonLeafAttributeImpl nonLeafAttribute = new NonLeafAttributeImpl(); + return nonLeafAttribute; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public PackageToSchema createPackageToSchema() { + PackageToSchemaImpl packageToSchema = new PackageToSchemaImpl(); + return packageToSchema; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public StringToVarchar createStringToVarchar() { + StringToVarcharImpl stringToVarchar = new StringToVarcharImpl(); + return stringToVarchar; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Simpleuml2rdbmsPackage getSimpleuml2rdbmsPackage() { + return (Simpleuml2rdbmsPackage)getEPackage(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @deprecated + * @generated + */ + @Deprecated + public static Simpleuml2rdbmsPackage getPackage() { + return Simpleuml2rdbmsPackage.eINSTANCE; + } + +} //Simpleuml2rdbmsFactoryImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/Simpleuml2rdbmsPackageImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/Simpleuml2rdbmsPackageImpl.java new file mode 100644 index 000000000..c53626845 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/Simpleuml2rdbmsPackageImpl.java @@ -0,0 +1,872 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import org.eclipse.emf.ecore.EAttribute; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +import org.eclipse.emf.ecore.impl.EPackageImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.SimplerdbmsPackage; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.impl.SimplerdbmsPackageImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.SimpleumlPackage; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml.impl.SimpleumlPackageImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.BooleanToBoolean; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.IntegerToNumber; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.NonLeafAttribute; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsFactory; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.StringToVarchar; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement; + +/** + * <!-- begin-user-doc --> + * An implementation of the model <b>Package</b>. + * <!-- end-user-doc --> + * @generated + */ +public class Simpleuml2rdbmsPackageImpl extends EPackageImpl implements Simpleuml2rdbmsPackage { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass attributeToColumnEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass associationToForeignKeyEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass booleanToBooleanEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass classToTableEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass fromAttributeEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass fromAttributeOwnerEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass integerToNumberEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass nonLeafAttributeEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass packageToSchemaEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass primitiveToNameEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass stringToVarcharEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass toColumnEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass umlToRdbmsModelElementEClass = null; + + /** + * Creates an instance of the model <b>Package</b>, registered with + * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package + * package URI value. + * <p>Note: the correct way to create the package is via the static + * factory method {@link #init init()}, which also performs + * initialization of the package, or returns the registered package, + * if one already exists. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.ecore.EPackage.Registry + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage#eNS_URI + * @see #init() + * @generated + */ + private Simpleuml2rdbmsPackageImpl() { + super(eNS_URI, Simpleuml2rdbmsFactory.eINSTANCE); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private static boolean isInited = false; + + /** + * Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends. + * + * <p>This method is used to initialize {@link Simpleuml2rdbmsPackage#eINSTANCE} when that field is accessed. + * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #eNS_URI + * @see #createPackageContents() + * @see #initializePackageContents() + * @generated + */ + public static Simpleuml2rdbmsPackage init() { + if (isInited) return (Simpleuml2rdbmsPackage)EPackage.Registry.INSTANCE.getEPackage(Simpleuml2rdbmsPackage.eNS_URI); + + // Obtain or create and register package + Simpleuml2rdbmsPackageImpl theSimpleuml2rdbmsPackage = (Simpleuml2rdbmsPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof Simpleuml2rdbmsPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new Simpleuml2rdbmsPackageImpl()); + + isInited = true; + + // Obtain or create and register interdependencies + SimpleumlPackageImpl theSimpleumlPackage = (SimpleumlPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(SimpleumlPackage.eNS_URI) instanceof SimpleumlPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(SimpleumlPackage.eNS_URI) : SimpleumlPackage.eINSTANCE); + SimplerdbmsPackageImpl theSimplerdbmsPackage = (SimplerdbmsPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(SimplerdbmsPackage.eNS_URI) instanceof SimplerdbmsPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(SimplerdbmsPackage.eNS_URI) : SimplerdbmsPackage.eINSTANCE); + + // Create package meta-data objects + theSimpleuml2rdbmsPackage.createPackageContents(); + theSimpleumlPackage.createPackageContents(); + theSimplerdbmsPackage.createPackageContents(); + + // Initialize created meta-data + theSimpleuml2rdbmsPackage.initializePackageContents(); + theSimpleumlPackage.initializePackageContents(); + theSimplerdbmsPackage.initializePackageContents(); + + // Mark meta-data to indicate it can't be changed + theSimpleuml2rdbmsPackage.freeze(); + + + // Update the registry and return the package + EPackage.Registry.INSTANCE.put(Simpleuml2rdbmsPackage.eNS_URI, theSimpleuml2rdbmsPackage); + return theSimpleuml2rdbmsPackage; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getAttributeToColumn() { + return attributeToColumnEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getAttributeToColumn_Type() { + return (EReference)attributeToColumnEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getAssociationToForeignKey() { + return associationToForeignKeyEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getAssociationToForeignKey_Association() { + return (EReference)associationToForeignKeyEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getAssociationToForeignKey_ForeignKey() { + return (EReference)associationToForeignKeyEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getAssociationToForeignKey_Owner() { + return (EReference)associationToForeignKeyEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getAssociationToForeignKey_Referenced() { + return (EReference)associationToForeignKeyEClass.getEStructuralFeatures().get(3); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getBooleanToBoolean() { + return booleanToBooleanEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getClassToTable() { + return classToTableEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClassToTable_AssociationsToForeignKeys() { + return (EReference)classToTableEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClassToTable_Owner() { + return (EReference)classToTableEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClassToTable_PrimaryKey() { + return (EReference)classToTableEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClassToTable_Table() { + return (EReference)classToTableEClass.getEStructuralFeatures().get(3); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getClassToTable_UmlClass() { + return (EReference)classToTableEClass.getEStructuralFeatures().get(4); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getFromAttribute() { + return fromAttributeEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getFromAttribute_Kind() { + return (EAttribute)fromAttributeEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getFromAttribute_Attribute() { + return (EReference)fromAttributeEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getFromAttribute_Leafs() { + return (EReference)fromAttributeEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getFromAttribute_Owner() { + return (EReference)fromAttributeEClass.getEStructuralFeatures().get(3); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getFromAttributeOwner() { + return fromAttributeOwnerEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getFromAttributeOwner_FromAttributes() { + return (EReference)fromAttributeOwnerEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getIntegerToNumber() { + return integerToNumberEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getNonLeafAttribute() { + return nonLeafAttributeEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getPackageToSchema() { + return packageToSchemaEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getPackageToSchema_ClassesToTables() { + return (EReference)packageToSchemaEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getPackageToSchema_PrimitivesToNames() { + return (EReference)packageToSchemaEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getPackageToSchema_Schema() { + return (EReference)packageToSchemaEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getPackageToSchema_UmlPackage() { + return (EReference)packageToSchemaEClass.getEStructuralFeatures().get(3); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getPrimitiveToName() { + return primitiveToNameEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getPrimitiveToName_TypeName() { + return (EAttribute)primitiveToNameEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getPrimitiveToName_Owner() { + return (EReference)primitiveToNameEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getPrimitiveToName_Primitive() { + return (EReference)primitiveToNameEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getStringToVarchar() { + return stringToVarcharEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getToColumn() { + return toColumnEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getToColumn_Column() { + return (EReference)toColumnEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getUmlToRdbmsModelElement() { + return umlToRdbmsModelElementEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getUmlToRdbmsModelElement_Name() { + return (EAttribute)umlToRdbmsModelElementEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Simpleuml2rdbmsFactory getSimpleuml2rdbmsFactory() { + return (Simpleuml2rdbmsFactory)getEFactoryInstance(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private boolean isCreated = false; + + /** + * Creates the meta-model objects for the package. This method is + * guarded to have no affect on any invocation but its first. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void createPackageContents() { + if (isCreated) return; + isCreated = true; + + // Create classes and their features + attributeToColumnEClass = createEClass(ATTRIBUTE_TO_COLUMN); + createEReference(attributeToColumnEClass, ATTRIBUTE_TO_COLUMN__TYPE); + + associationToForeignKeyEClass = createEClass(ASSOCIATION_TO_FOREIGN_KEY); + createEReference(associationToForeignKeyEClass, ASSOCIATION_TO_FOREIGN_KEY__ASSOCIATION); + createEReference(associationToForeignKeyEClass, ASSOCIATION_TO_FOREIGN_KEY__FOREIGN_KEY); + createEReference(associationToForeignKeyEClass, ASSOCIATION_TO_FOREIGN_KEY__OWNER); + createEReference(associationToForeignKeyEClass, ASSOCIATION_TO_FOREIGN_KEY__REFERENCED); + + booleanToBooleanEClass = createEClass(BOOLEAN_TO_BOOLEAN); + + classToTableEClass = createEClass(CLASS_TO_TABLE); + createEReference(classToTableEClass, CLASS_TO_TABLE__ASSOCIATIONS_TO_FOREIGN_KEYS); + createEReference(classToTableEClass, CLASS_TO_TABLE__OWNER); + createEReference(classToTableEClass, CLASS_TO_TABLE__PRIMARY_KEY); + createEReference(classToTableEClass, CLASS_TO_TABLE__TABLE); + createEReference(classToTableEClass, CLASS_TO_TABLE__UML_CLASS); + + fromAttributeEClass = createEClass(FROM_ATTRIBUTE); + createEAttribute(fromAttributeEClass, FROM_ATTRIBUTE__KIND); + createEReference(fromAttributeEClass, FROM_ATTRIBUTE__ATTRIBUTE); + createEReference(fromAttributeEClass, FROM_ATTRIBUTE__LEAFS); + createEReference(fromAttributeEClass, FROM_ATTRIBUTE__OWNER); + + fromAttributeOwnerEClass = createEClass(FROM_ATTRIBUTE_OWNER); + createEReference(fromAttributeOwnerEClass, FROM_ATTRIBUTE_OWNER__FROM_ATTRIBUTES); + + integerToNumberEClass = createEClass(INTEGER_TO_NUMBER); + + nonLeafAttributeEClass = createEClass(NON_LEAF_ATTRIBUTE); + + packageToSchemaEClass = createEClass(PACKAGE_TO_SCHEMA); + createEReference(packageToSchemaEClass, PACKAGE_TO_SCHEMA__CLASSES_TO_TABLES); + createEReference(packageToSchemaEClass, PACKAGE_TO_SCHEMA__PRIMITIVES_TO_NAMES); + createEReference(packageToSchemaEClass, PACKAGE_TO_SCHEMA__SCHEMA); + createEReference(packageToSchemaEClass, PACKAGE_TO_SCHEMA__UML_PACKAGE); + + primitiveToNameEClass = createEClass(PRIMITIVE_TO_NAME); + createEAttribute(primitiveToNameEClass, PRIMITIVE_TO_NAME__TYPE_NAME); + createEReference(primitiveToNameEClass, PRIMITIVE_TO_NAME__OWNER); + createEReference(primitiveToNameEClass, PRIMITIVE_TO_NAME__PRIMITIVE); + + stringToVarcharEClass = createEClass(STRING_TO_VARCHAR); + + toColumnEClass = createEClass(TO_COLUMN); + createEReference(toColumnEClass, TO_COLUMN__COLUMN); + + umlToRdbmsModelElementEClass = createEClass(UML_TO_RDBMS_MODEL_ELEMENT); + createEAttribute(umlToRdbmsModelElementEClass, UML_TO_RDBMS_MODEL_ELEMENT__NAME); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private boolean isInitialized = false; + + /** + * Complete the initialization of the package and its meta-model. This + * method is guarded to have no affect on any invocation but its first. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void initializePackageContents() { + if (isInitialized) return; + isInitialized = true; + + // Initialize package + setName(eNAME); + setNsPrefix(eNS_PREFIX); + setNsURI(eNS_URI); + + // Obtain other dependent packages + SimpleumlPackage theSimpleumlPackage = (SimpleumlPackage)EPackage.Registry.INSTANCE.getEPackage(SimpleumlPackage.eNS_URI); + SimplerdbmsPackage theSimplerdbmsPackage = (SimplerdbmsPackage)EPackage.Registry.INSTANCE.getEPackage(SimplerdbmsPackage.eNS_URI); + + // Create type parameters + + // Set bounds for type parameters + + // Add supertypes to classes + attributeToColumnEClass.getESuperTypes().add(this.getFromAttribute()); + attributeToColumnEClass.getESuperTypes().add(this.getToColumn()); + associationToForeignKeyEClass.getESuperTypes().add(this.getToColumn()); + associationToForeignKeyEClass.getESuperTypes().add(this.getUmlToRdbmsModelElement()); + booleanToBooleanEClass.getESuperTypes().add(this.getPrimitiveToName()); + classToTableEClass.getESuperTypes().add(this.getFromAttributeOwner()); + classToTableEClass.getESuperTypes().add(this.getToColumn()); + classToTableEClass.getESuperTypes().add(this.getUmlToRdbmsModelElement()); + fromAttributeEClass.getESuperTypes().add(this.getUmlToRdbmsModelElement()); + integerToNumberEClass.getESuperTypes().add(this.getPrimitiveToName()); + nonLeafAttributeEClass.getESuperTypes().add(this.getFromAttributeOwner()); + nonLeafAttributeEClass.getESuperTypes().add(this.getFromAttribute()); + packageToSchemaEClass.getESuperTypes().add(this.getUmlToRdbmsModelElement()); + primitiveToNameEClass.getESuperTypes().add(this.getUmlToRdbmsModelElement()); + stringToVarcharEClass.getESuperTypes().add(this.getPrimitiveToName()); + + // Initialize classes, features, and operations; add parameters + initEClass(attributeToColumnEClass, AttributeToColumn.class, "AttributeToColumn", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getAttributeToColumn_Type(), this.getPrimitiveToName(), null, "type", null, 0, 1, AttributeToColumn.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(associationToForeignKeyEClass, AssociationToForeignKey.class, "AssociationToForeignKey", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getAssociationToForeignKey_Association(), theSimpleumlPackage.getAssociation(), null, "association", null, 0, 1, AssociationToForeignKey.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getAssociationToForeignKey_ForeignKey(), theSimplerdbmsPackage.getForeignKey(), null, "foreignKey", null, 0, 1, AssociationToForeignKey.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getAssociationToForeignKey_Owner(), this.getClassToTable(), this.getClassToTable_AssociationsToForeignKeys(), "owner", null, 1, 1, AssociationToForeignKey.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getAssociationToForeignKey_Referenced(), this.getClassToTable(), null, "referenced", null, 0, 1, AssociationToForeignKey.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(booleanToBooleanEClass, BooleanToBoolean.class, "BooleanToBoolean", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(classToTableEClass, ClassToTable.class, "ClassToTable", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getClassToTable_AssociationsToForeignKeys(), this.getAssociationToForeignKey(), this.getAssociationToForeignKey_Owner(), "associationsToForeignKeys", null, 0, -1, ClassToTable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getClassToTable_Owner(), this.getPackageToSchema(), this.getPackageToSchema_ClassesToTables(), "owner", null, 1, 1, ClassToTable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getClassToTable_PrimaryKey(), theSimplerdbmsPackage.getKey(), null, "primaryKey", null, 0, 1, ClassToTable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getClassToTable_Table(), theSimplerdbmsPackage.getTable(), null, "table", null, 0, 1, ClassToTable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getClassToTable_UmlClass(), theSimpleumlPackage.getClass_(), null, "umlClass", null, 0, 1, ClassToTable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(fromAttributeEClass, FromAttribute.class, "FromAttribute", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEAttribute(getFromAttribute_Kind(), ecorePackage.getEString(), "kind", null, 0, 1, FromAttribute.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getFromAttribute_Attribute(), theSimpleumlPackage.getAttribute(), null, "attribute", null, 0, 1, FromAttribute.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getFromAttribute_Leafs(), this.getAttributeToColumn(), null, "leafs", null, 0, -1, FromAttribute.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + initEReference(getFromAttribute_Owner(), this.getFromAttributeOwner(), this.getFromAttributeOwner_FromAttributes(), "owner", null, 1, 1, FromAttribute.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(fromAttributeOwnerEClass, FromAttributeOwner.class, "FromAttributeOwner", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFromAttributeOwner_FromAttributes(), this.getFromAttribute(), this.getFromAttribute_Owner(), "fromAttributes", null, 0, -1, FromAttributeOwner.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + + initEClass(integerToNumberEClass, IntegerToNumber.class, "IntegerToNumber", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(nonLeafAttributeEClass, NonLeafAttribute.class, "NonLeafAttribute", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(packageToSchemaEClass, PackageToSchema.class, "PackageToSchema", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getPackageToSchema_ClassesToTables(), this.getClassToTable(), this.getClassToTable_Owner(), "classesToTables", null, 1, -1, PackageToSchema.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + initEReference(getPackageToSchema_PrimitivesToNames(), this.getPrimitiveToName(), this.getPrimitiveToName_Owner(), "primitivesToNames", null, 0, -1, PackageToSchema.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + initEReference(getPackageToSchema_Schema(), theSimplerdbmsPackage.getSchema(), null, "schema", null, 1, 1, PackageToSchema.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getPackageToSchema_UmlPackage(), theSimpleumlPackage.getPackage(), null, "umlPackage", null, 1, 1, PackageToSchema.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(primitiveToNameEClass, PrimitiveToName.class, "PrimitiveToName", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEAttribute(getPrimitiveToName_TypeName(), ecorePackage.getEString(), "typeName", null, 1, 1, PrimitiveToName.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getPrimitiveToName_Owner(), this.getPackageToSchema(), this.getPackageToSchema_PrimitivesToNames(), "owner", null, 1, 1, PrimitiveToName.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getPrimitiveToName_Primitive(), theSimpleumlPackage.getPrimitiveDataType(), null, "primitive", null, 1, 1, PrimitiveToName.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(stringToVarcharEClass, StringToVarchar.class, "StringToVarchar", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(toColumnEClass, ToColumn.class, "ToColumn", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getToColumn_Column(), theSimplerdbmsPackage.getColumn(), null, "column", null, 1, 1, ToColumn.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(umlToRdbmsModelElementEClass, UmlToRdbmsModelElement.class, "UmlToRdbmsModelElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEAttribute(getUmlToRdbmsModelElement_Name(), ecorePackage.getEString(), "name", null, 0, 1, UmlToRdbmsModelElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + // Create resource + createResource(eNS_URI); + + // Create annotations + // http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper + createEmofAnnotations(); + // http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName + createEmof_1Annotations(); + } + + /** + * Initializes the annotations for <b>http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper</b>. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void createEmofAnnotations() { + String source = "http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeUpper"; + addAnnotation + (getAssociationToForeignKey_Association(), + source, + new String[] { + "body", "1" + }); + addAnnotation + (getAssociationToForeignKey_ForeignKey(), + source, + new String[] { + "body", "1" + }); + addAnnotation + (getClassToTable_PrimaryKey(), + source, + new String[] { + "body", "1" + }); + addAnnotation + (getClassToTable_Table(), + source, + new String[] { + "body", "1" + }); + addAnnotation + (getClassToTable_UmlClass(), + source, + new String[] { + "body", "1" + }); + addAnnotation + (getFromAttribute_Attribute(), + source, + new String[] { + "body", "1" + }); + addAnnotation + (getPackageToSchema_Schema(), + source, + new String[] { + "body", "1" + }); + addAnnotation + (getPackageToSchema_UmlPackage(), + source, + new String[] { + "body", "1" + }); + addAnnotation + (getPrimitiveToName_Primitive(), + source, + new String[] { + "body", "1" + }); + addAnnotation + (getToColumn_Column(), + source, + new String[] { + "body", "1" + }); + } + + /** + * Initializes the annotations for <b>http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName</b>. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void createEmof_1Annotations() { + String source = "http://schema.omg.org/spec/MOF/2.0/emof.xml#Property.oppositeRoleName"; + addAnnotation + (getAssociationToForeignKey_Association(), + source, + new String[] { + "body", "middle" + }); + addAnnotation + (getAssociationToForeignKey_ForeignKey(), + source, + new String[] { + "body", "middle" + }); + addAnnotation + (getClassToTable_PrimaryKey(), + source, + new String[] { + "body", "middle" + }); + addAnnotation + (getClassToTable_Table(), + source, + new String[] { + "body", "middle" + }); + addAnnotation + (getClassToTable_UmlClass(), + source, + new String[] { + "body", "middle" + }); + addAnnotation + (getFromAttribute_Attribute(), + source, + new String[] { + "body", "middle" + }); + addAnnotation + (getPackageToSchema_Schema(), + source, + new String[] { + "body", "middle" + }); + addAnnotation + (getPackageToSchema_UmlPackage(), + source, + new String[] { + "body", "middle" + }); + addAnnotation + (getPrimitiveToName_Primitive(), + source, + new String[] { + "body", "middle" + }); + addAnnotation + (getToColumn_Column(), + source, + new String[] { + "body", "middle" + }); + } + +} //Simpleuml2rdbmsPackageImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/StringToVarcharImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/StringToVarcharImpl.java new file mode 100644 index 000000000..2a712668c --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/StringToVarcharImpl.java @@ -0,0 +1,45 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import org.eclipse.emf.ecore.EClass; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.StringToVarchar; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>String To Varchar</b></em>'. + * <!-- end-user-doc --> + * + * @generated + */ +public class StringToVarcharImpl extends PrimitiveToNameImpl implements StringToVarchar { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected StringToVarcharImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.STRING_TO_VARCHAR; + } + +} //StringToVarcharImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/ToColumnImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/ToColumnImpl.java new file mode 100644 index 000000000..898491656 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/ToColumnImpl.java @@ -0,0 +1,166 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import org.eclipse.emf.common.notify.Notification; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simplerdbms.Column; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>To Column</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.ToColumnImpl#getColumn <em>Column</em>}</li> + * </ul> + * + * @generated + */ +public abstract class ToColumnImpl extends MinimalEObjectImpl.Container implements ToColumn { + /** + * The cached value of the '{@link #getColumn() <em>Column</em>}' reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getColumn() + * @generated + * @ordered + */ + protected Column column; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ToColumnImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.TO_COLUMN; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Column getColumn() { + if (column != null && column.eIsProxy()) { + InternalEObject oldColumn = (InternalEObject)column; + column = (Column)eResolveProxy(oldColumn); + if (column != oldColumn) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, Simpleuml2rdbmsPackage.TO_COLUMN__COLUMN, oldColumn, column)); + } + } + return column; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Column basicGetColumn() { + return column; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setColumn(Column newColumn) { + Column oldColumn = column; + column = newColumn; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.TO_COLUMN__COLUMN, oldColumn, column)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case Simpleuml2rdbmsPackage.TO_COLUMN__COLUMN: + if (resolve) return getColumn(); + return basicGetColumn(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case Simpleuml2rdbmsPackage.TO_COLUMN__COLUMN: + setColumn((Column)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.TO_COLUMN__COLUMN: + setColumn((Column)null); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.TO_COLUMN__COLUMN: + return column != null; + } + return super.eIsSet(featureID); + } + +} //ToColumnImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/UmlToRdbmsModelElementImpl.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/UmlToRdbmsModelElementImpl.java new file mode 100644 index 000000000..4f49234dc --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/impl/UmlToRdbmsModelElementImpl.java @@ -0,0 +1,171 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl; + +import org.eclipse.emf.common.notify.Notification; + +import org.eclipse.emf.ecore.EClass; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage; +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Uml To Rdbms Model Element</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * </p> + * <ul> + * <li>{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.impl.UmlToRdbmsModelElementImpl#getName <em>Name</em>}</li> + * </ul> + * + * @generated + */ +public abstract class UmlToRdbmsModelElementImpl extends MinimalEObjectImpl.Container implements UmlToRdbmsModelElement { + /** + * The default value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected static final String NAME_EDEFAULT = null; + + /** + * The cached value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected String name = NAME_EDEFAULT; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected UmlToRdbmsModelElementImpl() { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() { + return Simpleuml2rdbmsPackage.Literals.UML_TO_RDBMS_MODEL_ELEMENT; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getName() { + return name; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setName(String newName) { + String oldName = name; + name = newName; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME, oldName, name)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME: + return getName(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME: + setName((String)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME: + setName(NAME_EDEFAULT); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT__NAME: + return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuffer result = new StringBuffer(super.toString()); + result.append(" (name: "); + result.append(name); + result.append(')'); + return result.toString(); + } + +} //UmlToRdbmsModelElementImpl diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/util/Simpleuml2rdbmsAdapterFactory.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/util/Simpleuml2rdbmsAdapterFactory.java new file mode 100644 index 000000000..6cfb797f5 --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/util/Simpleuml2rdbmsAdapterFactory.java @@ -0,0 +1,344 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.util; + +import org.eclipse.emf.common.notify.Adapter; +import org.eclipse.emf.common.notify.Notifier; + +import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; + +import org.eclipse.emf.ecore.EObject; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.*; + +/** + * <!-- begin-user-doc --> + * The <b>Adapter Factory</b> for the model. + * It provides an adapter <code>createXXX</code> method for each class of the model. + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage + * @generated + */ +public class Simpleuml2rdbmsAdapterFactory extends AdapterFactoryImpl { + /** + * The cached model package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected static Simpleuml2rdbmsPackage modelPackage; + + /** + * Creates an instance of the adapter factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Simpleuml2rdbmsAdapterFactory() { + if (modelPackage == null) { + modelPackage = Simpleuml2rdbmsPackage.eINSTANCE; + } + } + + /** + * Returns whether this factory is applicable for the type of the object. + * <!-- begin-user-doc --> + * This implementation returns <code>true</code> if the object is either the model's package or is an instance object of the model. + * <!-- end-user-doc --> + * @return whether this factory is applicable for the type of the object. + * @generated + */ + @Override + public boolean isFactoryForType(Object object) { + if (object == modelPackage) { + return true; + } + if (object instanceof EObject) { + return ((EObject)object).eClass().getEPackage() == modelPackage; + } + return false; + } + + /** + * The switch that delegates to the <code>createXXX</code> methods. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Simpleuml2rdbmsSwitch<Adapter> modelSwitch = + new Simpleuml2rdbmsSwitch<Adapter>() { + @Override + public Adapter caseAttributeToColumn(AttributeToColumn object) { + return createAttributeToColumnAdapter(); + } + @Override + public Adapter caseAssociationToForeignKey(AssociationToForeignKey object) { + return createAssociationToForeignKeyAdapter(); + } + @Override + public Adapter caseBooleanToBoolean(BooleanToBoolean object) { + return createBooleanToBooleanAdapter(); + } + @Override + public Adapter caseClassToTable(ClassToTable object) { + return createClassToTableAdapter(); + } + @Override + public Adapter caseFromAttribute(FromAttribute object) { + return createFromAttributeAdapter(); + } + @Override + public Adapter caseFromAttributeOwner(FromAttributeOwner object) { + return createFromAttributeOwnerAdapter(); + } + @Override + public Adapter caseIntegerToNumber(IntegerToNumber object) { + return createIntegerToNumberAdapter(); + } + @Override + public Adapter caseNonLeafAttribute(NonLeafAttribute object) { + return createNonLeafAttributeAdapter(); + } + @Override + public Adapter casePackageToSchema(PackageToSchema object) { + return createPackageToSchemaAdapter(); + } + @Override + public Adapter casePrimitiveToName(PrimitiveToName object) { + return createPrimitiveToNameAdapter(); + } + @Override + public Adapter caseStringToVarchar(StringToVarchar object) { + return createStringToVarcharAdapter(); + } + @Override + public Adapter caseToColumn(ToColumn object) { + return createToColumnAdapter(); + } + @Override + public Adapter caseUmlToRdbmsModelElement(UmlToRdbmsModelElement object) { + return createUmlToRdbmsModelElementAdapter(); + } + @Override + public Adapter defaultCase(EObject object) { + return createEObjectAdapter(); + } + }; + + /** + * Creates an adapter for the <code>target</code>. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param target the object to adapt. + * @return the adapter for the <code>target</code>. + * @generated + */ + @Override + public Adapter createAdapter(Notifier target) { + return modelSwitch.doSwitch((EObject)target); + } + + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn <em>Attribute To Column</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AttributeToColumn + * @generated + */ + public Adapter createAttributeToColumnAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey <em>Association To Foreign Key</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.AssociationToForeignKey + * @generated + */ + public Adapter createAssociationToForeignKeyAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.BooleanToBoolean <em>Boolean To Boolean</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.BooleanToBoolean + * @generated + */ + public Adapter createBooleanToBooleanAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable <em>Class To Table</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ClassToTable + * @generated + */ + public Adapter createClassToTableAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute <em>From Attribute</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttribute + * @generated + */ + public Adapter createFromAttributeAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner <em>From Attribute Owner</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.FromAttributeOwner + * @generated + */ + public Adapter createFromAttributeOwnerAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.IntegerToNumber <em>Integer To Number</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.IntegerToNumber + * @generated + */ + public Adapter createIntegerToNumberAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.NonLeafAttribute <em>Non Leaf Attribute</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.NonLeafAttribute + * @generated + */ + public Adapter createNonLeafAttributeAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema <em>Package To Schema</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PackageToSchema + * @generated + */ + public Adapter createPackageToSchemaAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName <em>Primitive To Name</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.PrimitiveToName + * @generated + */ + public Adapter createPrimitiveToNameAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.StringToVarchar <em>String To Varchar</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.StringToVarchar + * @generated + */ + public Adapter createStringToVarcharAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn <em>To Column</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.ToColumn + * @generated + */ + public Adapter createToColumnAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement <em>Uml To Rdbms Model Element</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.UmlToRdbmsModelElement + * @generated + */ + public Adapter createUmlToRdbmsModelElementAdapter() { + return null; + } + + /** + * Creates a new adapter for the default case. + * <!-- begin-user-doc --> + * This default implementation returns null. + * <!-- end-user-doc --> + * @return the new adapter. + * @generated + */ + public Adapter createEObjectAdapter() { + return null; + } + +} //Simpleuml2rdbmsAdapterFactory diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/util/Simpleuml2rdbmsSwitch.java b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/util/Simpleuml2rdbmsSwitch.java new file mode 100644 index 000000000..0804a138f --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src-gen/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/simpleuml2rdbms/util/Simpleuml2rdbmsSwitch.java @@ -0,0 +1,390 @@ +/** + * Copyright (c) 2015, 2016 Willink Transformations 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: + * E.D.Willink - Initial API and implementation + */ +package org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.util; + +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.util.Switch; + +import org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.*; + +/** + * <!-- begin-user-doc --> + * The <b>Switch</b> for the model's inheritance hierarchy. + * It supports the call {@link #doSwitch(EObject) doSwitch(object)} + * to invoke the <code>caseXXX</code> method for each class of the model, + * starting with the actual class of the object + * and proceeding up the inheritance hierarchy + * until a non-null result is returned, + * which is the result of the switch. + * <!-- end-user-doc --> + * @see org.eclipse.qvtd.examples.qvtcore.uml2rdbms.simpleuml2rdbms.Simpleuml2rdbmsPackage + * @generated + */ +public class Simpleuml2rdbmsSwitch<T> extends Switch<T> { + /** + * The cached model package + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected static Simpleuml2rdbmsPackage modelPackage; + + /** + * Creates an instance of the switch. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Simpleuml2rdbmsSwitch() { + if (modelPackage == null) { + modelPackage = Simpleuml2rdbmsPackage.eINSTANCE; + } + } + + /** + * Checks whether this is a switch for the given package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param ePackage the package in question. + * @return whether this is a switch for the given package. + * @generated + */ + @Override + protected boolean isSwitchFor(EPackage ePackage) { + return ePackage == modelPackage; + } + + /** + * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the first non-null result returned by a <code>caseXXX</code> call. + * @generated + */ + @Override + protected T doSwitch(int classifierID, EObject theEObject) { + switch (classifierID) { + case Simpleuml2rdbmsPackage.ATTRIBUTE_TO_COLUMN: { + AttributeToColumn attributeToColumn = (AttributeToColumn)theEObject; + T result = caseAttributeToColumn(attributeToColumn); + if (result == null) result = caseFromAttribute(attributeToColumn); + if (result == null) result = caseToColumn(attributeToColumn); + if (result == null) result = caseUmlToRdbmsModelElement(attributeToColumn); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.ASSOCIATION_TO_FOREIGN_KEY: { + AssociationToForeignKey associationToForeignKey = (AssociationToForeignKey)theEObject; + T result = caseAssociationToForeignKey(associationToForeignKey); + if (result == null) result = caseToColumn(associationToForeignKey); + if (result == null) result = caseUmlToRdbmsModelElement(associationToForeignKey); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.BOOLEAN_TO_BOOLEAN: { + BooleanToBoolean booleanToBoolean = (BooleanToBoolean)theEObject; + T result = caseBooleanToBoolean(booleanToBoolean); + if (result == null) result = casePrimitiveToName(booleanToBoolean); + if (result == null) result = caseUmlToRdbmsModelElement(booleanToBoolean); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.CLASS_TO_TABLE: { + ClassToTable classToTable = (ClassToTable)theEObject; + T result = caseClassToTable(classToTable); + if (result == null) result = caseFromAttributeOwner(classToTable); + if (result == null) result = caseToColumn(classToTable); + if (result == null) result = caseUmlToRdbmsModelElement(classToTable); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE: { + FromAttribute fromAttribute = (FromAttribute)theEObject; + T result = caseFromAttribute(fromAttribute); + if (result == null) result = caseUmlToRdbmsModelElement(fromAttribute); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.FROM_ATTRIBUTE_OWNER: { + FromAttributeOwner fromAttributeOwner = (FromAttributeOwner)theEObject; + T result = caseFromAttributeOwner(fromAttributeOwner); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.INTEGER_TO_NUMBER: { + IntegerToNumber integerToNumber = (IntegerToNumber)theEObject; + T result = caseIntegerToNumber(integerToNumber); + if (result == null) result = casePrimitiveToName(integerToNumber); + if (result == null) result = caseUmlToRdbmsModelElement(integerToNumber); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.NON_LEAF_ATTRIBUTE: { + NonLeafAttribute nonLeafAttribute = (NonLeafAttribute)theEObject; + T result = caseNonLeafAttribute(nonLeafAttribute); + if (result == null) result = caseFromAttributeOwner(nonLeafAttribute); + if (result == null) result = caseFromAttribute(nonLeafAttribute); + if (result == null) result = caseUmlToRdbmsModelElement(nonLeafAttribute); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.PACKAGE_TO_SCHEMA: { + PackageToSchema packageToSchema = (PackageToSchema)theEObject; + T result = casePackageToSchema(packageToSchema); + if (result == null) result = caseUmlToRdbmsModelElement(packageToSchema); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.PRIMITIVE_TO_NAME: { + PrimitiveToName primitiveToName = (PrimitiveToName)theEObject; + T result = casePrimitiveToName(primitiveToName); + if (result == null) result = caseUmlToRdbmsModelElement(primitiveToName); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.STRING_TO_VARCHAR: { + StringToVarchar stringToVarchar = (StringToVarchar)theEObject; + T result = caseStringToVarchar(stringToVarchar); + if (result == null) result = casePrimitiveToName(stringToVarchar); + if (result == null) result = caseUmlToRdbmsModelElement(stringToVarchar); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.TO_COLUMN: { + ToColumn toColumn = (ToColumn)theEObject; + T result = caseToColumn(toColumn); + if (result == null) result = defaultCase(theEObject); + return result; + } + case Simpleuml2rdbmsPackage.UML_TO_RDBMS_MODEL_ELEMENT: { + UmlToRdbmsModelElement umlToRdbmsModelElement = (UmlToRdbmsModelElement)theEObject; + T result = caseUmlToRdbmsModelElement(umlToRdbmsModelElement); + if (result == null) result = defaultCase(theEObject); + return result; + } + default: return defaultCase(theEObject); + } + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Attribute To Column</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Attribute To Column</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseAttributeToColumn(AttributeToColumn object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Association To Foreign Key</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Association To Foreign Key</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseAssociationToForeignKey(AssociationToForeignKey object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Boolean To Boolean</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Boolean To Boolean</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseBooleanToBoolean(BooleanToBoolean object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Class To Table</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Class To Table</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseClassToTable(ClassToTable object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>From Attribute</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>From Attribute</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFromAttribute(FromAttribute object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>From Attribute Owner</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>From Attribute Owner</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFromAttributeOwner(FromAttributeOwner object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Integer To Number</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Integer To Number</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseIntegerToNumber(IntegerToNumber object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Non Leaf Attribute</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Non Leaf Attribute</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseNonLeafAttribute(NonLeafAttribute object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Package To Schema</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Package To Schema</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T casePackageToSchema(PackageToSchema object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Primitive To Name</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Primitive To Name</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T casePrimitiveToName(PrimitiveToName object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>String To Varchar</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>String To Varchar</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseStringToVarchar(StringToVarchar object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>To Column</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>To Column</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseToColumn(ToColumn object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Uml To Rdbms Model Element</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Uml To Rdbms Model Element</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseUmlToRdbmsModelElement(UmlToRdbmsModelElement object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>EObject</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch, but this is the last case anyway. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>EObject</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) + * @generated + */ + @Override + public T defaultCase(EObject object) { + return null; + } + +} //Simpleuml2rdbmsSwitch diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvtc b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvtc index 136a97562..40805c4df 100644 --- a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvtc +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUML2RDBMS.qvtc @@ -2,7 +2,7 @@ import SimpleUML : 'SimpleUML.ecore#/'; import SimpleRDBMS : 'SimpleRDBMS.ecore#/'; import SimpleUML2RDBMS : 'SimpleUML2RDBMS.ecore#/'; -transformation umlRdbms +transformation org::eclipse::qvtd::examples::qvtcore::uml2rdbms::umlRdbms { uml imports simpleuml; rdbms imports simplerdbms; diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUMLPeople.xmi b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/in/SimpleUMLPeople.xmi index 13609c830..13609c830 100644 --- a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleUMLPeople.xmi +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/in/SimpleUMLPeople.xmi diff --git a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleRDBMSPeople_expected.xmi b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/out/SimpleRDBMSPeople_expected.xmi index 864612d33..864612d33 100644 --- a/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/SimpleRDBMSPeople_expected.xmi +++ b/examples/org.eclipse.qvtd.examples.qvtcore.uml2rdbms/src/org/eclipse/qvtd/examples/qvtcore/uml2rdbms/out/SimpleRDBMSPeople_expected.xmi diff --git a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/.classpath b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/.classpath index eca7bdba8..f0c554985 100644 --- a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/.classpath +++ b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/.classpath @@ -3,5 +3,6 @@ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/> <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> <classpathentry kind="src" path="src"/> + <classpathentry kind="src" path="src-gen"/> <classpathentry kind="output" path="bin"/> </classpath> diff --git a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/.settings/HierarchicalStateMachine2FlatStateMachine.qvtr.launch b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/.settings/HierarchicalStateMachine2FlatStateMachine.qvtr.launch index d7051b9d6..13a294fe8 100644 --- a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/.settings/HierarchicalStateMachine2FlatStateMachine.qvtr.launch +++ b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/.settings/HierarchicalStateMachine2FlatStateMachine.qvtr.launch @@ -3,26 +3,29 @@ <booleanAttribute key="auto-build" value="false"/>
<booleanAttribute key="console-trace" value="false"/>
<stringAttribute key="direction" value="flat"/>
-<stringAttribute key="genmodel" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/HierarchicalStateMachine2FlatStateMachine.genmodel"/>
+<stringAttribute key="genmodel" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/temp/HierarchicalStateMachine2FlatStateMachine.genmodel"/>
<mapAttribute key="in">
-<mapEntry key="hier" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/SimpleModel.xmi"/>
+<mapEntry key="hier" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/in/hier.xmi"/>
</mapAttribute>
<mapAttribute key="intermediates">
-<mapEntry key="QVTc" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/HierarchicalStateMachine2FlatStateMachine.qvtcas"/>
-<mapEntry key="QVTi" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/HierarchicalStateMachine2FlatStateMachine.qvtias"/>
-<mapEntry key="QVTm" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/HierarchicalStateMachine2FlatStateMachine.qvtm.qvtcas"/>
-<mapEntry key="QVTp" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/HierarchicalStateMachine2FlatStateMachine.qvtp.qvtcas"/>
-<mapEntry key="QVTr" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/HierarchicalStateMachine2FlatStateMachine.qvtras"/>
-<mapEntry key="QVTs" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/HierarchicalStateMachine2FlatStateMachine.qvts.xmi"/>
-<mapEntry key="QVTu" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/HierarchicalStateMachine2FlatStateMachine.qvtu.qvtcas"/>
+<mapEntry key="Class" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/bin"/>
+<mapEntry key="Java" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src-gen"/>
+<mapEntry key="QVTc" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/temp/HierarchicalStateMachine2FlatStateMachine.qvtcas"/>
+<mapEntry key="QVTi" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/temp/HierarchicalStateMachine2FlatStateMachine.qvtias"/>
+<mapEntry key="QVTm" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/temp/HierarchicalStateMachine2FlatStateMachine.qvtm.qvtcas"/>
+<mapEntry key="QVTp" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/temp/HierarchicalStateMachine2FlatStateMachine.qvtp.qvtcas"/>
+<mapEntry key="QVTr" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/temp/HierarchicalStateMachine2FlatStateMachine.qvtras"/>
+<mapEntry key="QVTs" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/temp/HierarchicalStateMachine2FlatStateMachine.qvts.xmi"/>
+<mapEntry key="QVTu" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/temp/HierarchicalStateMachine2FlatStateMachine.qvtu.qvtcas"/>
</mapAttribute>
-<booleanAttribute key="interpreted" value="true"/>
+<booleanAttribute key="interpreted" value="false"/>
<stringAttribute key="mode" value="ENFORCE - CREATE"/>
<mapAttribute key="old-in"/>
<mapAttribute key="old-out"/>
<mapAttribute key="out">
-<mapEntry key="flat" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/SimpleFlatModel.xmi"/>
+<mapEntry key="flat" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/out/flat.xmi"/>
</mapAttribute>
+<stringAttribute key="project" value="org.eclipse.qvtd.examples.qvtrelation.hstm2fstm"/>
<stringAttribute key="tx" value="platform:/resource/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/HierarchicalStateMachine2FlatStateMachine.qvtr"/>
<booleanAttribute key="view" value="false"/>
</launchConfiguration>
diff --git a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/META-INF/MANIFEST.MF b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/META-INF/MANIFEST.MF index de3929192..e31f58706 100644 --- a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/META-INF/MANIFEST.MF +++ b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/META-INF/MANIFEST.MF @@ -6,3 +6,4 @@ Bundle-Version: 0.13.0.qualifier Bundle-Vendor: %providerName Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-1.8 +Require-Bundle: org.eclipse.qvtd.runtime diff --git a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/build.properties b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/build.properties index 87922d01d..a846cbfeb 100644 --- a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/build.properties +++ b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/build.properties @@ -1,5 +1,5 @@ source.. = src/,\ - src-gen/ + src-gen/ output.. = bin/ bin.includes = META-INF/,\ .,\ diff --git a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src-gen/PlaceHolder.txt b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src-gen/PlaceHolder.txt new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src-gen/PlaceHolder.txt diff --git a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/SimpleModel.xmi b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/in/hier.xmi index 231453ad7..231453ad7 100644 --- a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/SimpleModel.xmi +++ b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/in/hier.xmi diff --git a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/SimpleModel_expected.xmi b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/out/expected.xmi index bb433d6e9..bb433d6e9 100644 --- a/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/SimpleModel_expected.xmi +++ b/examples/org.eclipse.qvtd.examples.qvtrelation.hstm2fstm/src/org/eclipse/qvtd/examples/qvtrelation/hstm2fstm/out/expected.xmi diff --git a/examples/org.eclipse.qvtd.examples/buildZips.xml b/examples/org.eclipse.qvtd.examples/buildZips.xml index cc69bf769..d4fa9748d 100644 --- a/examples/org.eclipse.qvtd.examples/buildZips.xml +++ b/examples/org.eclipse.qvtd.examples/buildZips.xml @@ -4,6 +4,7 @@ </target> <patternset id="qvtc.excludes" excludes="bin/** qvtcbin/** src-gen/org/**"/> + <patternset id="qvtc2.excludes" excludes="bin/** qvtcbin/**"/> <patternset id="qvtr.excludes" excludes="bin/** qvtrbin/** src/** .settings/** META-INF/** .classpath build.properties about.html"/> <patternset id="qvtr2.excludes" excludes="bin/** qvtrbin/** src-gen/org/**"/> @@ -24,7 +25,7 @@ <patternset refid="qvtc.excludes"/> </zip> <zip destfile="zips/qvtc/uml2rdbms.zip" basedir="${examplesDir}org.eclipse.qvtd.examples.qvtcore.uml2rdbms"> - <patternset refid="qvtc.excludes"/> + <patternset refid="qvtc2.excludes"/> </zip> <mkdir dir="zips/qvtr"/> <zip destfile="zips/qvtr/empty.zip" basedir="${examplesDir}org.eclipse.qvtd.examples.qvtrelation.empty"> diff --git a/examples/org.eclipse.qvtd.examples/plugin.properties b/examples/org.eclipse.qvtd.examples/plugin.properties index 4035dd7e8..9ec97fb76 100644 --- a/examples/org.eclipse.qvtd.examples/plugin.properties +++ b/examples/org.eclipse.qvtd.examples/plugin.properties @@ -32,16 +32,16 @@ EmptyQVTc_name=Empty QVTc Project EmptyQVTc_description=Create an Empty QVT Core project QVTc_UML2RDBMS_name=QVTc UML2RDBMS Project -QVTc_UML2RDBMS_description=Create the UML2RDBMS QVT Core example project +QVTc_UML2RDBMS_description=Create a project containing a QVT core implementation of the classic (Simple) UML to Relational Database transformation. QVTr_HSTM2FSTM_name=QVTr HSTM2FSTM Project -QVTr_HSTM2FSTM_description=Create the HSTM2FSTM QVT Relation example project +QVTr_HSTM2FSTM_description=Create a project containing a QVT Relation implementation of the hierarchical to flat state machine transformation. EmptyQVTr_name=Empty QVTr Project EmptyQVTr_description=Create an Empty QVT Relation project ModelMorf_name=ModelMorf distribution Examples -ModelMorf_description=Create a project containing Examples from the ModelMorf distribution +ModelMorf_description=Create a project containing Examples from the ModelMorf distribution. RelToCore_name=Relations To Core Example -RelToCore_description=Create a project containing the Relations To Core Example +RelToCore_description=Create a project containing QVT Relation source code for the Relations To Core trasformation corresponding to the QVT specification. This transformation does not work yet. |