Class ObjectTimings<T>

java.lang.Object
net.neoforged.neoforge.server.timings.ObjectTimings<T>
Type Parameters:
T -

public class ObjectTimings<T> extends Object
ObjectTimings aggregates timings data collected by TimeTracker for an Object and performs operations for interpretation of the data.
  • Field Details

    • object

      private WeakReference<T> object
    • rawTimingData

      private int[] rawTimingData
  • Constructor Details

    • ObjectTimings

      public ObjectTimings(T object, int[] rawTimingData)
  • Method Details

    • getObject

      public WeakReference<T> getObject()
      Retrieves the object that the timings are for
      Returns:
      The object
    • getAverageTimings

      public double getAverageTimings()
      Averages the raw timings data collected
      Returns:
      An average of the raw timing data