Interface NodeManager<T>

Type Parameters:
T - the type of nodes this NodeManager tracks.
All Superinterfaces:
Iterable<T>
All Known Subinterfaces:
CallGraph, ControlFlowGraph<I,T>, Graph<T>, HeapGraph<T>, IFlowGraph, ISDG, ISupergraph<T,P>, LabeledGraph<T,U>, MinimalCFG<T>, NumberedGraph<T>, NumberedLabeledGraph<T,I>, NumberedNodeManager<T>, OrderedMultiGraph<T>, SerializableGraph<T>
All Known Implementing Classes:
AbstractCFG, AbstractDemandFlowGraph, AbstractFlowGraph, AbstractGraph, AbstractInterproceduralCFG, AbstractLabeledGraph, AbstractNumberedGraph, AbstractNumberedLabeledGraph, AstCallGraph, AstInducedCFG, AstTranslator.AstCFG, AstTranslator.IncipientCFG, BackwardsSupergraph, BasicCallGraph, BasicGraph, BasicHeapGraph, BasicNodeManager, BasicOrderedMultiGraph, CHACallGraph, CISDG, ControlDependenceGraph, CrossLanguageCallGraph, DelegatingCFG, DelegatingExplicitCallGraph, DelegatingGraph, DelegatingNumberedGraph, DelegatingNumberedNodeManager, DemandPointerFlowGraph, DemandValueFlowGraph, DexCFG, EdgeFilteredNumberedGraph, ExplicitCallGraph, ExplodedControlFlowGraph, ExplodedInterproceduralCFG, ExtensionGraph, HeapGraphImpl, ICFGSupergraph, InducedCFG, InterproceduralCFG, InvertedGraph, InvertedNumberedGraph, JSCallGraph, JSInducedCFG, MutableCFG, PartialCallGraph, PDG, PrefixTransferGraph, PrunedCallGraph, PrunedCFG, RandomGraph, RandomGraph.IntegerRandomGraph, SDG, SelfLoopAddedGraph, ShrikeCFG, SimpleDemandPointerFlowGraph, SlowNumberedNodeManager, SlowSparseNumberedGraph, SlowSparseNumberedLabeledGraph, SparseNumberedGraph, SSACFG, UriPrefixTransferGraph

public interface NodeManager<T> extends Iterable<T>
An object which tracks graph nodes.

This is effectively a stripped-down collection interface. We choose to avoid using the full Collection interface, so that it takes less code to implement a new NodeManager.

  • Method Details

    • iterator

      default Iterator<T> iterator()
      Specified by:
      iterator in interface Iterable<T>
      Returns:
      an Iterator of the nodes in this graph
    • stream

      Stream<T> stream()
      Returns:
      a Stream of the nodes in this graph
    • getNumberOfNodes

      int getNumberOfNodes()
      Returns:
      the number of nodes in this graph
    • addNode

      void addNode(T n)
      add a node to this graph
    • removeNode

      void removeNode(T n) throws UnsupportedOperationException
      remove a node from this graph
      Throws:
      UnsupportedOperationException
    • containsNode

      boolean containsNode(@Nullable T n)
      Returns:
      true iff the graph contains the specified node