Package loci.common

Class StatusEvent


  • public class StatusEvent
    extends Object
    An event indicating a status update.
    • Field Detail

      • progress

        protected int progress
        Current progress value.
      • maximum

        protected int maximum
        Current progress maximum.
      • status

        protected String status
        Current status message.
      • warning

        protected boolean warning
        Whether or not this is a warning event.
    • Constructor Detail

      • StatusEvent

        public StatusEvent​(String message)
        Constructs a non-warning status event. The initial progress and maximum progress are set to -1.
        Parameters:
        message - the initial status message
      • StatusEvent

        public StatusEvent​(String message,
                           boolean warn)
        Constructs a status event. The initial progress and maximum progress are set to -1.
        Parameters:
        message - the initial status message
        warn - true if this is a warning event
      • StatusEvent

        public StatusEvent​(int progress,
                           int maximum,
                           String message)
        Constructs a non-warning status event.
        Parameters:
        progress - the current progress value
        maximum - the maximum progress value
        message - the initial status message
      • StatusEvent

        public StatusEvent​(int progress,
                           int maximum,
                           String message,
                           boolean warn)
        Constructs a status event.
        Parameters:
        progress - the current progress value
        maximum - the maximum progress value
        message - the initial status message
        warn - true if this is a warning event
    • Method Detail

      • getProgressValue

        public int getProgressValue()
        Returns:
        the progress value. Returns -1 if progress is unknown.
      • getProgressMaximum

        public int getProgressMaximum()
        Returns:
        progress maximum. Returns -1 if progress is unknown.
      • getStatusMessage

        public String getStatusMessage()
        Returns:
        status message.
      • isWarning

        public boolean isWarning()
        Returns:
        true if this is a warning event.