Package org.spigotmc
Class CustomTimingsHandler
- java.lang.Object
-
- org.spigotmc.CustomTimingsHandler
-
public class CustomTimingsHandler extends Object
Provides custom timing sections for /timings merged.
-
-
Constructor Summary
Constructors Constructor Description CustomTimingsHandler(@NotNull String name)CustomTimingsHandler(@NotNull String name, @Nullable CustomTimingsHandler parent)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static voidprintTimings(@NotNull PrintStream printStream)Prints the timings and extra data to the given stream.static voidreload()Resets all timings.voidreset()Reset this timer, setting all values to zero.voidstartTiming()Starts timing to track a section of code.voidstopTiming()Stops timing a section of code.static voidtick()Ticked every tick by CraftBukkit to count the number of times a timer caused TPS loss.
-
-
-
Constructor Detail
-
CustomTimingsHandler
public CustomTimingsHandler(@NotNull @NotNull String name)
-
CustomTimingsHandler
public CustomTimingsHandler(@NotNull @NotNull String name, @Nullable @Nullable CustomTimingsHandler parent)
-
-
Method Detail
-
printTimings
public static void printTimings(@NotNull @NotNull PrintStream printStream)Prints the timings and extra data to the given stream.- Parameters:
printStream- output stream
-
reload
public static void reload()
Resets all timings.
-
tick
public static void tick()
Ticked every tick by CraftBukkit to count the number of times a timer caused TPS loss.
-
startTiming
public void startTiming()
Starts timing to track a section of code.
-
stopTiming
public void stopTiming()
Stops timing a section of code.
-
reset
public void reset()
Reset this timer, setting all values to zero.
-
-