Class SimulationContext.Builder

  • Enclosing class:
    SimulationContext

    public static class SimulationContext.Builder
    extends Object
    Mutable builder for SimulationContext instances.
    • Constructor Detail

      • Builder

        public Builder()
    • Method Detail

      • classPool

        public SimulationContext.Builder classPool​(ClassPool classPool)
        Sets the class pool used to resolve classes and callees.
        Parameters:
        classPool - the class pool to use
        Returns:
        this builder
      • callGraph

        public SimulationContext.Builder callGraph​(CallGraph callGraph)
        Sets the call graph for inter-procedural resolution.
        Parameters:
        callGraph - the call graph to use
        Returns:
        this builder
      • maxCallDepth

        public SimulationContext.Builder maxCallDepth​(int maxCallDepth)
        Sets the maximum inter-procedural call depth.
        Parameters:
        maxCallDepth - the depth limit; 0 means intra-procedural only
        Returns:
        this builder
      • trackHeap

        public SimulationContext.Builder trackHeap​(boolean trackHeap)
        Sets whether heap allocations are tracked.
        Parameters:
        trackHeap - whether to track heap allocations
        Returns:
        this builder
      • trackValues

        public SimulationContext.Builder trackValues​(boolean trackValues)
        Sets whether value flow is tracked.
        Parameters:
        trackValues - whether to track value flow
        Returns:
        this builder
      • trackStackOperations

        public SimulationContext.Builder trackStackOperations​(boolean trackStackOperations)
        Sets whether stack operations are tracked.
        Parameters:
        trackStackOperations - whether to track stack operations
        Returns:
        this builder
      • build

        public SimulationContext build()
        Builds the immutable context from the current settings.
        Returns:
        a new SimulationContext