Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/org.eclipse.emf.cdo.examples.installer/examples/org.gastro.inventory/src/org/gastro/inventory/impl/InventoryPackageImpl.java')
-rw-r--r--plugins/org.eclipse.emf.cdo.examples.installer/examples/org.gastro.inventory/src/org/gastro/inventory/impl/InventoryPackageImpl.java999
1 files changed, 999 insertions, 0 deletions
diff --git a/plugins/org.eclipse.emf.cdo.examples.installer/examples/org.gastro.inventory/src/org/gastro/inventory/impl/InventoryPackageImpl.java b/plugins/org.eclipse.emf.cdo.examples.installer/examples/org.gastro.inventory/src/org/gastro/inventory/impl/InventoryPackageImpl.java
new file mode 100644
index 0000000000..e7486d6296
--- /dev/null
+++ b/plugins/org.eclipse.emf.cdo.examples.installer/examples/org.gastro.inventory/src/org/gastro/inventory/impl/InventoryPackageImpl.java
@@ -0,0 +1,999 @@
+/*
+ * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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:
+ * Eike Stepper - initial API and implementation
+ *
+ * Initial Publication:
+ * Eclipse Magazin - http://www.eclipse-magazin.de
+ */
+package org.gastro.inventory.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.gastro.inventory.Department;
+import org.gastro.inventory.Employee;
+import org.gastro.inventory.Ingredient;
+import org.gastro.inventory.InventoryFactory;
+import org.gastro.inventory.InventoryPackage;
+import org.gastro.inventory.MenuCard;
+import org.gastro.inventory.Offering;
+import org.gastro.inventory.Product;
+import org.gastro.inventory.Recipe;
+import org.gastro.inventory.Restaurant;
+import org.gastro.inventory.Section;
+import org.gastro.inventory.Station;
+import org.gastro.inventory.Stock;
+import org.gastro.inventory.StockProduct;
+import org.gastro.inventory.Table;
+
+/**
+ * <!-- begin-user-doc --> An implementation of the model <b>Package</b>. <!-- end-user-doc -->
+ *
+ * @generated
+ */
+public class InventoryPackageImpl extends EPackageImpl implements InventoryPackage
+{
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass stockEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass productEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass stockProductEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass recipeEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass ingredientEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass menuCardEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass restaurantEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass departmentEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass offeringEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass tableEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass employeeEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass stationEClass = null;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ private EClass sectionEClass = 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.gastro.inventory.InventoryPackage#eNS_URI
+ * @see #init()
+ * @generated
+ */
+ private InventoryPackageImpl()
+ {
+ super(eNS_URI, InventoryFactory.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 InventoryPackage#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 InventoryPackage init()
+ {
+ if (isInited)
+ return (InventoryPackage)EPackage.Registry.INSTANCE.getEPackage(InventoryPackage.eNS_URI);
+
+ // Obtain or create and register package
+ InventoryPackageImpl theInventoryPackage = (InventoryPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof InventoryPackageImpl ? EPackage.Registry.INSTANCE
+ .get(eNS_URI) : new InventoryPackageImpl());
+
+ isInited = true;
+
+ // Create package meta-data objects
+ theInventoryPackage.createPackageContents();
+
+ // Initialize created meta-data
+ theInventoryPackage.initializePackageContents();
+
+ // Mark meta-data to indicate it can't be changed
+ theInventoryPackage.freeze();
+
+ // Update the registry and return the package
+ EPackage.Registry.INSTANCE.put(InventoryPackage.eNS_URI, theInventoryPackage);
+ return theInventoryPackage;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getStock()
+ {
+ return stockEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getStock_Products()
+ {
+ return (EReference)stockEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getStock_Name()
+ {
+ return (EAttribute)stockEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getStock_Department()
+ {
+ return (EReference)stockEClass.getEStructuralFeatures().get(2);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getProduct()
+ {
+ return productEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getProduct_Name()
+ {
+ return (EAttribute)productEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getStockProduct()
+ {
+ return stockProductEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getStockProduct_Stock()
+ {
+ return (EReference)stockProductEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getStockProduct_Cost()
+ {
+ return (EAttribute)stockProductEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getStockProduct_Available()
+ {
+ return (EAttribute)stockProductEClass.getEStructuralFeatures().get(2);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getStockProduct_OrderLimit()
+ {
+ return (EAttribute)stockProductEClass.getEStructuralFeatures().get(3);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getRecipe()
+ {
+ return recipeEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getRecipe_Ingredients()
+ {
+ return (EReference)recipeEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getRecipe_Department()
+ {
+ return (EReference)recipeEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getRecipe_Cost()
+ {
+ return (EAttribute)recipeEClass.getEStructuralFeatures().get(2);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getIngredient()
+ {
+ return ingredientEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getIngredient_Recipe()
+ {
+ return (EReference)ingredientEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getIngredient_Product()
+ {
+ return (EReference)ingredientEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getIngredient_Quantity()
+ {
+ return (EAttribute)ingredientEClass.getEStructuralFeatures().get(2);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getMenuCard()
+ {
+ return menuCardEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getMenuCard_Title()
+ {
+ return (EAttribute)menuCardEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getMenuCard_Restaurant()
+ {
+ return (EReference)menuCardEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getMenuCard_Sections()
+ {
+ return (EReference)menuCardEClass.getEStructuralFeatures().get(2);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getRestaurant()
+ {
+ return restaurantEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getRestaurant_Name()
+ {
+ return (EAttribute)restaurantEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getRestaurant_Departments()
+ {
+ return (EReference)restaurantEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getRestaurant_MenuCards()
+ {
+ return (EReference)restaurantEClass.getEStructuralFeatures().get(2);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getRestaurant_Tables()
+ {
+ return (EReference)restaurantEClass.getEStructuralFeatures().get(3);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getRestaurant_Stations()
+ {
+ return (EReference)restaurantEClass.getEStructuralFeatures().get(4);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getDepartment()
+ {
+ return departmentEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getDepartment_Recipes()
+ {
+ return (EReference)departmentEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getDepartment_Restaurant()
+ {
+ return (EReference)departmentEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getDepartment_Employees()
+ {
+ return (EReference)departmentEClass.getEStructuralFeatures().get(2);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getDepartment_Stocks()
+ {
+ return (EReference)departmentEClass.getEStructuralFeatures().get(3);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getOffering()
+ {
+ return offeringEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getOffering_Product()
+ {
+ return (EReference)offeringEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getOffering_Name()
+ {
+ return (EAttribute)offeringEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getOffering_Description()
+ {
+ return (EAttribute)offeringEClass.getEStructuralFeatures().get(2);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getOffering_Price()
+ {
+ return (EAttribute)offeringEClass.getEStructuralFeatures().get(3);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getOffering_Section()
+ {
+ return (EReference)offeringEClass.getEStructuralFeatures().get(4);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getTable()
+ {
+ return tableEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getTable_Seats()
+ {
+ return (EAttribute)tableEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getTable_Restaurant()
+ {
+ return (EReference)tableEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getEmployee()
+ {
+ return employeeEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getEmployee_Department()
+ {
+ return (EReference)employeeEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getEmployee_Name()
+ {
+ return (EAttribute)employeeEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getStation()
+ {
+ return stationEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getStation_StationID()
+ {
+ return (EAttribute)stationEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EClass getSection()
+ {
+ return sectionEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getSection_MenuCard()
+ {
+ return (EReference)sectionEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EReference getSection_Offerings()
+ {
+ return (EReference)sectionEClass.getEStructuralFeatures().get(1);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getSection_Title()
+ {
+ return (EAttribute)sectionEClass.getEStructuralFeatures().get(2);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EAttribute getSection_Text()
+ {
+ return (EAttribute)sectionEClass.getEStructuralFeatures().get(3);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public InventoryFactory getInventoryFactory()
+ {
+ return (InventoryFactory)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
+ stockEClass = createEClass(STOCK);
+ createEReference(stockEClass, STOCK__PRODUCTS);
+ createEAttribute(stockEClass, STOCK__NAME);
+ createEReference(stockEClass, STOCK__DEPARTMENT);
+
+ productEClass = createEClass(PRODUCT);
+ createEAttribute(productEClass, PRODUCT__NAME);
+
+ stockProductEClass = createEClass(STOCK_PRODUCT);
+ createEReference(stockProductEClass, STOCK_PRODUCT__STOCK);
+ createEAttribute(stockProductEClass, STOCK_PRODUCT__COST);
+ createEAttribute(stockProductEClass, STOCK_PRODUCT__AVAILABLE);
+ createEAttribute(stockProductEClass, STOCK_PRODUCT__ORDER_LIMIT);
+
+ recipeEClass = createEClass(RECIPE);
+ createEReference(recipeEClass, RECIPE__INGREDIENTS);
+ createEReference(recipeEClass, RECIPE__DEPARTMENT);
+ createEAttribute(recipeEClass, RECIPE__COST);
+
+ ingredientEClass = createEClass(INGREDIENT);
+ createEReference(ingredientEClass, INGREDIENT__RECIPE);
+ createEReference(ingredientEClass, INGREDIENT__PRODUCT);
+ createEAttribute(ingredientEClass, INGREDIENT__QUANTITY);
+
+ menuCardEClass = createEClass(MENU_CARD);
+ createEAttribute(menuCardEClass, MENU_CARD__TITLE);
+ createEReference(menuCardEClass, MENU_CARD__RESTAURANT);
+ createEReference(menuCardEClass, MENU_CARD__SECTIONS);
+
+ restaurantEClass = createEClass(RESTAURANT);
+ createEAttribute(restaurantEClass, RESTAURANT__NAME);
+ createEReference(restaurantEClass, RESTAURANT__DEPARTMENTS);
+ createEReference(restaurantEClass, RESTAURANT__MENU_CARDS);
+ createEReference(restaurantEClass, RESTAURANT__TABLES);
+ createEReference(restaurantEClass, RESTAURANT__STATIONS);
+
+ departmentEClass = createEClass(DEPARTMENT);
+ createEReference(departmentEClass, DEPARTMENT__RECIPES);
+ createEReference(departmentEClass, DEPARTMENT__RESTAURANT);
+ createEReference(departmentEClass, DEPARTMENT__EMPLOYEES);
+ createEReference(departmentEClass, DEPARTMENT__STOCKS);
+
+ offeringEClass = createEClass(OFFERING);
+ createEReference(offeringEClass, OFFERING__PRODUCT);
+ createEAttribute(offeringEClass, OFFERING__NAME);
+ createEAttribute(offeringEClass, OFFERING__DESCRIPTION);
+ createEAttribute(offeringEClass, OFFERING__PRICE);
+ createEReference(offeringEClass, OFFERING__SECTION);
+
+ tableEClass = createEClass(TABLE);
+ createEAttribute(tableEClass, TABLE__SEATS);
+ createEReference(tableEClass, TABLE__RESTAURANT);
+
+ employeeEClass = createEClass(EMPLOYEE);
+ createEReference(employeeEClass, EMPLOYEE__DEPARTMENT);
+ createEAttribute(employeeEClass, EMPLOYEE__NAME);
+
+ stationEClass = createEClass(STATION);
+ createEAttribute(stationEClass, STATION__STATION_ID);
+
+ sectionEClass = createEClass(SECTION);
+ createEReference(sectionEClass, SECTION__MENU_CARD);
+ createEReference(sectionEClass, SECTION__OFFERINGS);
+ createEAttribute(sectionEClass, SECTION__TITLE);
+ createEAttribute(sectionEClass, SECTION__TEXT);
+ }
+
+ /**
+ * <!-- 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
+ stockProductEClass.getESuperTypes().add(this.getProduct());
+ recipeEClass.getESuperTypes().add(this.getProduct());
+ departmentEClass.getESuperTypes().add(this.getStation());
+ tableEClass.getESuperTypes().add(this.getStation());
+
+ // Initialize classes and features; add operations and parameters
+ initEClass(stockEClass, Stock.class, "Stock", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
+ initEReference(getStock_Products(), this.getStockProduct(), this.getStockProduct_Stock(), "products", null, 0, -1,
+ Stock.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getStock_Name(), ecorePackage.getEString(), "name", null, 0, 1, Stock.class, !IS_TRANSIENT,
+ !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getStock_Department(), this.getDepartment(), this.getDepartment_Stocks(), "department", null, 1, 1,
+ Stock.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+
+ initEClass(productEClass, Product.class, "Product", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
+ initEAttribute(getProduct_Name(), ecorePackage.getEString(), "name", null, 0, 1, Product.class, !IS_TRANSIENT,
+ !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+
+ addEOperation(productEClass, ecorePackage.getEFloat(), "getCost", 0, 1, IS_UNIQUE, IS_ORDERED);
+
+ initEClass(stockProductEClass, StockProduct.class, "StockProduct", !IS_ABSTRACT, !IS_INTERFACE,
+ IS_GENERATED_INSTANCE_CLASS);
+ initEReference(getStockProduct_Stock(), this.getStock(), this.getStock_Products(), "stock", null, 1, 1,
+ StockProduct.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getStockProduct_Cost(), ecorePackage.getEFloat(), "cost", null, 0, 1, StockProduct.class,
+ !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getStockProduct_Available(), ecorePackage.getEInt(), "available", null, 0, 1, StockProduct.class,
+ !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getStockProduct_OrderLimit(), ecorePackage.getEInt(), "orderLimit", null, 0, 1, StockProduct.class,
+ !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+
+ initEClass(recipeEClass, Recipe.class, "Recipe", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
+ initEReference(getRecipe_Ingredients(), this.getIngredient(), this.getIngredient_Recipe(), "ingredients", null, 0,
+ -1, Recipe.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getRecipe_Department(), this.getDepartment(), this.getDepartment_Recipes(), "department", null, 0,
+ 1, Recipe.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getRecipe_Cost(), ecorePackage.getEFloat(), "cost", null, 0, 1, Recipe.class, IS_TRANSIENT,
+ IS_VOLATILE, !IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, IS_DERIVED, IS_ORDERED);
+
+ initEClass(ingredientEClass, Ingredient.class, "Ingredient", !IS_ABSTRACT, !IS_INTERFACE,
+ IS_GENERATED_INSTANCE_CLASS);
+ initEReference(getIngredient_Recipe(), this.getRecipe(), this.getRecipe_Ingredients(), "recipe", null, 1, 1,
+ Ingredient.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getIngredient_Product(), this.getProduct(), null, "product", null, 1, 1, Ingredient.class,
+ !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
+ !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getIngredient_Quantity(), ecorePackage.getEInt(), "quantity", null, 0, 1, Ingredient.class,
+ !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+
+ initEClass(menuCardEClass, MenuCard.class, "MenuCard", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
+ initEAttribute(getMenuCard_Title(), ecorePackage.getEString(), "title", null, 0, 1, MenuCard.class, !IS_TRANSIENT,
+ !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getMenuCard_Restaurant(), this.getRestaurant(), this.getRestaurant_MenuCards(), "restaurant", null,
+ 1, 1, MenuCard.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getMenuCard_Sections(), this.getSection(), this.getSection_MenuCard(), "sections", null, 1, -1,
+ MenuCard.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+
+ initEClass(restaurantEClass, Restaurant.class, "Restaurant", !IS_ABSTRACT, !IS_INTERFACE,
+ IS_GENERATED_INSTANCE_CLASS);
+ initEAttribute(getRestaurant_Name(), ecorePackage.getEString(), "name", null, 0, 1, Restaurant.class,
+ !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getRestaurant_Departments(), this.getDepartment(), this.getDepartment_Restaurant(), "departments",
+ null, 0, -1, Restaurant.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getRestaurant_MenuCards(), this.getMenuCard(), this.getMenuCard_Restaurant(), "menuCards", null, 0,
+ -1, Restaurant.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getRestaurant_Tables(), this.getTable(), this.getTable_Restaurant(), "tables", null, 0, -1,
+ Restaurant.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getRestaurant_Stations(), this.getStation(), null, "stations", null, 0, -1, Restaurant.class,
+ IS_TRANSIENT, IS_VOLATILE, !IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
+ IS_DERIVED, IS_ORDERED);
+
+ initEClass(departmentEClass, Department.class, "Department", !IS_ABSTRACT, !IS_INTERFACE,
+ IS_GENERATED_INSTANCE_CLASS);
+ initEReference(getDepartment_Recipes(), this.getRecipe(), this.getRecipe_Department(), "recipes", null, 0, -1,
+ Department.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getDepartment_Restaurant(), this.getRestaurant(), this.getRestaurant_Departments(), "restaurant",
+ null, 1, 1, Department.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getDepartment_Employees(), this.getEmployee(), this.getEmployee_Department(), "employees", null, 0,
+ -1, Department.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getDepartment_Stocks(), this.getStock(), this.getStock_Department(), "stocks", null, 1, -1,
+ Department.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+
+ initEClass(offeringEClass, Offering.class, "Offering", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
+ initEReference(getOffering_Product(), this.getProduct(), null, "product", null, 1, 1, Offering.class,
+ !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
+ !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getOffering_Name(), ecorePackage.getEString(), "name", null, 0, 1, Offering.class, !IS_TRANSIENT,
+ !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getOffering_Description(), ecorePackage.getEString(), "description", null, 0, 1, Offering.class,
+ !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getOffering_Price(), ecorePackage.getEFloat(), "price", null, 0, 1, Offering.class, !IS_TRANSIENT,
+ !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getOffering_Section(), this.getSection(), this.getSection_Offerings(), "section", null, 1, 1,
+ Offering.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);
+ initEAttribute(getTable_Seats(), ecorePackage.getEInt(), "seats", null, 0, 1, Table.class, !IS_TRANSIENT,
+ !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getTable_Restaurant(), this.getRestaurant(), this.getRestaurant_Tables(), "restaurant", null, 1, 1,
+ Table.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+
+ initEClass(employeeEClass, Employee.class, "Employee", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
+ initEReference(getEmployee_Department(), this.getDepartment(), this.getDepartment_Employees(), "department", null,
+ 0, 1, Employee.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getEmployee_Name(), ecorePackage.getEString(), "name", null, 0, 1, Employee.class, !IS_TRANSIENT,
+ !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+
+ initEClass(stationEClass, Station.class, "Station", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
+ initEAttribute(getStation_StationID(), ecorePackage.getEString(), "stationID", null, 0, 1, Station.class,
+ !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+
+ initEClass(sectionEClass, Section.class, "Section", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
+ initEReference(getSection_MenuCard(), this.getMenuCard(), this.getMenuCard_Sections(), "menuCard", null, 1, 1,
+ Section.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getSection_Offerings(), this.getOffering(), this.getOffering_Section(), "offerings", null, 1, -1,
+ Section.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getSection_Title(), ecorePackage.getEString(), "title", null, 0, 1, Section.class, !IS_TRANSIENT,
+ !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getSection_Text(), ecorePackage.getEString(), "text", null, 0, 1, Section.class, !IS_TRANSIENT,
+ !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+
+ // Create resource
+ createResource(eNS_URI);
+ }
+
+} // InventoryPackageImpl

Back to the top