Class ControlLoadSnapshot


  • public class ControlLoadSnapshot
    extends java.lang.Object
    A container class that is used to wrap the control metric response.
    • Constructor Summary

      Constructors 
      Constructor Description
      ControlLoadSnapshot​(long latest, long average, long time)
      Instantiates a new control metric response with given latest, average, time.
      ControlLoadSnapshot​(long latest, long average, long time, long[] recent)
      Instantiates a new control metric response with given latest, average, time, recent values.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      long average()
      Returns average value of control metric.
      boolean equals​(java.lang.Object obj)  
      int hashCode()  
      long latest()
      Returns latest value of control metric.
      long[] recent()
      Returns a set of historical recent of control metric.
      long time()
      Returns last logging time of control metric.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • ControlLoadSnapshot

        public ControlLoadSnapshot​(long latest,
                                   long average,
                                   long time)
        Instantiates a new control metric response with given latest, average, time.
        Parameters:
        latest - latest value of control metric
        average - average value of control metric
        time - last logging time of control metric
      • ControlLoadSnapshot

        public ControlLoadSnapshot​(long latest,
                                   long average,
                                   long time,
                                   long[] recent)
        Instantiates a new control metric response with given latest, average, time, recent values.
        Parameters:
        latest - latest value of control metric
        average - average value of control metric
        time - last logging time of control metric
        recent - a set of historical data
    • Method Detail

      • latest

        public long latest()
        Returns latest value of control metric.
        Returns:
        latest value of control metric
      • time

        public long time()
        Returns last logging time of control metric.
        Returns:
        last logging time of control metric
      • average

        public long average()
        Returns average value of control metric.
        Returns:
        average value of control metric
      • recent

        public long[] recent()
        Returns a set of historical recent of control metric.
        Returns:
        a set of historical recent of control metric
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object