/*********************************************************************************************************************** | |
* Copyright (c) 2010 Attensity Europe GmbH. 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 | |
**********************************************************************************************************************/ | |
package org.eclipse.smila.processing.designer.model.record.impl; | |
import org.eclipse.emf.ecore.*; | |
import org.eclipse.emf.ecore.impl.EFactoryImpl; | |
import org.eclipse.emf.ecore.plugin.EcorePlugin; | |
import org.eclipse.smila.processing.designer.model.record.*; | |
/** | |
* <!-- begin-user-doc --> An implementation of the model <b>Factory</b>. <!-- end-user-doc --> | |
* | |
* @generated | |
*/ | |
public class RecordFactoryImpl extends EFactoryImpl implements RecordFactory { | |
/** | |
* Creates the default factory implementation. <!-- begin-user-doc --> <!-- end-user-doc --> | |
* | |
* @generated | |
*/ | |
public static RecordFactory init() { | |
try { | |
RecordFactory theRecordFactory = | |
(RecordFactory) EPackage.Registry.INSTANCE.getEFactory("http://www.eclipse.org/smila/record"); | |
if (theRecordFactory != null) { | |
return theRecordFactory; | |
} | |
} catch (Exception exception) { | |
EcorePlugin.INSTANCE.log(exception); | |
} | |
return new RecordFactoryImpl(); | |
} | |
/** | |
* Creates an instance of the factory. <!-- begin-user-doc --> <!-- end-user-doc --> | |
* | |
* @generated | |
*/ | |
public RecordFactoryImpl() { | |
super(); | |
} | |
/** | |
* <!-- begin-user-doc --> <!-- end-user-doc --> | |
* | |
* @generated | |
*/ | |
@Override | |
public EObject create(EClass eClass) { | |
switch (eClass.getClassifierID()) { | |
case RecordPackage.RECORD_MAP: | |
return createRecordMap(); | |
case RecordPackage.RECORD_SEQ: | |
return createRecordSeq(); | |
case RecordPackage.RECORD_VAL: | |
return createRecordVal(); | |
default: | |
throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); | |
} | |
} | |
/** | |
* <!-- begin-user-doc --> <!-- end-user-doc --> | |
* | |
* @generated | |
*/ | |
@Override | |
public RecordMap createRecordMap() { | |
RecordMapImpl recordMap = new RecordMapImpl(); | |
return recordMap; | |
} | |
/** | |
* <!-- begin-user-doc --> <!-- end-user-doc --> | |
* | |
* @generated | |
*/ | |
@Override | |
public RecordSeq createRecordSeq() { | |
RecordSeqImpl recordSeq = new RecordSeqImpl(); | |
return recordSeq; | |
} | |
/** | |
* <!-- begin-user-doc --> <!-- end-user-doc --> | |
* | |
* @generated | |
*/ | |
@Override | |
public RecordVal createRecordVal() { | |
RecordValImpl recordVal = new RecordValImpl(); | |
return recordVal; | |
} | |
/** | |
* <!-- begin-user-doc --> <!-- end-user-doc --> | |
* | |
* @generated | |
*/ | |
@Override | |
public RecordPackage getRecordPackage() { | |
return (RecordPackage) getEPackage(); | |
} | |
/** | |
* <!-- begin-user-doc --> <!-- end-user-doc --> | |
* | |
* @deprecated | |
* @generated | |
*/ | |
@Deprecated | |
public static RecordPackage getPackage() { | |
return RecordPackage.eINSTANCE; | |
} | |
} // RecordFactoryImpl |