Package redempt.redlib.dev.profiler
Class BurstProfiler
java.lang.Object
redempt.redlib.dev.profiler.Profiler
redempt.redlib.dev.profiler.BurstProfiler
A profiler best used in bursts. Uses a lot of memory to profile even short periods of time,
 but allows you to select certain timeframes to inspect
- 
Constructor SummaryConstructorsConstructorDescriptionCreate a new BurstProfiler with a default size of 10,000 (10 seconds)BurstProfiler(int size) Create a new BurstProfiler with an initial size, being the number of milliseconds it will be able to record
- 
Method SummaryModifier and TypeMethodDescriptionprotected voidend()Gets a summary of the last X milliseconds of profiling, with X being the size this BurstProfiler was initialized withgetSummary(long after) Gets a summary of the profiling after the specified time.voidstart()Start this profiler.
- 
Constructor Details- 
BurstProfilerpublic BurstProfiler(int size) Create a new BurstProfiler with an initial size, being the number of milliseconds it will be able to record- Parameters:
- size- The size of the sample queue to create, 1ms = 1 element
 
- 
BurstProfilerpublic BurstProfiler()Create a new BurstProfiler with a default size of 10,000 (10 seconds)
 
- 
- 
Method Details- 
startpublic void start()Start this profiler. Must be run from the thread you intend to profile.
- 
endprotected void end()
- 
getSummaryGets a summary of the last X milliseconds of profiling, with X being the size this BurstProfiler was initialized with- Specified by:
- getSummaryin class- Profiler
- Returns:
- The summary
 
- 
getSummaryGets a summary of the profiling after the specified time. Cannot go back further than X milliseconds, with X being the size this BrustProfiler was initialized with- Parameters:
- after- The timestamp after which summary data should be included
- Returns:
- The summary
 
 
-