Class CFGEdge<N>

java.lang.Object
pascal.taie.util.graph.AbstractEdge<N>
pascal.taie.analysis.graph.cfg.CFGEdge<N>
Type Parameters:
N - type of CFG nodes.
All Implemented Interfaces:
Serializable, Edge<N>

public class CFGEdge<N> extends AbstractEdge<N>
Represents CFG edges.
See Also:
  • Method Details

    • getKind

      public CFGEdge.Kind getKind()
      Returns:
      the kind of the edge.
      See Also:
    • isSwitchCase

      public boolean isSwitchCase()
      Returns:
      true if this edge is a switch-case edge, otherwise false.
    • getCaseValue

      public int getCaseValue()
      If this edge is a switch-case edge, then returns the case value. The client code should call isSwitchCase() to check if this edge is switch-case edge before calling this method.
      Throws:
      AnalysisException - if this edge is not a switch-case edge.
    • isExceptional

      public boolean isExceptional()
      Returns:
      true if this edge is an exceptional edge, otherwise false.
    • getExceptions

      public Set<ClassType> getExceptions()
      If this edge is an exceptional edge, return the exception types along with this edge, otherwise return an empty set.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class AbstractEdge<N>
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class AbstractEdge<N>
    • toString

      public String toString()
      Overrides:
      toString in class AbstractEdge<N>