Class TaskEvent

    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int TASK_ERROR
      The task has produced an error.
      static int TASK_FINISHED
      The task has finished.
      static int TASK_INFO
      The task has produces an information.
      static int TASK_PROGRESS
      The task has progressed.
      static int TASK_STARTED
      The task has started.
      static int TASK_SUSPENDED
      The task is suspended.
      static int TASK_WARNING
      The task has produced a warning.
      • Fields inherited from class java.awt.AWTEvent

        ACTION_EVENT_MASK, ADJUSTMENT_EVENT_MASK, COMPONENT_EVENT_MASK, consumed, CONTAINER_EVENT_MASK, FOCUS_EVENT_MASK, HIERARCHY_BOUNDS_EVENT_MASK, HIERARCHY_EVENT_MASK, id, INPUT_METHOD_EVENT_MASK, INVOCATION_EVENT_MASK, ITEM_EVENT_MASK, KEY_EVENT_MASK, MOUSE_EVENT_MASK, MOUSE_MOTION_EVENT_MASK, MOUSE_WHEEL_EVENT_MASK, PAINT_EVENT_MASK, RESERVED_ID_MAX, TEXT_EVENT_MASK, WINDOW_EVENT_MASK, WINDOW_FOCUS_EVENT_MASK, WINDOW_STATE_EVENT_MASK
      • Fields inherited from class java.util.EventObject

        source
    • Constructor Summary

      Constructors 
      Constructor Description
      TaskEvent​(java.awt.AWTEvent event)
      Create a new task event.
      TaskEvent​(java.lang.Object source, int id)
      Create a new task event.
      TaskEvent​(java.lang.Object source, int id, int size)
      Create a new task event.
      TaskEvent​(java.lang.Object source, int id, java.lang.String name)
      Create a new task event.
      TaskEvent​(java.lang.Object source, int id, java.lang.String name, int size)
      Create a new task event.
      TaskEvent​(java.lang.Object source, int id, java.lang.String name, java.lang.String description)
      Create a new task event.
      TaskEvent​(java.lang.Object source, int id, java.lang.String name, java.lang.String description, int size)
      Create a new task event.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getDescription()
      Get the description of the task
      int getSize()
      Get the size of the task.
      java.lang.String getTaskName()
      Get the name of the task attached to this event
      • Methods inherited from class java.awt.AWTEvent

        consume, getID, isConsumed, paramString, setSource, toString
      • Methods inherited from class java.util.EventObject

        getSource
      • Methods inherited from class java.lang.Object

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

      • TASK_STARTED

        public static final int TASK_STARTED
        The task has started.
        See Also:
        Constant Field Values
      • TASK_PROGRESS

        public static final int TASK_PROGRESS
        The task has progressed.
        See Also:
        Constant Field Values
      • TASK_SUSPENDED

        public static final int TASK_SUSPENDED
        The task is suspended.
        See Also:
        Constant Field Values
      • TASK_FINISHED

        public static final int TASK_FINISHED
        The task has finished.
        See Also:
        Constant Field Values
      • TASK_WARNING

        public static final int TASK_WARNING
        The task has produced a warning.
        See Also:
        Constant Field Values
      • TASK_ERROR

        public static final int TASK_ERROR
        The task has produced an error.
        See Also:
        Constant Field Values
      • TASK_INFO

        public static final int TASK_INFO
        The task has produces an information.
        See Also:
        Constant Field Values
    • Constructor Detail

      • TaskEvent

        public TaskEvent​(java.lang.Object source,
                         int id)
        Create a new task event.
        Parameters:
        source - the source (task) of the event.
        id - the identifier of the task.
      • TaskEvent

        public TaskEvent​(java.awt.AWTEvent event)
        Create a new task event.
        Parameters:
        event - the original event to copy.
      • TaskEvent

        public TaskEvent​(java.lang.Object source,
                         int id,
                         java.lang.String name)
        Create a new task event.
        Parameters:
        source - the source (task) of the event.
        id - the identifier of the task.
        name - the name of the task.
      • TaskEvent

        public TaskEvent​(java.lang.Object source,
                         int id,
                         java.lang.String name,
                         java.lang.String description)
        Create a new task event.
        Parameters:
        source - the source (task) of the event.
        id - the identifier of the task.
        name - the name of the task.
        description - the description of the event.
      • TaskEvent

        public TaskEvent​(java.lang.Object source,
                         int id,
                         int size)
        Create a new task event.
        Parameters:
        source - the source (task) of the event.
        id - the identifier of the task.
        size - the size of the event in case of progress monitoring. If the event is TASK_STARTED, the size is the size of the task. If the event is TASK_PROGRESS, the size is the actually accomplished part of the task.
      • TaskEvent

        public TaskEvent​(java.lang.Object source,
                         int id,
                         java.lang.String name,
                         int size)
        Create a new task event.
        Parameters:
        source - the source (task) of the event.
        id - the identifier of the task.
        name - the name of the task.
        size - the size of the event in case of progress monitoring. If the event is TASK_STARTED, the size is the size of the task. If the event is TASK_PROGRESS, the size is the actually accomplished part of the task.
      • TaskEvent

        public TaskEvent​(java.lang.Object source,
                         int id,
                         java.lang.String name,
                         java.lang.String description,
                         int size)
        Create a new task event.
        Parameters:
        source - the source (task) of the event.
        id - the identifier of the task.
        name - the name of the task.
        description - the description of the event.
        size - the size of the event in case of progress monitoring. If the event is TASK_STARTED, the size is the size of the task. If the event is TASK_PROGRESS, the size is the actually accomplished part of the task.
    • Method Detail

      • getTaskName

        public java.lang.String getTaskName()
        Get the name of the task attached to this event
        Returns:
        String the name of the task attached to this event
      • getDescription

        public java.lang.String getDescription()
        Get the description of the task
        Returns:
        String the description of the task
      • getSize

        public int getSize()
        Get the size of the task.
        Returns:
        int the size of the task