Class NonProbabilisticExpressionInferTypeVisitor


public class NonProbabilisticExpressionInferTypeVisitor extends ExpressionInferTypeVisitor
  • Constructor Details

    • NonProbabilisticExpressionInferTypeVisitor

      public NonProbabilisticExpressionInferTypeVisitor()
  • Method Details

    • getType

      public TypeEnum getType(Expression e)
      Description copied from class: ExpressionInferTypeVisitor
      Return the inferred type of the passed expression node. The type annotation is automatically stored in the Map if it has not been inferred before.
      Overrides:
      getType in class ExpressionInferTypeVisitor
      Parameters:
      e - The node whose type should be returned.
      Returns:
      The inferred type of the expression.
    • casePowerExpression

      public Object casePowerExpression(PowerExpression expr)
      Result of a power expression so far only be of type DOUBLE, as the power operation is only allowed on NUMBERs, not PMFs.
      Overrides:
      casePowerExpression in class ExpressionInferTypeVisitor
      Parameters:
      expr - the target of the switch.
      Returns:
      the result of interpreting the object as an instance of 'Power Expression'.
      See Also: