public final class StartUpMeasurer
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
StartUpMeasurer.Activities |
Modifier and Type | Field and Description |
---|---|
static long |
MEASURE_THRESHOLD |
static boolean |
measuringPluginStartupCosts |
static java.util.Map<java.lang.String,ObjectLongHashMap<java.lang.String>> |
pluginCostMap |
Constructor and Description |
---|
StartUpMeasurer() |
Modifier and Type | Method and Description |
---|---|
static long |
addCompletedActivity(long start,
java.lang.Class<?> clazz,
ActivityCategory category,
java.lang.String pluginId)
Default threshold is applied.
|
static long |
addCompletedActivity(long start,
java.lang.Class<?> clazz,
ActivityCategory category,
java.lang.String pluginId,
long threshold) |
static void |
addCompletedActivity(long start,
long end,
java.lang.String name,
ActivityCategory category,
java.lang.String pluginId) |
static long |
addCompletedActivity(long start,
java.lang.String name,
ActivityCategory category,
java.lang.String pluginId)
Default threshold is applied.
|
static void |
addInstantEvent(java.lang.String name)
The instant events correspond to something that happens but has no duration associated with it.
|
static void |
addPluginCost(java.lang.String pluginId,
java.lang.String phase,
long time) |
static void |
addTimings(java.util.LinkedHashMap<java.lang.String,java.lang.Long> timings,
java.lang.String groupName) |
static void |
compareAndSetCurrentState(LoadingState expectedState,
LoadingState newState) |
static void |
disable() |
static void |
doAddPluginCost(java.lang.String pluginId,
java.lang.String phase,
long time,
java.util.Map<java.lang.String,ObjectLongHashMap<java.lang.String>> pluginCostMap) |
static long |
getCurrentTime() |
static long |
getStartTime() |
static boolean |
isEnabled() |
static boolean |
isMeasuringPluginStartupCosts() |
static void |
processAndClear(boolean isContinueToCollect,
java.util.function.Consumer<? super ActivityImpl> consumer) |
static void |
setCurrentState(LoadingState state) |
static long |
sinceStart()
Since start in ms.
|
static Activity |
startActivity(java.lang.String name) |
static Activity |
startActivity(java.lang.String name,
ActivityCategory category) |
static Activity |
startActivity(java.lang.String name,
ActivityCategory category,
java.lang.String pluginId) |
static Activity |
startMainActivity(java.lang.String name) |
static void |
stopPluginCostMeasurement() |
public static final long MEASURE_THRESHOLD
public static boolean measuringPluginStartupCosts
public static final java.util.Map<java.lang.String,ObjectLongHashMap<java.lang.String>> pluginCostMap
public static void stopPluginCostMeasurement()
public static boolean isEnabled()
public static void disable()
public static long getCurrentTime()
public static long sinceStart()
public static void addInstantEvent(java.lang.String name)
public static Activity startActivity(java.lang.String name)
public static Activity startActivity(java.lang.String name, ActivityCategory category)
public static Activity startActivity(java.lang.String name, ActivityCategory category, java.lang.String pluginId)
public static Activity startMainActivity(java.lang.String name)
public static long addCompletedActivity(long start, java.lang.Class<?> clazz, ActivityCategory category, java.lang.String pluginId)
public static long addCompletedActivity(long start, java.lang.Class<?> clazz, ActivityCategory category, java.lang.String pluginId, long threshold)
public static long addCompletedActivity(long start, java.lang.String name, ActivityCategory category, java.lang.String pluginId)
public static void addCompletedActivity(long start, long end, java.lang.String name, ActivityCategory category, java.lang.String pluginId)
public static void setCurrentState(LoadingState state)
public static void compareAndSetCurrentState(LoadingState expectedState, LoadingState newState)
public static void processAndClear(boolean isContinueToCollect, java.util.function.Consumer<? super ActivityImpl> consumer)
public static long getStartTime()
public static void addTimings(java.util.LinkedHashMap<java.lang.String,java.lang.Long> timings, java.lang.String groupName)
public static void addPluginCost(java.lang.String pluginId, java.lang.String phase, long time)
public static boolean isMeasuringPluginStartupCosts()
public static void doAddPluginCost(java.lang.String pluginId, java.lang.String phase, long time, java.util.Map<java.lang.String,ObjectLongHashMap<java.lang.String>> pluginCostMap)