Package pascal.taie.ir
Interface IR
- All Superinterfaces:
Indexer<Stmt>
,Iterable<Stmt>
,ResultHolder
,Serializable
- All Known Implementing Classes:
DefaultIR
Intermediate representation for method body of non-abstract methods.
Each IR contains the variables and statements defined in a method.
-
Method Summary
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface pascal.taie.util.ResultHolder
clearAll, clearResult, getKeys, getResult, getResult, getResult, hasResult, storeResult
-
Method Details
-
getMethod
JMethod getMethod()- Returns:
- the method that defines the content of this IR.
-
getThis
- Returns:
- the "this" variable in this IR. If the method is static, then returns null.
-
getParams
- Returns:
- the parameters in this IR ("this" variable is excluded). The order of the parameters in the resulting list is the same as the order they are declared in the method.
-
getParam
- Returns:
- the i-th parameter in this IR. The indexes start from 0.
-
isParam
- Returns:
true
ifvar
is a parameter of this IR.
-
isThisOrParam
- Returns:
true
ifvar
is "this" variable or a parameter of this IR.
-
getReturnVars
- Returns:
- all returned variables. If the method return type is void, then returns empty list.
-
getVar
- Returns:
- the i-th
Var
in this IR. The indexes start from 0.
-
getVars
- Returns:
- the variables in this IR.
-
getVarIndexer
- Returns:
- an indexer for the variables in this IR.
-
getStmt
- Returns:
- the i-th
Stmt
in this IR. The indexes start from 0.
-
getStmts
- Returns:
- a list of Stmts in this IR.
-
stmts
- Returns:
- a stream of Stmts in this IR.
-
invokes
Convenient method to obtain Invokes in this IR.- Parameters:
includeIndy
- whether include invokedynamic in the result.- Returns:
- a stream of Invokes in this IR.
-
iterator
-
getExceptionEntries
List<ExceptionEntry> getExceptionEntries()- Returns:
- the exception entries in this IR.
- See Also:
-