org.eclipse.viatra.query.patternlanguage.typing

## Class ITypeInferrer.NullTypeInferrer

- java.lang.Object
- - org.eclipse.viatra.query.patternlanguage.typing.AbstractTypeInferrer
  - - org.eclipse.viatra.query.patternlanguage.typing.ITypeInferrer.NullTypeInferrer

- All Implemented Interfaces:
    ITypeInferrer
  Enclosing interface:
    ITypeInferrer

      public static class ITypeInferrer.NullTypeInferrer
      extends AbstractTypeInferrer

  An empty implementation of `ITypeInferrer` that can be used by the abstract pattern language module.
  Since:
    1.3

- - ### Nested Class Summary

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

      `ITypeInferrer.NullTypeInferrer`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `NullTypeInferrer()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.util.Set<IInputKey>` | `getAllPossibleTypes(Expression ex)` Returns a collection of possible inferred types.
    `IInputKey` | `getDeclaredType(Expression ex)` Returns the declared type of a variable
    `IInputKey` | `getInferredType(Expression ex)` Returns the inferred type of a variable
    `org.eclipse.xtext.common.types.JvmTypeReference` | `getJvmType(Expression ex, org.eclipse.emf.ecore.EObject context)` Creates a Jvm Type Reference for a selected expression.
    `IInputKey` | `getType(Expression ex)` Returns the type of a variable.

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

      `getDeclaredType, getInferredVariableType, getVariableJvmType, getVariableReferenceType, getVariableType`

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

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

- - ### Constructor Detail

    - #### NullTypeInferrer

          public NullTypeInferrer()

  - ### Method Detail

    - #### getInferredType

          public IInputKey getInferredType(Expression ex)

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

    - #### getJvmType

          public org.eclipse.xtext.common.types.JvmTypeReference getJvmType(Expression ex,
                                                                            org.eclipse.emf.ecore.EObject context)

      Description copied from interface: `ITypeInferrer`
      Creates a Jvm Type Reference for a selected expression. Useful during Jvm Model Inference
      Specified by:
        `getJvmType` in interface `ITypeInferrer`
      Overrides:
        `getJvmType` in class `AbstractTypeInferrer`
      Since:
        1.3

    - #### getType

          public IInputKey getType(Expression ex)

      Description copied from interface: `ITypeInferrer`
      Returns the type of a variable.
      Specified by:
        `getType` in interface `ITypeInferrer`
      Overrides:
        `getType` in class `AbstractTypeInferrer`
      Returns:
        if the variable has a declared type, it is returned; otherwise the inferred type is calculated.
      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 ex)

      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