blob: ac782945d447e1d63a26aaa8fd958c8d57aaf5c7 [file] [log] [blame]
/*
* Copyright (c) 2014 CEA 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:
* Kenn Hussey (CEA) - initial API and implementation
*
*/
package org.eclipse.uml2.uml.profile.standard.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.eclipse.uml2.uml.profile.standard.Auxiliary;
import org.eclipse.uml2.uml.profile.standard.BuildComponent;
import org.eclipse.uml2.uml.profile.standard.Call;
import org.eclipse.uml2.uml.profile.standard.Create;
import org.eclipse.uml2.uml.profile.standard.Derive;
import org.eclipse.uml2.uml.profile.standard.Destroy;
import org.eclipse.uml2.uml.profile.standard.Document;
import org.eclipse.uml2.uml.profile.standard.Entity;
import org.eclipse.uml2.uml.profile.standard.Executable;
import org.eclipse.uml2.uml.profile.standard.File;
import org.eclipse.uml2.uml.profile.standard.Focus;
import org.eclipse.uml2.uml.profile.standard.Framework;
import org.eclipse.uml2.uml.profile.standard.Implement;
import org.eclipse.uml2.uml.profile.standard.ImplementationClass;
import org.eclipse.uml2.uml.profile.standard.Instantiate;
import org.eclipse.uml2.uml.profile.standard.Library;
import org.eclipse.uml2.uml.profile.standard.Metaclass;
import org.eclipse.uml2.uml.profile.standard.Metamodel;
import org.eclipse.uml2.uml.profile.standard.ModelLibrary;
import org.eclipse.uml2.uml.profile.standard.Realization;
import org.eclipse.uml2.uml.profile.standard.Refine;
import org.eclipse.uml2.uml.profile.standard.Responsibility;
import org.eclipse.uml2.uml.profile.standard.Script;
import org.eclipse.uml2.uml.profile.standard.Send;
import org.eclipse.uml2.uml.profile.standard.Service;
import org.eclipse.uml2.uml.profile.standard.Source;
import org.eclipse.uml2.uml.profile.standard.Specification;
import org.eclipse.uml2.uml.profile.standard.StandardPackage;
import org.eclipse.uml2.uml.profile.standard.Subsystem;
import org.eclipse.uml2.uml.profile.standard.SystemModel;
import org.eclipse.uml2.uml.profile.standard.Trace;
import org.eclipse.uml2.uml.profile.standard.Type;
import org.eclipse.uml2.uml.profile.standard.Utility;
/**
* <!-- 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.eclipse.uml2.uml.profile.standard.StandardPackage
* @generated
*/
public class StandardAdapterFactory
extends AdapterFactoryImpl {
/**
* The cached model package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected static StandardPackage modelPackage;
/**
* Creates an instance of the adapter factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public StandardAdapterFactory() {
if (modelPackage == null) {
modelPackage = StandardPackage.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 StandardSwitch<Adapter> modelSwitch = new StandardSwitch<Adapter>() {
@Override
public Adapter caseAuxiliary(Auxiliary object) {
return createAuxiliaryAdapter();
}
@Override
public Adapter caseCall(Call object) {
return createCallAdapter();
}
@Override
public Adapter caseCreate(Create object) {
return createCreateAdapter();
}
@Override
public Adapter caseDerive(Derive object) {
return createDeriveAdapter();
}
@Override
public Adapter caseDestroy(Destroy object) {
return createDestroyAdapter();
}
@Override
public Adapter caseDocument(Document object) {
return createDocumentAdapter();
}
@Override
public Adapter caseFile(File object) {
return createFileAdapter();
}
@Override
public Adapter caseEntity(Entity object) {
return createEntityAdapter();
}
@Override
public Adapter caseExecutable(Executable object) {
return createExecutableAdapter();
}
@Override
public Adapter caseFocus(Focus object) {
return createFocusAdapter();
}
@Override
public Adapter caseFramework(Framework object) {
return createFrameworkAdapter();
}
@Override
public Adapter caseImplement(Implement object) {
return createImplementAdapter();
}
@Override
public Adapter caseImplementationClass(ImplementationClass object) {
return createImplementationClassAdapter();
}
@Override
public Adapter caseInstantiate(Instantiate object) {
return createInstantiateAdapter();
}
@Override
public Adapter caseLibrary(Library object) {
return createLibraryAdapter();
}
@Override
public Adapter caseMetaclass(Metaclass object) {
return createMetaclassAdapter();
}
@Override
public Adapter caseModelLibrary(ModelLibrary object) {
return createModelLibraryAdapter();
}
@Override
public Adapter caseProcess(
org.eclipse.uml2.uml.profile.standard.Process object) {
return createProcessAdapter();
}
@Override
public Adapter caseRealization(Realization object) {
return createRealizationAdapter();
}
@Override
public Adapter caseRefine(Refine object) {
return createRefineAdapter();
}
@Override
public Adapter caseResponsibility(Responsibility object) {
return createResponsibilityAdapter();
}
@Override
public Adapter caseScript(Script object) {
return createScriptAdapter();
}
@Override
public Adapter caseSend(Send object) {
return createSendAdapter();
}
@Override
public Adapter caseService(Service object) {
return createServiceAdapter();
}
@Override
public Adapter caseSource(Source object) {
return createSourceAdapter();
}
@Override
public Adapter caseSpecification(Specification object) {
return createSpecificationAdapter();
}
@Override
public Adapter caseSubsystem(Subsystem object) {
return createSubsystemAdapter();
}
@Override
public Adapter caseTrace(Trace object) {
return createTraceAdapter();
}
@Override
public Adapter caseType(Type object) {
return createTypeAdapter();
}
@Override
public Adapter caseUtility(Utility object) {
return createUtilityAdapter();
}
@Override
public Adapter caseBuildComponent(BuildComponent object) {
return createBuildComponentAdapter();
}
@Override
public Adapter caseMetamodel(Metamodel object) {
return createMetamodelAdapter();
}
@Override
public Adapter caseSystemModel(SystemModel object) {
return createSystemModelAdapter();
}
@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.eclipse.uml2.uml.profile.standard.Auxiliary <em>Auxiliary</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.eclipse.uml2.uml.profile.standard.Auxiliary
* @generated
*/
public Adapter createAuxiliaryAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Call <em>Call</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.eclipse.uml2.uml.profile.standard.Call
* @generated
*/
public Adapter createCallAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Create <em>Create</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.eclipse.uml2.uml.profile.standard.Create
* @generated
*/
public Adapter createCreateAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Derive <em>Derive</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.eclipse.uml2.uml.profile.standard.Derive
* @generated
*/
public Adapter createDeriveAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Destroy <em>Destroy</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.eclipse.uml2.uml.profile.standard.Destroy
* @generated
*/
public Adapter createDestroyAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Document <em>Document</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.eclipse.uml2.uml.profile.standard.Document
* @generated
*/
public Adapter createDocumentAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.File <em>File</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.eclipse.uml2.uml.profile.standard.File
* @generated
*/
public Adapter createFileAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.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.eclipse.uml2.uml.profile.standard.Entity
* @generated
*/
public Adapter createEntityAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Executable <em>Executable</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.eclipse.uml2.uml.profile.standard.Executable
* @generated
*/
public Adapter createExecutableAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Focus <em>Focus</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.eclipse.uml2.uml.profile.standard.Focus
* @generated
*/
public Adapter createFocusAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Framework <em>Framework</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.eclipse.uml2.uml.profile.standard.Framework
* @generated
*/
public Adapter createFrameworkAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Implement <em>Implement</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.eclipse.uml2.uml.profile.standard.Implement
* @generated
*/
public Adapter createImplementAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.ImplementationClass <em>Implementation Class</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.eclipse.uml2.uml.profile.standard.ImplementationClass
* @generated
*/
public Adapter createImplementationClassAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Instantiate <em>Instantiate</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.eclipse.uml2.uml.profile.standard.Instantiate
* @generated
*/
public Adapter createInstantiateAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Library <em>Library</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.eclipse.uml2.uml.profile.standard.Library
* @generated
*/
public Adapter createLibraryAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Metaclass <em>Metaclass</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.eclipse.uml2.uml.profile.standard.Metaclass
* @generated
*/
public Adapter createMetaclassAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.ModelLibrary <em>Model Library</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.eclipse.uml2.uml.profile.standard.ModelLibrary
* @generated
*/
public Adapter createModelLibraryAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Process <em>Process</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.eclipse.uml2.uml.profile.standard.Process
* @generated
*/
public Adapter createProcessAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Realization <em>Realization</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.eclipse.uml2.uml.profile.standard.Realization
* @generated
*/
public Adapter createRealizationAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Refine <em>Refine</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.eclipse.uml2.uml.profile.standard.Refine
* @generated
*/
public Adapter createRefineAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Responsibility <em>Responsibility</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.eclipse.uml2.uml.profile.standard.Responsibility
* @generated
*/
public Adapter createResponsibilityAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Script <em>Script</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.eclipse.uml2.uml.profile.standard.Script
* @generated
*/
public Adapter createScriptAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Send <em>Send</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.eclipse.uml2.uml.profile.standard.Send
* @generated
*/
public Adapter createSendAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Service <em>Service</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.eclipse.uml2.uml.profile.standard.Service
* @generated
*/
public Adapter createServiceAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Source <em>Source</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.eclipse.uml2.uml.profile.standard.Source
* @generated
*/
public Adapter createSourceAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Specification <em>Specification</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.eclipse.uml2.uml.profile.standard.Specification
* @generated
*/
public Adapter createSpecificationAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Subsystem <em>Subsystem</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.eclipse.uml2.uml.profile.standard.Subsystem
* @generated
*/
public Adapter createSubsystemAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Trace <em>Trace</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.eclipse.uml2.uml.profile.standard.Trace
* @generated
*/
public Adapter createTraceAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Type <em>Type</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.eclipse.uml2.uml.profile.standard.Type
* @generated
*/
public Adapter createTypeAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Utility <em>Utility</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.eclipse.uml2.uml.profile.standard.Utility
* @generated
*/
public Adapter createUtilityAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.BuildComponent <em>Build Component</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.eclipse.uml2.uml.profile.standard.BuildComponent
* @generated
*/
public Adapter createBuildComponentAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.Metamodel <em>Metamodel</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.eclipse.uml2.uml.profile.standard.Metamodel
* @generated
*/
public Adapter createMetamodelAdapter() {
return null;
}
/**
* Creates a new adapter for an object of class '{@link org.eclipse.uml2.uml.profile.standard.SystemModel <em>System Model</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.eclipse.uml2.uml.profile.standard.SystemModel
* @generated
*/
public Adapter createSystemModelAdapter() {
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;
}
} //StandardAdapterFactory