@ Override public TimelineSample < StopwatchTimeRange > sample ( ) { StopwatchTimeRange [ ] timeRangesCopy ; synchronized ( this ) { timeRangesCopy = timeRanges . toArray ( new StopwatchTimeRange [ timeRanges . size ( ) ] ) ; } // TODO sample each time-range by making a copy of it return new TimelineSample <> ( timeRanges . getCapacity ( ) , timeRangeWidth * SimonClock . NANOS_IN_MILLIS , timeRangesCopy ) ; }
Take a snapshot of the timeline .