/*******************************************************************************
 * Copyright (c) 2015, 2016 CNRS, IRIT, IRT AESE (IRT Saint Exupéry).
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the LGPL 3.0
 * which accompanies this distribution, and is available at
 * https://www.gnu.org/licenses/lgpl-3.0-standalone.html
 *
 * Contributors:
 *     Faiez Zalila - initial API and implementation and/or initial documentation
 *******************************************************************************/
/**
 */
package com.irtsaintexupery.fiacre.instance.fiacreinstance.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 com.irtsaintexupery.fiacre.instance.fiacreinstance.*;

/**
 * <!-- begin-user-doc -->
 * An implementation of the model <b>Factory</b>.
 * <!-- end-user-doc -->
 * @generated
 */
public class FiacreinstanceFactoryImpl extends EFactoryImpl implements FiacreinstanceFactory {
	/**
	 * Creates the default factory implementation.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static FiacreinstanceFactory init() {
		try {
			FiacreinstanceFactory theFiacreinstanceFactory = (FiacreinstanceFactory)EPackage.Registry.INSTANCE.getEFactory(FiacreinstancePackage.eNS_URI);
			if (theFiacreinstanceFactory != null) {
				return theFiacreinstanceFactory;
			}
		}
		catch (Exception exception) {
			EcorePlugin.INSTANCE.log(exception);
		}
		return new FiacreinstanceFactoryImpl();
	}

	/**
	 * Creates an instance of the factory.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public FiacreinstanceFactoryImpl() {
		super();
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	@Override
	public EObject create(EClass eClass) {
		switch (eClass.getClassifierID()) {
			case FiacreinstancePackage.INSTANCE_MODEL: return createInstanceModel();
			case FiacreinstancePackage.EXECUTED_STATEMENT_BLOCK: return createExecutedStatementBlock();
			case FiacreinstancePackage.EXECUTABLE_STATEMENT_BLOCK: return createExecutableStatementBlock();
			case FiacreinstancePackage.FIREABLE_STATEMENT_BLOCK: return createFireableStatementBlock();
			case FiacreinstancePackage.ENABLED_STATEMENT_BLOCK: return createEnabledStatementBlock();
			case FiacreinstancePackage.COMPOSITION_INSTANCE: return createCompositionInstance();
			case FiacreinstancePackage.COMPONENT_DECLARATION_INSTANCE: return createComponentDeclarationInstance();
			case FiacreinstancePackage.PROCESS_DECLARATION_INSTANCE: return createProcessDeclarationInstance();
			case FiacreinstancePackage.INSTANCE_EXECUTED_STATEMENT_BLOCK: return createInstanceExecutedStatementBlock();
			case FiacreinstancePackage.INSTANCE_FIREABLE_STATEMENT_BLOCK: return createInstanceFireableStatementBlock();
			case FiacreinstancePackage.INSTANCE_ENABLED_STATEMENT_BLOCK: return createInstanceEnabledStatementBlock();
			case FiacreinstancePackage.VARIABLE_DECLARATION_INSTANCE: return createVariableDeclarationInstance();
			default:
				throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
		}
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public InstanceModel createInstanceModel() {
		InstanceModelImpl instanceModel = new InstanceModelImpl();
		return instanceModel;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ExecutedStatementBlock createExecutedStatementBlock() {
		ExecutedStatementBlockImpl executedStatementBlock = new ExecutedStatementBlockImpl();
		return executedStatementBlock;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ExecutableStatementBlock createExecutableStatementBlock() {
		ExecutableStatementBlockImpl executableStatementBlock = new ExecutableStatementBlockImpl();
		return executableStatementBlock;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public FireableStatementBlock createFireableStatementBlock() {
		FireableStatementBlockImpl fireableStatementBlock = new FireableStatementBlockImpl();
		return fireableStatementBlock;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public EnabledStatementBlock createEnabledStatementBlock() {
		EnabledStatementBlockImpl enabledStatementBlock = new EnabledStatementBlockImpl();
		return enabledStatementBlock;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public CompositionInstance createCompositionInstance() {
		CompositionInstanceImpl compositionInstance = new CompositionInstanceImpl();
		return compositionInstance;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ComponentDeclarationInstance createComponentDeclarationInstance() {
		ComponentDeclarationInstanceImpl componentDeclarationInstance = new ComponentDeclarationInstanceImpl();
		return componentDeclarationInstance;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ProcessDeclarationInstance createProcessDeclarationInstance() {
		ProcessDeclarationInstanceImpl processDeclarationInstance = new ProcessDeclarationInstanceImpl();
		return processDeclarationInstance;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public InstanceExecutedStatementBlock createInstanceExecutedStatementBlock() {
		InstanceExecutedStatementBlockImpl instanceExecutedStatementBlock = new InstanceExecutedStatementBlockImpl();
		return instanceExecutedStatementBlock;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public InstanceFireableStatementBlock createInstanceFireableStatementBlock() {
		InstanceFireableStatementBlockImpl instanceFireableStatementBlock = new InstanceFireableStatementBlockImpl();
		return instanceFireableStatementBlock;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public InstanceEnabledStatementBlock createInstanceEnabledStatementBlock() {
		InstanceEnabledStatementBlockImpl instanceEnabledStatementBlock = new InstanceEnabledStatementBlockImpl();
		return instanceEnabledStatementBlock;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public VariableDeclarationInstance createVariableDeclarationInstance() {
		VariableDeclarationInstanceImpl variableDeclarationInstance = new VariableDeclarationInstanceImpl();
		return variableDeclarationInstance;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public FiacreinstancePackage getFiacreinstancePackage() {
		return (FiacreinstancePackage)getEPackage();
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @deprecated
	 * @generated
	 */
	@Deprecated
	public static FiacreinstancePackage getPackage() {
		return FiacreinstancePackage.eINSTANCE;
	}

} //FiacreinstanceFactoryImpl
