org.jetbrains.kotlin.types.expressions
Class DataFlowAnalyzer

java.lang.Object
  extended by org.jetbrains.kotlin.types.expressions.DataFlowAnalyzer

public class DataFlowAnalyzer
extends java.lang.Object


Constructor Summary
DataFlowAnalyzer(java.lang.Iterable<AdditionalTypeChecker> additionalTypeCheckers, ConstantExpressionEvaluator constantExpressionEvaluator, KotlinBuiltIns builtIns, SmartCastManager smartCastManager, ExpressionTypingFacade facade)
           
 
Method Summary
 KotlinTypeInfo checkImplicitCast(KotlinTypeInfo typeInfo, KtExpression expression, ResolutionContext context, boolean isStatement)
           
 KotlinType checkImplicitCast(KotlinType expressionType, KtExpression expression, ResolutionContext context, boolean isStatement)
           
 KotlinType checkPossibleCast(KotlinType expressionType, KtExpression expression, ResolutionContext c)
           
 KotlinType checkStatementType(KtExpression expression, ResolutionContext context)
           
 KotlinTypeInfo checkType(KotlinTypeInfo typeInfo, KtExpression expression, ResolutionContext context)
           
 KotlinType checkType(KotlinType expressionType, KtExpression expression, ResolutionContext context)
           
 KotlinType checkType(KotlinType expressionType, KtExpression expressionToCheck, ResolutionContext c, com.intellij.openapi.util.Ref<java.lang.Boolean> hasError)
           
 KotlinTypeInfo createCheckedTypeInfo(KotlinType type, ResolutionContext<?> context, KtExpression expression)
           
 KotlinTypeInfo createCompileTimeConstantTypeInfo( value, KtExpression expression, ExpressionTypingContext context)
           
 DataFlowInfo extractDataFlowInfoFromCondition(KtExpression condition, boolean conditionValue, ExpressionTypingContext context)
           
 java.util.Collection<KotlinType> getAllPossibleTypes(KtExpression expression, DataFlowInfo dataFlowInfo, KotlinType type, ResolutionContext c)
           
 KotlinTypeInfo illegalStatementType(KtExpression expression, ExpressionTypingContext context, org.jetbrains.kotlin.types.expressions.ExpressionTypingInternals facade)
           
 void recordExpectedType(BindingTrace trace, KtExpression expression, KotlinType expectedType)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DataFlowAnalyzer

public DataFlowAnalyzer(@NotNull
                        java.lang.Iterable<AdditionalTypeChecker> additionalTypeCheckers,
                        @NotNull
                        ConstantExpressionEvaluator constantExpressionEvaluator,
                        @NotNull
                        KotlinBuiltIns builtIns,
                        @NotNull
                        SmartCastManager smartCastManager,
                        @NotNull
                        ExpressionTypingFacade facade)
Method Detail

extractDataFlowInfoFromCondition

@NotNull
public DataFlowInfo extractDataFlowInfoFromCondition(@Nullable
                                                             KtExpression condition,
                                                             boolean conditionValue,
                                                             ExpressionTypingContext context)

checkType

@Nullable
public KotlinType checkType(@Nullable
                                     KotlinType expressionType,
                                     @NotNull
                                     KtExpression expression,
                                     @NotNull
                                     ResolutionContext context)

checkType

@NotNull
public KotlinTypeInfo checkType(@NotNull
                                        KotlinTypeInfo typeInfo,
                                        @NotNull
                                        KtExpression expression,
                                        @NotNull
                                        ResolutionContext context)

checkType

@Nullable
public KotlinType checkType(@Nullable
                                     KotlinType expressionType,
                                     @NotNull
                                     KtExpression expressionToCheck,
                                     @NotNull
                                     ResolutionContext c,
                                     @Nullable
                                     com.intellij.openapi.util.Ref<java.lang.Boolean> hasError)

checkPossibleCast

@Nullable
public KotlinType checkPossibleCast(@NotNull
                                             KotlinType expressionType,
                                             @NotNull
                                             KtExpression expression,
                                             @NotNull
                                             ResolutionContext c)

recordExpectedType

public void recordExpectedType(@NotNull
                               BindingTrace trace,
                               @NotNull
                               KtExpression expression,
                               @NotNull
                               KotlinType expectedType)

checkStatementType

@Nullable
public KotlinType checkStatementType(@NotNull
                                              KtExpression expression,
                                              @NotNull
                                              ResolutionContext context)

checkImplicitCast

@Nullable
public KotlinType checkImplicitCast(@Nullable
                                             KotlinType expressionType,
                                             @NotNull
                                             KtExpression expression,
                                             @NotNull
                                             ResolutionContext context,
                                             boolean isStatement)

checkImplicitCast

@NotNull
public KotlinTypeInfo checkImplicitCast(@NotNull
                                                KotlinTypeInfo typeInfo,
                                                @NotNull
                                                KtExpression expression,
                                                @NotNull
                                                ResolutionContext context,
                                                boolean isStatement)

illegalStatementType

@NotNull
public KotlinTypeInfo illegalStatementType(@NotNull
                                                   KtExpression expression,
                                                   @NotNull
                                                   ExpressionTypingContext context,
                                                   @NotNull
                                                   org.jetbrains.kotlin.types.expressions.ExpressionTypingInternals facade)

getAllPossibleTypes

@NotNull
public java.util.Collection<KotlinType> getAllPossibleTypes(@NotNull
                                                                    KtExpression expression,
                                                                    @NotNull
                                                                    DataFlowInfo dataFlowInfo,
                                                                    @NotNull
                                                                    KotlinType type,
                                                                    @NotNull
                                                                    ResolutionContext c)

createCheckedTypeInfo

@NotNull
public KotlinTypeInfo createCheckedTypeInfo(@Nullable
                                                    KotlinType type,
                                                    @NotNull
                                                    ResolutionContext<?> context,
                                                    @NotNull
                                                    KtExpression expression)

createCompileTimeConstantTypeInfo

@NotNull
public KotlinTypeInfo createCompileTimeConstantTypeInfo(@NotNull
                                                                 value,
                                                                @NotNull
                                                                KtExpression expression,
                                                                @NotNull
                                                                ExpressionTypingContext context)