fabric.worker.debug
Enum Timing

java.lang.Object
  extended by java.lang.Enum<Timing>
      extended by fabric.worker.debug.Timing
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<Timing>

public enum Timing
extends java.lang.Enum<Timing>

A utility class for recording the timing of various categories.


Enum Constant Summary
APP
           
BEGIN
           
COMMIT
           
FETCH
           
STORE
           
SUBTX
           
TXLOG
           
 
Field Summary
 boolean enabled
          Whether or not to record time for this category
 
Method Summary
 void begin()
          Begin recording time into the given category (exclusively)
 void end()
          Stop recording time into the given category, and begin recording to the former category.
static void main(java.lang.String[] args)
           
static void printStats()
          Print a summary of the time spent in each category to standard output.
static void printStats(java.io.PrintStream out)
          Print a summary of the time spent in each category to the provided OutputStream
static void reset()
          Reset all of the statistics, and begin timing in cat
static Timing valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static Timing[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

APP

public static final Timing APP

BEGIN

public static final Timing BEGIN

COMMIT

public static final Timing COMMIT

TXLOG

public static final Timing TXLOG

SUBTX

public static final Timing SUBTX

FETCH

public static final Timing FETCH

STORE

public static final Timing STORE
Field Detail

enabled

public boolean enabled
Whether or not to record time for this category

Method Detail

values

public static Timing[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (Timing c : Timing.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static Timing valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null

begin

public void begin()
Begin recording time into the given category (exclusively)


end

public void end()
Stop recording time into the given category, and begin recording to the former category.


printStats

public static void printStats()
Print a summary of the time spent in each category to standard output.


printStats

public static void printStats(java.io.PrintStream out)
Print a summary of the time spent in each category to the provided OutputStream


reset

public static void reset()
Reset all of the statistics, and begin timing in cat


main

public static void main(java.lang.String[] args)