com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICMethod |
C AST method objects are top-level AST objects that can be retrieved by a
ICMethodFactory
.
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From interface
com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICDecompilableElement
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
abstract void | addParameter(int index, ICDecl param) | ||||||||||
abstract void | addParameter(ICDecl param) | ||||||||||
abstract void | addStatement(ICStatement stm) | ||||||||||
abstract boolean |
deleteStatement(ICStatement stm)
Delete a statement by reference.
| ||||||||||
abstract ICMethod |
duplicate()
Deep duplication of the element.
| ||||||||||
abstract void |
fromFlatList(List<ICStatement> list)
Regenerate the AST of this method based on a flat list of statements and pseudo-statements.
| ||||||||||
abstract void | generateName(COutputSink out, boolean definition) | ||||||||||
abstract ICBlock | getBody() | ||||||||||
abstract ICType | getClassType() | ||||||||||
abstract ICIdentifierManager |
getIdentifierManager()
Retrieve this method's identifier manager (local variable factory).
| ||||||||||
abstract ICLabelFactory |
getLabelFactory()
Retrieve this method's label factory.
| ||||||||||
abstract ICStatement | getLastStatement() | ||||||||||
abstract String | getName() | ||||||||||
abstract List<ICDecl> | getParameters() | ||||||||||
abstract ICType |
getReturnType()
Retrieve the primary return type, or the void type if this method does not return anything.
| ||||||||||
abstract List<ICType> | getReturnTypes() | ||||||||||
abstract List<ICStatement> |
getStatements()
Walk the tree and get the ordered list of all (non-pseudo) statements that make up the
method.
| ||||||||||
abstract boolean | insertAtOffset(long offset, ICStatement stm) | ||||||||||
abstract boolean | isEmpty() | ||||||||||
abstract void | removeParameter(int index) | ||||||||||
abstract List<ICStatement> |
toFlatList()
Flatten the abstract syntax tree.
| ||||||||||
abstract boolean |
visitStatements(ICVisitor visitor)
Visit all
statements of the method's body recursively. |
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From interface
com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICDecompilableElement
| |||||||||||
From interface
com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICElement
| |||||||||||
From interface
com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICSourceElement
| |||||||||||
From interface
com.pnfsoftware.jeb.core.units.code.asm.decompiler.opt.IOptimizerTarget
|
Delete a statement by reference.
stm | the statement to delete |
---|
Deep duplication of the element. Sub-elements are duplicated.
Note: ICClass
, ICMethod
, ICField
, ICIdentifier
,
ICConstant
, ICType
and ICLabel
are not duplicated.
Regenerate the AST of this method based on a flat list of statements and pseudo-statements.
list | the list of all statements (including pseudo-statements) that make up the method |
---|
Retrieve this method's identifier manager (local variable factory).
Retrieve the primary return type, or the void type if this method does not return anything.
The primary return type, if not void, is the first element returned by
getReturnTypes()
.
Walk the tree and get the ordered list of all (non-pseudo) statements that make up the method.
Flatten the abstract syntax tree. The returned list contains extra statements, called
"pseudo-statements", needed to represent the structure of the method.
In programmer's words, all statements implementing ICoumpound in the AST are replaced by two
or more appropriate objects deriving from PseudoStatement.
Visit all statements
of the method's body recursively. This method
differs from getStatements()
, which simply returns the list of statements contained
in the body, but not the statements contained in the statements.
visitor | a visitor object |
---|