Class TrackerViewFactory

java.lang.Object
com.arc_e_tect.gradle.trackerlens.dashboard.TrackerViewFactory

public class TrackerViewFactory extends Object
Builds a TrackerView from a tracker's raw records, ready for DashboardHtmlWriter to render.
  • Constructor Details

    • TrackerViewFactory

      public TrackerViewFactory()
      Creates a new TrackerViewFactory.
  • Method Details

    • build

      public TrackerView build(String trackerId, List<String> stages, List<LifecycleRecord> records, Optional<Projection> projection, Instant now, boolean stagesFormADependencyChain)
      Builds the view for one tracker.
      Parameters:
      trackerId - the tracker's registered id
      stages - the tracker's canonical stage names, in order
      records - the tracker's records
      projection - the tracker's completion projection, if available
      now - the instant to render as of
      stagesFormADependencyChain - whether an item can only reach a later stage by having already passed through every earlier one, e.g. Gherkin scenarios (true). When true, metric card counts are each item's single current stage (mutually exclusive, summing to the total). When false, e.g. API contracts, stages are independent conditions an item may reach in any combination, so metric card counts stay cumulative "reached at least this stage" counts.
      Returns:
      the built view