public class IfStatementContext extends StatementContext<IfStmt>
typeSolver, wrappedNode
Constructor and Description |
---|
IfStatementContext(IfStmt wrappedNode,
TypeSolver typeSolver) |
Modifier and Type | Method and Description |
---|---|
List<TypePatternExpr> |
getIntroducedTypePatterns()
The following rules apply to a statement if (e) S:
- A pattern variable is introduced by if (e) S iff
(i) it is introduced by e when false and
(ii) S cannot complete normally.
|
boolean |
nodeContextIsChainedIfElseIf(Context parentContext)
if() {
// Does not match here (doesn't need to, as stuff inside of the if() is likely in context..)
} else if() {
// Matches here
} else {
// Matches here
}
|
boolean |
nodeContextIsConditionOfIfStmt(Context parentContext) |
boolean |
nodeContextIsImmediateChildElse(Context parentContext)
if() {
// Does not match here (doesn't need to, as stuff inside of the if() is likely in context..)
} else {
// Does not match here, as the else block is a field inside of an ifstmt as opposed to child
}
|
boolean |
nodeContextIsThenOfIfStmt(Context parentContext)
if() {
// Does not match here (doesn't need to, as stuff inside of the if() is likely in context..)
} else {
// Does not match here, as the else block is a field inside of an ifstmt as opposed to child
}
|
List<TypePatternExpr> |
typePatternExprsExposedToChild(Node child)
The following rules apply to a statement if (e) S:
- A pattern variable introduced by e when true is definitely matched at S.
|
solveInBlock, solveInBlockAsValue, solveMethod, solveSymbol, solveSymbolAsValue, solveWithAsValue
equals, findExposedPatternInParentContext, findTypeDeclarations, getParent, getScope, getWrappedNode, hashCode, negatedTypePatternExprsExposedFromChildren, solveMethodAsUsage, solveSymbolInParentContext, solveWith, typePatternExprsDiscoveredInPattern, typePatternExprsExposedFromChildren
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
fieldDeclarationInScope, fieldsExposedToChild, localVariableDeclarationInScope, localVariablesExposedToChild, parameterDeclarationInScope, parametersExposedToChild, solveConstructor, solveGenericType, solveGenericTypeInParentContext, solveMethodInParentContext, solveSymbolAsValueInParentContext, solveType, solveType, solveTypeInParentContext, solveTypeInParentContext, typePatternExprInScope
public IfStatementContext(IfStmt wrappedNode, TypeSolver typeSolver)
public List<TypePatternExpr> typePatternExprsExposedToChild(Node child)
public List<TypePatternExpr> getIntroducedTypePatterns()
getIntroducedTypePatterns
in class StatementContext<IfStmt>
public boolean nodeContextIsChainedIfElseIf(Context parentContext)
if() {
// Does not match here (doesn't need to, as stuff inside of the if() is likely in context..)
} else if() {
// Matches here
} else {
// Matches here
}
public boolean nodeContextIsImmediateChildElse(Context parentContext)
if() {
// Does not match here (doesn't need to, as stuff inside of the if() is likely in context..)
} else {
// Does not match here, as the else block is a field inside of an ifstmt as opposed to child
}
public boolean nodeContextIsThenOfIfStmt(Context parentContext)
if() {
// Does not match here (doesn't need to, as stuff inside of the if() is likely in context..)
} else {
// Does not match here, as the else block is a field inside of an ifstmt as opposed to child
}
public boolean nodeContextIsConditionOfIfStmt(Context parentContext)
Copyright © 2007–2024. All rights reserved.