Class StatementContext<N extends Statement>
- java.lang.Object
-
- com.github.javaparser.symbolsolver.javaparsermodel.contexts.AbstractJavaParserContext<N>
-
- com.github.javaparser.symbolsolver.javaparsermodel.contexts.StatementContext<N>
-
- All Implemented Interfaces:
Context
- Direct Known Subclasses:
BlockStmtContext,DoStatementContext,ForEachStatementContext,ForStatementContext,IfStatementContext,TryWithResourceContext,WhileStatementContext
public class StatementContext<N extends Statement> extends AbstractJavaParserContext<N>
- Author:
- Federico Tomassetti
-
-
Field Summary
-
Fields inherited from class com.github.javaparser.symbolsolver.javaparsermodel.contexts.AbstractJavaParserContext
typeSolver, wrappedNode
-
-
Constructor Summary
Constructors Constructor Description StatementContext(N wrappedNode, TypeSolver typeSolver)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description List<TypePatternExpr>getIntroducedTypePatterns()static SymbolReference<? extends ResolvedValueDeclaration>solveInBlock(String name, TypeSolver typeSolver, Statement stmt)static Optional<Value>solveInBlockAsValue(String name, TypeSolver typeSolver, Statement stmt)SymbolReference<ResolvedMethodDeclaration>solveMethod(String name, List<ResolvedType> argumentsTypes, boolean staticOnly)SymbolReference<? extends ResolvedValueDeclaration>solveSymbol(String name)Optional<Value>solveSymbolAsValue(String name)protected Optional<Value>solveWithAsValue(SymbolDeclarator symbolDeclarator, String name)-
Methods inherited from class com.github.javaparser.symbolsolver.javaparsermodel.contexts.AbstractJavaParserContext
equals, findExposedPatternInParentContext, findTypeDeclarations, getParent, getScope, getWrappedNode, hashCode, negatedTypePatternExprsExposedFromChildren, solveMethodAsUsage, solveSymbolInParentContext, solveWith, typePatternExprsDiscoveredInPattern, typePatternExprsExposedFromChildren
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.github.javaparser.resolution.Context
fieldDeclarationInScope, fieldsExposedToChild, localVariableDeclarationInScope, localVariablesExposedToChild, parameterDeclarationInScope, parametersExposedToChild, solveConstructor, solveGenericType, solveGenericTypeInParentContext, solveMethodInParentContext, solveSymbolAsValueInParentContext, solveType, solveType, solveTypeInParentContext, solveTypeInParentContext, typePatternExprInScope, typePatternExprsExposedToChild
-
-
-
-
Constructor Detail
-
StatementContext
public StatementContext(N wrappedNode, TypeSolver typeSolver)
-
-
Method Detail
-
solveInBlock
public static SymbolReference<? extends ResolvedValueDeclaration> solveInBlock(String name, TypeSolver typeSolver, Statement stmt)
-
solveInBlockAsValue
public static Optional<Value> solveInBlockAsValue(String name, TypeSolver typeSolver, Statement stmt)
-
solveWithAsValue
protected Optional<Value> solveWithAsValue(SymbolDeclarator symbolDeclarator, String name)
- Overrides:
solveWithAsValuein classAbstractJavaParserContext<N extends Statement>
-
solveSymbol
public SymbolReference<? extends ResolvedValueDeclaration> solveSymbol(String name)
-
solveMethod
public SymbolReference<ResolvedMethodDeclaration> solveMethod(String name, List<ResolvedType> argumentsTypes, boolean staticOnly)
-
getIntroducedTypePatterns
public List<TypePatternExpr> getIntroducedTypePatterns()
-
-