org.eclipse.viatra.query.patternlanguage.emf.types

## Class EMFTypeInferrer

- java.lang.Object
- - org.eclipse.viatra.query.patternlanguage.typing.AbstractTypeInferrer
  - - org.eclipse.viatra.query.patternlanguage.emf.types.EMFTypeInferrer

- All Implemented Interfaces:
    ITypeInferrer

      public class EMFTypeInferrer
      extends AbstractTypeInferrer

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface org.eclipse.viatra.query.patternlanguage.typing.ITypeInferrer

      `ITypeInferrer.NullTypeInferrer`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `EMFTypeInferrer()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.util.Set<IInputKey>` | `getAllPossibleTypes(Expression var)` Returns a collection of possible inferred types.
    `IInputKey` | `getDeclaredType(Expression ex)` Returns the declared type of a variable
    `IInputKey` | `getInferredType(Expression var)` Returns the inferred type of a variable

    - ### Methods inherited from class org.eclipse.viatra.query.patternlanguage.typing.AbstractTypeInferrer

      `getDeclaredType, getInferredVariableType, getJvmType, getType, getVariableJvmType, getVariableReferenceType, getVariableType`

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

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

- - ### Constructor Detail

    - #### EMFTypeInferrer

          public EMFTypeInferrer()

  - ### Method Detail

    - #### getInferredType

          public IInputKey getInferredType(Expression var)

      Description copied from interface: `ITypeInferrer`
      Returns the inferred type of a variable
      Since:
        1.3

    - #### getDeclaredType

          public IInputKey getDeclaredType(Expression ex)

      Description copied from interface: `ITypeInferrer`
      Returns the declared type of a variable
      Specified by:
        `getDeclaredType` in interface `ITypeInferrer`
      Overrides:
        `getDeclaredType` in class `AbstractTypeInferrer`
      Returns:
        the declared type of the variable, or null if no type declaration is available
      Since:
        1.3

    - #### getAllPossibleTypes

          public java.util.Set<IInputKey> getAllPossibleTypes(Expression var)

      Description copied from interface: `ITypeInferrer`
      Returns a collection of possible inferred types. Used for validating inputs; not recommended to use when processing the patterns
      Since:
        1.3