/** * Copyright (c) 2015-2016 Inria * 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: * - Fawaz Paraiso <fawaz.paraiso@inria.fr> * - Philippe Merle <philippe.merle@inria.fr> */ package org.occiware.clouddesigner.occi.cloud.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.occiware.clouddesigner.occi.Entity; import org.occiware.clouddesigner.occi.Resource; import org.occiware.clouddesigner.occi.cloud.*; import org.occiware.clouddesigner.occi.infrastructure.Compute; /** * <!-- 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.occiware.clouddesigner.occi.cloud.CloudPackage * @generated */ public class CloudAdapterFactory extends AdapterFactoryImpl { /** * The cached model package. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ protected static CloudPackage modelPackage; /** * Creates an instance of the adapter factory. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public CloudAdapterFactory() { if (modelPackage == null) { modelPackage = CloudPackage.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 CloudSwitch<Adapter> modelSwitch = new CloudSwitch<Adapter>() { @Override public Adapter caseMachine(Machine object) { return createMachineAdapter(); } @Override public Adapter caseMachine_CloudSigma(Machine_CloudSigma object) { return createMachine_CloudSigmaAdapter(); } @Override public Adapter caseMachine_Amazon_EC2(Machine_Amazon_EC2 object) { return createMachine_Amazon_EC2Adapter(); } @Override public Adapter caseMachine_Gogrid(Machine_Gogrid object) { return createMachine_GogridAdapter(); } @Override public Adapter caseMachine_Hp_Helion(Machine_Hp_Helion object) { return createMachine_Hp_HelionAdapter(); } @Override public Adapter caseMachine_GCE(Machine_GCE object) { return createMachine_GCEAdapter(); } @Override public Adapter caseMachine_RackSpace(Machine_RackSpace object) { return createMachine_RackSpaceAdapter(); } @Override public Adapter caseMachine_ProfitBricks(Machine_ProfitBricks object) { return createMachine_ProfitBricksAdapter(); } @Override public Adapter caseMachine_OpenStack(Machine_OpenStack object) { return createMachine_OpenStackAdapter(); } @Override public Adapter caseMachine_SoftLayer(Machine_SoftLayer object) { return createMachine_SoftLayerAdapter(); } @Override public Adapter caseEntity(Entity object) { return createEntityAdapter(); } @Override public Adapter caseResource(Resource object) { return createResourceAdapter(); } @Override public Adapter caseCompute(Compute object) { return createComputeAdapter(); } @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.occiware.clouddesigner.occi.cloud.Machine <em>Machine</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.occiware.clouddesigner.occi.cloud.Machine * @generated */ public Adapter createMachineAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.cloud.Machine_CloudSigma <em>Machine Cloud Sigma</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.occiware.clouddesigner.occi.cloud.Machine_CloudSigma * @generated */ public Adapter createMachine_CloudSigmaAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.cloud.Machine_Amazon_EC2 <em>Machine Amazon EC2</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.occiware.clouddesigner.occi.cloud.Machine_Amazon_EC2 * @generated */ public Adapter createMachine_Amazon_EC2Adapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.cloud.Machine_Gogrid <em>Machine Gogrid</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.occiware.clouddesigner.occi.cloud.Machine_Gogrid * @generated */ public Adapter createMachine_GogridAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.cloud.Machine_Hp_Helion <em>Machine Hp Helion</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.occiware.clouddesigner.occi.cloud.Machine_Hp_Helion * @generated */ public Adapter createMachine_Hp_HelionAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.cloud.Machine_GCE <em>Machine GCE</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.occiware.clouddesigner.occi.cloud.Machine_GCE * @generated */ public Adapter createMachine_GCEAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.cloud.Machine_RackSpace <em>Machine Rack Space</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.occiware.clouddesigner.occi.cloud.Machine_RackSpace * @generated */ public Adapter createMachine_RackSpaceAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.cloud.Machine_ProfitBricks <em>Machine Profit Bricks</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.occiware.clouddesigner.occi.cloud.Machine_ProfitBricks * @generated */ public Adapter createMachine_ProfitBricksAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.cloud.Machine_OpenStack <em>Machine Open Stack</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.occiware.clouddesigner.occi.cloud.Machine_OpenStack * @generated */ public Adapter createMachine_OpenStackAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.cloud.Machine_SoftLayer <em>Machine Soft Layer</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.occiware.clouddesigner.occi.cloud.Machine_SoftLayer * @generated */ public Adapter createMachine_SoftLayerAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.Entity <em>Entity</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.occiware.clouddesigner.occi.Entity * @generated */ public Adapter createEntityAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.Resource <em>Resource</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.occiware.clouddesigner.occi.Resource * @generated */ public Adapter createResourceAdapter() { return null; } /** * Creates a new adapter for an object of class '{@link org.occiware.clouddesigner.occi.infrastructure.Compute <em>Compute</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.occiware.clouddesigner.occi.infrastructure.Compute * @generated */ public Adapter createComputeAdapter() { 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; } } //CloudAdapterFactory