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)
           
 
Method Summary
 JetTypeInfo checkImplicitCast(JetTypeInfo 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)
           
 JetTypeInfo checkType(JetTypeInfo 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)
           
 JetTypeInfo createCheckedTypeInfo(KotlinType type, ResolutionContext<?> context, KtExpression expression)
           
 JetTypeInfo 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)
           
 JetTypeInfo 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)
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 JetTypeInfo checkType(@NotNull
                                     JetTypeInfo 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 JetTypeInfo checkImplicitCast(@NotNull
                                             JetTypeInfo typeInfo,
                                             @NotNull
                                             KtExpression expression,
                                             @NotNull
                                             ResolutionContext context,
                                             boolean isStatement)

illegalStatementType

@NotNull
public JetTypeInfo 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 JetTypeInfo createCheckedTypeInfo(@Nullable
                                                 KotlinType type,
                                                 @NotNull
                                                 ResolutionContext<?> context,
                                                 @NotNull
                                                 KtExpression expression)

createCompileTimeConstantTypeInfo

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