package dev.dtrentin.chart.demo import java.util.concurrent.atomic.AtomicLong /** * Thread-safe monotonic counter incremented on every `state.push(...)` from the * synthetic generator. Used by the status panel to report push throughput and total * sample count (library does not expose `dataVersion` as public API). */ class PushCounter { private val n = AtomicLong(0L) fun increment() { n.incrementAndGet() } fun get(): Long = n.get() fun reset() { n.set(0L) } }