org.eclipse.oomph.setup.util

## Class SetupSwitch<T>

- java.lang.Object
- - org.eclipse.emf.ecore.util.Switch<T>
  - - org.eclipse.oomph.setup.util.SetupSwitch<T>

-     public class SetupSwitch<T>
      extends Switch<T>

  The Switch for the model's inheritance hierarchy. It supports the call `doSwitch(object)` to invoke the `caseXXX` method for each class of the model, starting with the actual class of the object and proceeding up the inheritance hierarchy until a non-null result is returned, which is the result of the switch.
  See Also:
    `SetupPackage`
  Generated

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected static SetupPackage` | `modelPackage` The cached model package

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SetupSwitch()` Creates an instance of the switch.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `T` | `caseAttributeRule(AttributeRule object)` Returns the result of interpreting the object as an instance of 'Attribute Rule'.
    `T` | `caseCatalogSelection(CatalogSelection object)` Returns the result of interpreting the object as an instance of 'Catalog Selection'.
    `T` | `caseCompoundTask(CompoundTask object)` Returns the result of interpreting the object as an instance of 'Compound Task'.
    `T` | `caseEclipseIniTask(EclipseIniTask object)` Returns the result of interpreting the object as an instance of 'Eclipse Ini Task'.
    `T` | `caseIndex(Index object)` Returns the result of interpreting the object as an instance of 'Index'.
    `T` | `caseInstallation(Installation object)` Returns the result of interpreting the object as an instance of 'Installation'.
    `T` | `caseInstallationTask(InstallationTask object)` Returns the result of interpreting the object as an instance of 'Installation Task'.
    `T` | `caseInstallationToWorkspacesMapEntry(Map.Entry<Installation,EList<Workspace>> object)` Returns the result of interpreting the object as an instance of 'Installation To Workspaces Map Entry'.
    `T` | `caseLinkLocationTask(LinkLocationTask object)` Returns the result of interpreting the object as an instance of 'Link Location Task'.
    `T` | `caseLocationCatalog(LocationCatalog object)` Returns the result of interpreting the object as an instance of 'Location Catalog'.
    `T` | `caseModelElement(ModelElement object)` Returns the result of interpreting the object as an instance of 'Model Element'.
    `T` | `casePreferenceTask(PreferenceTask object)` Returns the result of interpreting the object as an instance of 'Preference Task'.
    `T` | `caseProduct(Product object)` Returns the result of interpreting the object as an instance of 'Product'.
    `T` | `caseProductCatalog(ProductCatalog object)` Returns the result of interpreting the object as an instance of 'Product Catalog'.
    `T` | `caseProductToProductVersionMapEntry(Map.Entry<Product,ProductVersion> object)` Returns the result of interpreting the object as an instance of 'Product To Product Version Map Entry'.
    `T` | `caseProductVersion(ProductVersion object)` Returns the result of interpreting the object as an instance of 'Product Version'.
    `T` | `caseProject(Project object)` Returns the result of interpreting the object as an instance of 'Project'.
    `T` | `caseProjectCatalog(ProjectCatalog object)` Returns the result of interpreting the object as an instance of 'Project Catalog'.
    `T` | `caseProjectContainer(ProjectContainer object)` Returns the result of interpreting the object as an instance of 'Project Container'.
    `T` | `caseProjectToStreamMapEntry(Map.Entry<Project,Stream> object)` Returns the result of interpreting the object as an instance of 'Project To Stream Map Entry'.
    `T` | `caseRedirectionTask(RedirectionTask object)` Returns the result of interpreting the object as an instance of 'Redirection Task'.
    `T` | `caseResourceCopyTask(ResourceCopyTask object)` Returns the result of interpreting the object as an instance of 'Resource Copy Task'.
    `T` | `caseResourceCreationTask(ResourceCreationTask object)` Returns the result of interpreting the object as an instance of 'Resource Creation Task'.
    `T` | `caseScope(Scope object)` Returns the result of interpreting the object as an instance of 'Scope'.
    `T` | `caseSetupTask(SetupTask object)` Returns the result of interpreting the object as an instance of 'Task'.
    `T` | `caseSetupTaskContainer(SetupTaskContainer object)` Returns the result of interpreting the object as an instance of 'Task Container'.
    `T` | `caseStream(Stream object)` Returns the result of interpreting the object as an instance of 'Stream'.
    `T` | `caseStringSubstitutionTask(StringSubstitutionTask object)` Returns the result of interpreting the object as an instance of 'String Substitution Task'.
    `T` | `caseTextModification(TextModification object)` Returns the result of interpreting the object as an instance of 'Text Modification'.
    `T` | `caseTextModifyTask(TextModifyTask object)` Returns the result of interpreting the object as an instance of 'Text Modify Task'.
    `T` | `caseUser(User object)` Returns the result of interpreting the object as an instance of 'User'.
    `T` | `caseVariableChoice(VariableChoice object)` Returns the result of interpreting the object as an instance of 'Variable Choice'.
    `T` | `caseVariableTask(VariableTask object)` Returns the result of interpreting the object as an instance of 'Variable Task'.
    `T` | `caseWorkspace(Workspace object)` Returns the result of interpreting the object as an instance of 'Workspace'.
    `T` | `caseWorkspaceTask(WorkspaceTask object)` Returns the result of interpreting the object as an instance of 'Workspace Task'.
    `T` | `caseWorkspaceToInstallationsMapEntry(Map.Entry<Workspace,EList<Installation>> object)` Returns the result of interpreting the object as an instance of 'Workspace To Installations Map Entry'.
    `T` | `defaultCase(EObject object)` Returns the result of interpreting the object as an instance of 'EObject'.
    `protected T` | `doSwitch(int classifierID, EObject theEObject)` Calls `caseXXX` for each class of the model until one returns a non null result; it yields that result.
    `protected boolean` | `isSwitchFor(EPackage ePackage)` Checks whether this is a switch for the given package.

    - ### Methods inherited from class org.eclipse.emf.ecore.util.Switch

      `doSwitch, doSwitch`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### modelPackage

          protected static SetupPackage modelPackage

      The cached model package
      Generated

  - ### Constructor Detail

    - #### SetupSwitch

          public SetupSwitch()

      Creates an instance of the switch.
      Generated

  - ### Method Detail

    - #### isSwitchFor

          protected boolean isSwitchFor(EPackage ePackage)

      Checks whether this is a switch for the given package.
      Specified by:
        `isSwitchFor` in class `Switch<T>`
      Returns:
        whether this is a switch for the given package.
      Generated

    - #### doSwitch

          protected T doSwitch(int classifierID,
                   EObject theEObject)

      Calls `caseXXX` for each class of the model until one returns a non null result; it yields that result.
      Overrides:
        `doSwitch` in class `Switch<T>`
      Returns:
        the first non-null result returned by a `caseXXX` call.
      Generated

    - #### caseIndex

          public T caseIndex(Index object)

      Returns the result of interpreting the object as an instance of 'Index'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Index'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseCatalogSelection

          public T caseCatalogSelection(CatalogSelection object)

      Returns the result of interpreting the object as an instance of 'Catalog Selection'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Catalog Selection'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseWorkspace

          public T caseWorkspace(Workspace object)

      Returns the result of interpreting the object as an instance of 'Workspace'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Workspace'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseLinkLocationTask

          public T caseLinkLocationTask(LinkLocationTask object)

      Returns the result of interpreting the object as an instance of 'Link Location Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Link Location Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### casePreferenceTask

          public T casePreferenceTask(PreferenceTask object)

      Returns the result of interpreting the object as an instance of 'Preference Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Preference Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseSetupTaskContainer

          public T caseSetupTaskContainer(SetupTaskContainer object)

      Returns the result of interpreting the object as an instance of 'Task Container'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Task Container'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseScope

          public T caseScope(Scope object)

      Returns the result of interpreting the object as an instance of 'Scope'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Scope'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseProject

          public T caseProject(Project object)

      Returns the result of interpreting the object as an instance of 'Project'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Project'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseStream

          public T caseStream(Stream object)

      Returns the result of interpreting the object as an instance of 'Stream'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Stream'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseInstallation

          public T caseInstallation(Installation object)

      Returns the result of interpreting the object as an instance of 'Installation'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Installation'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseProductCatalog

          public T caseProductCatalog(ProductCatalog object)

      Returns the result of interpreting the object as an instance of 'Product Catalog'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Product Catalog'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseProduct

          public T caseProduct(Product object)

      Returns the result of interpreting the object as an instance of 'Product'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Product'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseProductVersion

          public T caseProductVersion(ProductVersion object)

      Returns the result of interpreting the object as an instance of 'Product Version'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Product Version'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseProjectCatalog

          public T caseProjectCatalog(ProjectCatalog object)

      Returns the result of interpreting the object as an instance of 'Project Catalog'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Project Catalog'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseInstallationTask

          public T caseInstallationTask(InstallationTask object)

      Returns the result of interpreting the object as an instance of 'Installation Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Installation Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseWorkspaceTask

          public T caseWorkspaceTask(WorkspaceTask object)

      Returns the result of interpreting the object as an instance of 'Workspace Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Workspace Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseCompoundTask

          public T caseCompoundTask(CompoundTask object)

      Returns the result of interpreting the object as an instance of 'Compound Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Compound Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseVariableTask

          public T caseVariableTask(VariableTask object)

      Returns the result of interpreting the object as an instance of 'Variable Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Variable Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseSetupTask

          public T caseSetupTask(SetupTask object)

      Returns the result of interpreting the object as an instance of 'Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseResourceCopyTask

          public T caseResourceCopyTask(ResourceCopyTask object)

      Returns the result of interpreting the object as an instance of 'Resource Copy Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Resource Copy Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseTextModifyTask

          public T caseTextModifyTask(TextModifyTask object)

      Returns the result of interpreting the object as an instance of 'Text Modify Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Text Modify Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseTextModification

          public T caseTextModification(TextModification object)

      Returns the result of interpreting the object as an instance of 'Text Modification'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Text Modification'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseProductToProductVersionMapEntry

          public T caseProductToProductVersionMapEntry(Map.Entry<Product,ProductVersion> object)

      Returns the result of interpreting the object as an instance of 'Product To Product Version Map Entry'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Product To Product Version Map Entry'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseProjectToStreamMapEntry

          public T caseProjectToStreamMapEntry(Map.Entry<Project,Stream> object)

      Returns the result of interpreting the object as an instance of 'Project To Stream Map Entry'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Project To Stream Map Entry'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseInstallationToWorkspacesMapEntry

          public T caseInstallationToWorkspacesMapEntry(Map.Entry<Installation,EList<Workspace>> object)

      Returns the result of interpreting the object as an instance of 'Installation To Workspaces Map Entry'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Installation To Workspaces Map Entry'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseWorkspaceToInstallationsMapEntry

          public T caseWorkspaceToInstallationsMapEntry(Map.Entry<Workspace,EList<Installation>> object)

      Returns the result of interpreting the object as an instance of 'Workspace To Installations Map Entry'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Workspace To Installations Map Entry'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseModelElement

          public T caseModelElement(ModelElement object)

      Returns the result of interpreting the object as an instance of 'Model Element'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Model Element'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseStringSubstitutionTask

          public T caseStringSubstitutionTask(StringSubstitutionTask object)

      Returns the result of interpreting the object as an instance of 'String Substitution Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'String Substitution Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseProjectContainer

          public T caseProjectContainer(ProjectContainer object)

      Returns the result of interpreting the object as an instance of 'Project Container'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Project Container'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseAttributeRule

          public T caseAttributeRule(AttributeRule object)

      Returns the result of interpreting the object as an instance of 'Attribute Rule'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Attribute Rule'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseLocationCatalog

          public T caseLocationCatalog(LocationCatalog object)

      Returns the result of interpreting the object as an instance of 'Location Catalog'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Location Catalog'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseRedirectionTask

          public T caseRedirectionTask(RedirectionTask object)

      Returns the result of interpreting the object as an instance of 'Redirection Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Redirection Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseVariableChoice

          public T caseVariableChoice(VariableChoice object)

      Returns the result of interpreting the object as an instance of 'Variable Choice'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Variable Choice'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseResourceCreationTask

          public T caseResourceCreationTask(ResourceCreationTask object)

      Returns the result of interpreting the object as an instance of 'Resource Creation Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Resource Creation Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseEclipseIniTask

          public T caseEclipseIniTask(EclipseIniTask object)

      Returns the result of interpreting the object as an instance of 'Eclipse Ini Task'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'Eclipse Ini Task'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### caseUser

          public T caseUser(User object)

      Returns the result of interpreting the object as an instance of 'User'. This implementation returns null; returning a non-null result will terminate the switch.
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'User'.
      See Also:
        `doSwitch(EObject)`
      Generated

    - #### defaultCase

          public T defaultCase(EObject object)

      Returns the result of interpreting the object as an instance of 'EObject'. This implementation returns null; returning a non-null result will terminate the switch, but this is the last case anyway.
      Overrides:
        `defaultCase` in class `Switch<T>`
      Parameters:
        `object` - the target of the switch.
      Returns:
        the result of interpreting the object as an instance of 'EObject'.
      See Also:
        `Switch.doSwitch(org.eclipse.emf.ecore.EObject)`
      Generated

Copyright (c) 2014 Eike Stepper (Loehne, Germany) 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