diff options
Diffstat (limited to 'plugins/org.eclipse.jst.j2ee.core/mofj2ee/org/eclipse/jst/j2ee/internal/client/util/ClientAdapterFactory.java')
-rw-r--r-- | plugins/org.eclipse.jst.j2ee.core/mofj2ee/org/eclipse/jst/j2ee/internal/client/util/ClientAdapterFactory.java | 158 |
1 files changed, 0 insertions, 158 deletions
diff --git a/plugins/org.eclipse.jst.j2ee.core/mofj2ee/org/eclipse/jst/j2ee/internal/client/util/ClientAdapterFactory.java b/plugins/org.eclipse.jst.j2ee.core/mofj2ee/org/eclipse/jst/j2ee/internal/client/util/ClientAdapterFactory.java deleted file mode 100644 index 33a7d2fc9..000000000 --- a/plugins/org.eclipse.jst.j2ee.core/mofj2ee/org/eclipse/jst/j2ee/internal/client/util/ClientAdapterFactory.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2001, 2004 IBM Corporation 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: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.client.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.emf.ecore.EPackage; -import org.eclipse.jst.j2ee.client.ApplicationClient; -import org.eclipse.jst.j2ee.common.CompatibilityDescriptionGroup; -import org.eclipse.jst.j2ee.common.DescriptionGroup; -import org.eclipse.jst.j2ee.internal.client.ClientPackage; - - - -public class ClientAdapterFactory extends AdapterFactoryImpl { - protected static ClientPackage modelPackage; - - public ClientAdapterFactory() { - if (modelPackage == null) { - modelPackage = (ClientPackage)EPackage.Registry.INSTANCE.getEPackage(ClientPackage.eNS_URI); - } - } - public boolean isFactoryForType(Object type) { - if (type == modelPackage) { - return true; - } - if (type instanceof EObject) { - return ((EObject)type).eClass().eContainer() == modelPackage; - } - return false; - } - - protected ClientSwitch sw = new ClientSwitch() { - public Object caseApplicationClient(ApplicationClient object) { - return createApplicationClientAdapter(); - } - }; - - public Adapter createAdapter(Notifier target) { - return (Adapter)sw.doSwitch((EObject)target); - } - - /** - * By default create methods return null so that we can easily ignore cases. - * It's useful to ignore a case when inheritance will catch all the cases anyway. - */ - - public Adapter createApplicationClientAdapter() { - return null; - } - /** - * @generated This field/method will be replaced during code generation. - */ - public boolean isFactoryForTypeGen(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject)object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch the delegates to the <code>createXXX</code> methods. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected ClientSwitch modelSwitch = - new ClientSwitch() { - public Object caseApplicationClient(ApplicationClient object) { - return createApplicationClientAdapter(); - } - public Object caseDescriptionGroup(DescriptionGroup object) { - return createDescriptionGroupAdapter(); - } - public Object caseCompatibilityDescriptionGroup(CompatibilityDescriptionGroup object) { - return createCompatibilityDescriptionGroupAdapter(); - } - public Object defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * @generated This field/method will be replaced during code generation. - */ - public Adapter createAdapterGen(Notifier target) { - return (Adapter)modelSwitch.doSwitch((EObject)target); - } - - - /** - * By default create methods return null so that we can easily ignore cases. - * It's useful to ignore a case when inheritance will catch all the cases anyway. - */ - - /** - * @generated This field/method will be replaced during code generation. - */ - public Adapter createApplicationClientAdapterGen() { - - return null; - } - /** - * Creates a new adapter for an object of class '{@link org.eclipse.jst.j2ee.internal.common.DescriptionGroup <em>Description Group</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.jst.j2ee.internal.common.DescriptionGroup - * @generated - */ - public Adapter createDescriptionGroupAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.jst.j2ee.internal.common.CompatibilityDescriptionGroup <em>Compatibility Description Group</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.jst.j2ee.internal.common.CompatibilityDescriptionGroup - * @generated - */ - public Adapter createCompatibilityDescriptionGroupAdapter() { - 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; - } - -} //ClientAdapterFactory - - |