Class DefaultStatusEvent

  • All Implemented Interfaces:
    ProgressEvent, StatusEvent

    public class DefaultStatusEvent
    extends java.lang.Object
    implements StatusEvent
    Base implementation of the StatusEvent interface.
    • Constructor Summary

      Constructors 
      Constructor Description
      DefaultStatusEvent​(long eventTime, java.lang.String displayName, OperationDescriptor descriptor, long total, long progress, java.lang.String unit)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      OperationDescriptor getDescriptor()
      Returns the description of the operation for which progress is reported.
      java.lang.String getDisplayName()
      Returns a human consumable short description of the event.
      long getEventTime()
      Returns the time this event was triggered.
      long getProgress()
      The amount of work already performed by the build operation.
      long getTotal()
      The total amount of work that the build operation is in the progress of performing, or -1 if not known.
      java.lang.String getUnit()
      The measure used to express the amount of work.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

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

      • DefaultStatusEvent

        public DefaultStatusEvent​(long eventTime,
                                  java.lang.String displayName,
                                  OperationDescriptor descriptor,
                                  long total,
                                  long progress,
                                  java.lang.String unit)
    • Method Detail

      • getProgress

        public long getProgress()
        Description copied from interface: StatusEvent
        The amount of work already performed by the build operation.
        Specified by:
        getProgress in interface StatusEvent
        Returns:
        The amount of performed work
      • getTotal

        public long getTotal()
        Description copied from interface: StatusEvent
        The total amount of work that the build operation is in the progress of performing, or -1 if not known.
        Specified by:
        getTotal in interface StatusEvent
        Returns:
        The total amount of work, or -1 if not known.
      • getUnit

        public java.lang.String getUnit()
        Description copied from interface: StatusEvent
        The measure used to express the amount of work.
        Specified by:
        getUnit in interface StatusEvent
        Returns:
        The measure used to express the amount of work.
      • getEventTime

        public long getEventTime()
        Description copied from interface: ProgressEvent
        Returns the time this event was triggered.
        Specified by:
        getEventTime in interface ProgressEvent
        Returns:
        The event time, in milliseconds since the epoch.
      • getDisplayName

        public java.lang.String getDisplayName()
        Description copied from interface: ProgressEvent
        Returns a human consumable short description of the event.
        Specified by:
        getDisplayName in interface ProgressEvent
        Returns:
        The short description of the event.
      • toString

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