| /** |
| * Copyright (c) 2020 CEA LIST, Committer Name, and others. |
| * All rights reserved. This program and the accompanying materials |
| * are made available under the terms of the Eclipse Public License 2.0 |
| * which accompanies this distribution, and is available at |
| * https://www.eclipse.org/legal/epl-2.0/ |
| * |
| * SPDX-License-Identifier: EPL-2.0 |
| * |
| * Contributors: |
| * CEA LIST - Initial API and implementation |
| * Patrick Tessier (CEA LIST) patrick.tessier@cea.fr |
| * Gabriel Pedroza (CEA LIST) gabriel.pedroza@cea.fr |
| * |
| */ |
| package org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.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.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.Consent; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.Contract; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.Controller; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.Data; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.DataSubject; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.LegalObligation; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.LegitimateInterest; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.Pdp4engCommonGDPRFactory; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.Pdp4engCommonGDPRPackage; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.PersonalData; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.Processor; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.PublicInterest; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.Purpose; |
| import org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.VitalInterest; |
| |
| /** |
| * <!-- begin-user-doc --> |
| * An implementation of the model <b>Factory</b>. |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| public class Pdp4engCommonGDPRFactoryImpl extends EFactoryImpl implements Pdp4engCommonGDPRFactory { |
| /** |
| * Creates the default factory implementation. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| public static Pdp4engCommonGDPRFactory init() { |
| try { |
| Pdp4engCommonGDPRFactory thePdp4engCommonGDPRFactory = (Pdp4engCommonGDPRFactory) EPackage.Registry.INSTANCE.getEFactory(Pdp4engCommonGDPRPackage.eNS_URI); |
| if (thePdp4engCommonGDPRFactory != null) { |
| return thePdp4engCommonGDPRFactory; |
| } |
| } catch (Exception exception) { |
| EcorePlugin.INSTANCE.log(exception); |
| } |
| return new Pdp4engCommonGDPRFactoryImpl(); |
| } |
| |
| /** |
| * Creates an instance of the factory. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| public Pdp4engCommonGDPRFactoryImpl() { |
| super(); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public EObject create(EClass eClass) { |
| switch (eClass.getClassifierID()) { |
| case Pdp4engCommonGDPRPackage.PROCESS: |
| return createProcess(); |
| case Pdp4engCommonGDPRPackage.PERSONAL_DATA: |
| return createPersonalData(); |
| case Pdp4engCommonGDPRPackage.DATA: |
| return createData(); |
| case Pdp4engCommonGDPRPackage.DATA_SUBJECT: |
| return createDataSubject(); |
| case Pdp4engCommonGDPRPackage.CONSENT: |
| return createConsent(); |
| case Pdp4engCommonGDPRPackage.PURPOSE: |
| return createPurpose(); |
| case Pdp4engCommonGDPRPackage.CONTRACT: |
| return createContract(); |
| case Pdp4engCommonGDPRPackage.CONTROLLER: |
| return createController(); |
| case Pdp4engCommonGDPRPackage.PROCESSOR: |
| return createProcessor(); |
| case Pdp4engCommonGDPRPackage.PUBLIC_INTEREST: |
| return createPublicInterest(); |
| case Pdp4engCommonGDPRPackage.LEGITIMATE_INTEREST: |
| return createLegitimateInterest(); |
| case Pdp4engCommonGDPRPackage.LEGAL_OBLIGATION: |
| return createLegalObligation(); |
| case Pdp4engCommonGDPRPackage.VITAL_INTEREST: |
| return createVitalInterest(); |
| default: |
| throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); |
| } |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public org.eclipse.papyrus.pdp4eng.common.profile.pdp4engCommonGDPR.Process createProcess() { |
| ProcessImpl process = new ProcessImpl(); |
| return process; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public PersonalData createPersonalData() { |
| PersonalDataImpl personalData = new PersonalDataImpl(); |
| return personalData; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Data createData() { |
| DataImpl data = new DataImpl(); |
| return data; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public DataSubject createDataSubject() { |
| DataSubjectImpl dataSubject = new DataSubjectImpl(); |
| return dataSubject; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Consent createConsent() { |
| ConsentImpl consent = new ConsentImpl(); |
| return consent; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Purpose createPurpose() { |
| PurposeImpl purpose = new PurposeImpl(); |
| return purpose; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Contract createContract() { |
| ContractImpl contract = new ContractImpl(); |
| return contract; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Controller createController() { |
| ControllerImpl controller = new ControllerImpl(); |
| return controller; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Processor createProcessor() { |
| ProcessorImpl processor = new ProcessorImpl(); |
| return processor; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public PublicInterest createPublicInterest() { |
| PublicInterestImpl publicInterest = new PublicInterestImpl(); |
| return publicInterest; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public LegitimateInterest createLegitimateInterest() { |
| LegitimateInterestImpl legitimateInterest = new LegitimateInterestImpl(); |
| return legitimateInterest; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public LegalObligation createLegalObligation() { |
| LegalObligationImpl legalObligation = new LegalObligationImpl(); |
| return legalObligation; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public VitalInterest createVitalInterest() { |
| VitalInterestImpl vitalInterest = new VitalInterestImpl(); |
| return vitalInterest; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Pdp4engCommonGDPRPackage getPdp4engCommonGDPRPackage() { |
| return (Pdp4engCommonGDPRPackage) getEPackage(); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * |
| * @deprecated |
| * @generated |
| */ |
| @Deprecated |
| public static Pdp4engCommonGDPRPackage getPackage() { |
| return Pdp4engCommonGDPRPackage.eINSTANCE; |
| } |
| |
| } // Pdp4engCommonGDPRFactoryImpl |