Class MetricsRootAction.Sampler.Sample

java.lang.Object
jenkins.metrics.api.MetricsRootAction.Sampler.Sample
Enclosing class:
MetricsRootAction.Sampler

public static class MetricsRootAction.Sampler.Sample extends Object
A sample.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Sample(long t, byte[] v)
    Constructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    Gets the time the sample was taken.
    com.fasterxml.jackson.databind.JsonNode
    getValue(com.fasterxml.jackson.databind.ObjectReader reader)
    Gets the JSON from the sample.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Sample

      public Sample(long t, @NonNull byte[] v)
      Constructor.
      Parameters:
      t - the time of the sample.
      v - the compressed JSON bytes.
  • Method Details

    • getTime

      @NonNull public Date getTime()
      Gets the time the sample was taken.
      Returns:
      the time the sample was taken.
    • getValue

      @CheckForNull public com.fasterxml.jackson.databind.JsonNode getValue(@NonNull com.fasterxml.jackson.databind.ObjectReader reader)
      Gets the JSON from the sample.
      Parameters:
      reader - the ObjectReader to use.
      Returns:
      the JSON.