Class CallGraphNode
- java.lang.Object
-
- it.unive.lisa.interprocedural.callgraph.CallGraphNode
-
- All Implemented Interfaces:
Node<BaseCallGraph,CallGraphNode,CallGraphEdge>
public class CallGraphNode extends java.lang.Object implements Node<BaseCallGraph,CallGraphNode,CallGraphEdge>
A node of aBaseCallGraph
, representing a singleCodeMember
.
-
-
Constructor Summary
Constructors Constructor Description CallGraphNode(BaseCallGraph graph, CodeMember cm)
Builds the node.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <V> boolean
accept(GraphVisitor<BaseCallGraph,CallGraphNode,CallGraphEdge,V> visitor, V tool)
Accepts the givenGraphVisitor
.boolean
equals(java.lang.Object obj)
CodeMember
getCodeMember()
Yields theCodeMember
represented by this node.BaseCallGraph
getGraph()
Yields the parentBaseCallGraph
containing this node.int
hashCode()
java.lang.String
toString()
-
-
-
Constructor Detail
-
CallGraphNode
public CallGraphNode(BaseCallGraph graph, CodeMember cm)
Builds the node.- Parameters:
graph
- the parent graphcm
- the code member represented by this node
-
-
Method Detail
-
getCodeMember
public CodeMember getCodeMember()
Yields theCodeMember
represented by this node.- Returns:
- the code member
-
getGraph
public BaseCallGraph getGraph()
Yields the parentBaseCallGraph
containing this node.- Returns:
- the parent graph
-
accept
public <V> boolean accept(GraphVisitor<BaseCallGraph,CallGraphNode,CallGraphEdge,V> visitor, V tool)
Description copied from interface:Node
Accepts the givenGraphVisitor
. Implementors of this method are responsible for invokingGraphVisitor.visit(Object, Graph, Node)
on this node afterNode.accept(GraphVisitor, Object)
has been invoked on all nested nodes, if any. The visiting should stop at the first of such calls that returnfalse
.- Specified by:
accept
in interfaceNode<BaseCallGraph,CallGraphNode,CallGraphEdge>
- Type Parameters:
V
- the type of auxiliary tool thatvisitor
can use- Parameters:
visitor
- the visitor that is visiting theGraph
containing this nodetool
- the auxiliary tool thatvisitor
can use- Returns:
- whether or not the visiting should stop when this call returns, as decided by the visitor itself
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-