javax.resource.spi.work

Class WorkEvent

  • All Implemented Interfaces:
    Serializable

    public class WorkEvent
    extends EventObject
    This class models the various events that occur during the processing of a Work instance.
    Version:
    1.0
    Author:
    Ram Jeyaraman
    See Also:
    Serialized Form
    • Field Detail

      • WORK_ACCEPTED

        public static final int WORK_ACCEPTED
        Indicates Work instance has been accepted.
        See Also:
        Constant Field Values
      • WORK_REJECTED

        public static final int WORK_REJECTED
        Indicates Work instance has been rejected.
        See Also:
        Constant Field Values
      • WORK_STARTED

        public static final int WORK_STARTED
        Indicates Work instance has started execution.
        See Also:
        Constant Field Values
      • WORK_COMPLETED

        public static final int WORK_COMPLETED
        Indicates Work instance has completed execution.
        See Also:
        Constant Field Values
    • Constructor Detail

      • WorkEvent

        public WorkEvent(Object source,
                         int type,
                         Work work,
                         WorkException exc)
        Constructor.
        Parameters:
        source - The object on which the event initially occurred.
        type - The event type.
        work - The Work object on which the event occured.
        exc - The exception that occured during Work processing.
      • WorkEvent

        public WorkEvent(Object source,
                         int type,
                         Work work,
                         WorkException exc,
                         long startDuration)
        Constructor.
        Parameters:
        source - The object on which the event initially occurred.
        type - The event type.
        work - The Work object on which the event occured.
        exc - The exception that occured during Work processing.
        startDuration - The start delay duration (in milliseconds).
    • Method Detail

      • getType

        public int getType()
        Return the type of this event.
        Returns:
        the event type.
      • getWork

        public Work getWork()
        Return the Work instance which is the cause of the event.
        Returns:
        the Work instance.
      • getStartDuration

        public long getStartDuration()
        Return the start interval duration.
        Returns:
        the time elapsed (in milliseconds) since the Work was accepted, until the Work execution started. Note, this does not offer real-time guarantees. It is valid to return -1, if the actual start interval duration is unknown.
      • getException

        public WorkException getException()
        Return the WorkException. The actual WorkException subtype returned depends on the type of the event.
        Returns:
        a WorkRejectedException or a WorkCompletedException, if any.

Nederlandse vertaling

U hebt gevraagd om deze site in het Nederlands te bezoeken. Voor nu wordt alleen de interface vertaald, maar nog niet alle inhoud.

Als je me wilt helpen met vertalingen, is je bijdrage welkom. Het enige dat u hoeft te doen, is u op de site registreren en mij een bericht sturen waarin u wordt gevraagd om u toe te voegen aan de groep vertalers, zodat u de gewenste pagina's kunt vertalen. Een link onderaan elke vertaalde pagina geeft aan dat u de vertaler bent en heeft een link naar uw profiel.

Bij voorbaat dank.

Document heeft de 11/06/2005 gemaakt, de laatste keer de 18/08/2025 gewijzigd
Bron van het afgedrukte document:https://www.gaudry.be/nl/java-api-javaee-rf-javax/resource/spi/work/WorkEvent.html

De infobrol is een persoonlijke site waarvan de inhoud uitsluitend mijn verantwoordelijkheid is. De tekst is beschikbaar onder CreativeCommons-licentie (BY-NC-SA). Meer info op de gebruiksvoorwaarden en de auteur.

Referenties

  1. Bekijk - html-document Taal van het document:fr Manuel PHP : https://docs.oracle.com, WorkEvent (Java(TM) EE 7 Specification APIs)

Deze verwijzingen en links verwijzen naar documenten die geraadpleegd zijn tijdens het schrijven van deze pagina, of die aanvullende informatie kunnen geven, maar de auteurs van deze bronnen kunnen niet verantwoordelijk worden gehouden voor de inhoud van deze pagina.
De auteur van deze site is als enige verantwoordelijk voor de manier waarop de verschillende concepten, en de vrijheden die met de referentiewerken worden genomen, hier worden gepresenteerd. Vergeet niet dat u meerdere broninformatie moet doorgeven om het risico op fouten te verkleinen.