public class TimelineCallback extends CallbackSkeleton
Callback.Event| Modifier and Type | Field and Description |
|---|---|
static String |
TIMELINE_ATTRIBUTE_NAME
Default attribute name for storing timelines.
|
| Constructor and Description |
|---|
TimelineCallback()
Constructor using default attribute name, default timeline capacity of 6
and default timeline width of 10 minutes.
|
TimelineCallback(int timelineCapacity,
long timeRangeWidth)
Constructor using default attribute name.
|
TimelineCallback(String timelineAttributeName,
int timelineCapacity,
long timeRangeWidth)
Main constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
onSimonCreated(Simon simon)
On simon creation a timeline attribute is added (for Stopwatches only).
|
void |
onStopwatchAdd(Stopwatch stopwatch,
Split split,
StopwatchSample sample)
Stopwatch add split event.
|
void |
onStopwatchStop(Split split,
StopwatchSample sample)
Stopwatch stop event.
|
cleanup, initialize, onCounterDecrease, onCounterIncrease, onCounterSet, onManagerClear, onManagerMessage, onManagerWarning, onSimonDestroyed, onStopwatchStartpublic static final String TIMELINE_ATTRIBUTE_NAME
public TimelineCallback(String timelineAttributeName, int timelineCapacity, long timeRangeWidth)
timelineAttributeName - Simon attribute name used for storing TimelinetimelineCapacity - Timeline capacity (number of time ranges)timeRangeWidth - Time range width (in milliseconds)public TimelineCallback(int timelineCapacity, long timeRangeWidth)
timelineCapacity - Timeline capacity (number of time ranges)timeRangeWidth - Time range width (in milliseconds)public TimelineCallback()
public void onSimonCreated(Simon simon)
onSimonCreated in interface CallbackonSimonCreated in class CallbackSkeletonsimon - created simonpublic void onStopwatchAdd(Stopwatch stopwatch, Split split, StopwatchSample sample)
CallbackStopwatchSample valid for the moment after the add is provided
because the callback is executed out of synchronized block.
It is guaranteed that Split.getStopwatch() will not return null.onStopwatchAdd in interface CallbackonStopwatchAdd in class CallbackSkeletonstopwatch - modified Stopwatchsplit - added split objectsample - stopwatch sampled after the addpublic void onStopwatchStop(Split split, StopwatchSample sample)
CallbackStopwatchSample valid for the moment after the stop is provided
because the callback is executed out of synchronized block.
It is guaranteed that Split.getStopwatch() will not return null.onStopwatchStop in interface CallbackonStopwatchStop in class CallbackSkeletonsplit - stopped Splitsample - stopwatch sampled after the stopCopyright © 2019. All rights reserved.