Class TypesSwitch<T>


  • public class TypesSwitch<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:
    TypesPackage
    Generated class or method.
    • Field Detail

      • modelPackage

        protected static TypesPackage modelPackage
        The cached model package
        Generated class or method.
    • Constructor Detail

      • TypesSwitch

        public TypesSwitch()
        Creates an instance of the switch.
        Generated class or method.
    • 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>
        Parameters:
        ePackage - the package in question.
        Returns:
        whether this is a switch for the given package.
        Generated class or method.
      • 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 class or method.
      • caseType

        public T caseType​(Type object)
        Returns the result of interpreting the object as an instance of 'Type'. 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 'Type'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseTypedElement

        public T caseTypedElement​(TypedElement object)
        Returns the result of interpreting the object as an instance of 'Typed 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 'Typed Element'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseTypedElementExtension

        public T caseTypedElementExtension​(TypedElementExtension object)
        Returns the result of interpreting the object as an instance of 'Typed Element Extension'. 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 'Typed Element Extension'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseTypeReference

        public T caseTypeReference​(TypeReference object)
        Returns the result of interpreting the object as an instance of 'Type Reference'. 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 'Type Reference'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseClassifierReference

        public T caseClassifierReference​(ClassifierReference object)
        Returns the result of interpreting the object as an instance of 'Classifier Reference'. 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 'Classifier Reference'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseNamespaceClassifierReference

        public T caseNamespaceClassifierReference​(NamespaceClassifierReference object)
        Returns the result of interpreting the object as an instance of 'Namespace Classifier Reference'. 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 'Namespace Classifier Reference'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • casePrimitiveType

        public T casePrimitiveType​(PrimitiveType object)
        Returns the result of interpreting the object as an instance of 'Primitive Type'. 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 'Primitive Type'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseBoolean

        public T caseBoolean​(Boolean object)
        Returns the result of interpreting the object as an instance of 'Boolean'. 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 'Boolean'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseByte

        public T caseByte​(Byte object)
        Returns the result of interpreting the object as an instance of 'Byte'. 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 'Byte'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseChar

        public T caseChar​(Char object)
        Returns the result of interpreting the object as an instance of 'Char'. 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 'Char'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseDouble

        public T caseDouble​(Double object)
        Returns the result of interpreting the object as an instance of 'Double'. 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 'Double'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseFloat

        public T caseFloat​(Float object)
        Returns the result of interpreting the object as an instance of 'Float'. 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 'Float'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseInt

        public T caseInt​(Int object)
        Returns the result of interpreting the object as an instance of 'Int'. 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 'Int'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseLong

        public T caseLong​(Long object)
        Returns the result of interpreting the object as an instance of 'Long'. 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 'Long'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseShort

        public T caseShort​(Short object)
        Returns the result of interpreting the object as an instance of 'Short'. 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 'Short'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseVoid

        public T caseVoid​(Void object)
        Returns the result of interpreting the object as an instance of 'Void'. 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 'Void'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseInferableType

        public T caseInferableType​(InferableType object)
        Returns the result of interpreting the object as an instance of 'Inferable Type'. 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 'Inferable Type'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseCommentable

        public T caseCommentable​(Commentable object)
        Returns the result of interpreting the object as an instance of 'Commentable'. 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 'Commentable'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseArrayTypeable

        public T caseArrayTypeable​(ArrayTypeable object)
        Returns the result of interpreting the object as an instance of 'Array Typeable'. 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 'Array Typeable'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseTypeArgumentable

        public T caseTypeArgumentable​(TypeArgumentable object)
        Returns the result of interpreting the object as an instance of 'Type Argumentable'. 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 'Type Argumentable'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseAnnotable

        public T caseAnnotable​(Annotable object)
        Returns the result of interpreting the object as an instance of 'Annotable'. 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 'Annotable'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • caseNamespaceAwareElement

        public T caseNamespaceAwareElement​(NamespaceAwareElement object)
        Returns the result of interpreting the object as an instance of 'Namespace Aware 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 'Namespace Aware Element'.
        See Also:
        doSwitch(EObject)
        Generated class or method.
      • 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 class or method.