Class StatEdge
- java.lang.Object
-
- org.jetbrains.java.decompiler.modules.decompiler.StatEdge
-
public class StatEdge extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description booleancanInlineStatementclosurebooleanexplicitbooleanlabeledbooleanphantomContinuestatic intTYPE_BREAKstatic intTYPE_CONTINUEstatic intTYPE_EXCEPTIONstatic intTYPE_FINALLYEXITstatic intTYPE_REGULARstatic int[]TYPES
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidchangeDestination(Statement newDestination)Makes this edge point from a different destination.voidchangeSource(Statement newSource)Makes this edge point from a different source.voidchangeType(int type)Updates the type of this edge.StatementgetDestination()java.util.List<java.lang.String>getExceptions()StatementgetSource()intgetType()voidremove()Removes this edge from the graph.voidremoveClosure()Remove the closure of this edge.voidsetDestination(Statement destination)voidsetSource(Statement source)voidsetType(int type)java.lang.StringtoString()
-
-
-
Field Detail
-
TYPE_REGULAR
public static final int TYPE_REGULAR
- See Also:
- Constant Field Values
-
TYPE_EXCEPTION
public static final int TYPE_EXCEPTION
- See Also:
- Constant Field Values
-
TYPE_BREAK
public static final int TYPE_BREAK
- See Also:
- Constant Field Values
-
TYPE_CONTINUE
public static final int TYPE_CONTINUE
- See Also:
- Constant Field Values
-
TYPE_FINALLYEXIT
public static final int TYPE_FINALLYEXIT
- See Also:
- Constant Field Values
-
TYPES
public static final int[] TYPES
-
closure
public Statement closure
-
labeled
public boolean labeled
-
explicit
public boolean explicit
-
canInline
public boolean canInline
-
phantomContinue
public boolean phantomContinue
-
-
Method Detail
-
getType
public int getType()
-
setType
public void setType(int type)
-
getSource
public Statement getSource()
-
setSource
public void setSource(Statement source)
-
changeSource
public void changeSource(Statement newSource)
Makes this edge point from a different source. This will remove this edge as a successor of the old source, add it as a successor of the new source, and update the predecessor of the current destination.- Parameters:
newSource- the new source of this edge
-
getDestination
public Statement getDestination()
-
setDestination
public void setDestination(Statement destination)
-
changeDestination
public void changeDestination(Statement newDestination)
Makes this edge point from a different destination. This will remove this edge as a predecessor of the old destination, add it as a predecessor of the new destination, and update the successor of the current source.- Parameters:
newDestination- the new destination of this edge
-
changeType
public void changeType(int type)
Updates the type of this edge. It will notify both the source and the destination of the change.- Parameters:
type-
-
remove
public void remove()
Removes this edge from the graph. The source will lose this edge as a successor, the destination will lose this edge as a predecessor. and if there is a labeled closure, it will be removed from there as well.
-
removeClosure
public void removeClosure()
Remove the closure of this edge. This edge will no longer be labeled.
-
getExceptions
public java.util.List<java.lang.String> getExceptions()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-