org.eclipse.net4j.util.concurrent

## Class SerializingExecutor

- java.lang.Object
- - org.eclipse.net4j.util.event.Notifier
  - - org.eclipse.net4j.util.lifecycle.Lifecycle
    - - org.eclipse.net4j.util.concurrent.SerializingExecutor

- All Implemented Interfaces:
    java.lang.Runnable, java.util.concurrent.Executor, INotifier, IDeactivateable, ILifecycle, ILifecycle.DeferrableActivation

      public class SerializingExecutor
      extends Lifecycle
      implements java.util.concurrent.Executor, java.lang.Runnable

  Since:
    3.9
  Author:
    Eike Stepper

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface org.eclipse.net4j.util.lifecycle.ILifecycle

      `ILifecycle.DeferrableActivation`

  - ### Field Summary

    - ### Fields inherited from class org.eclipse.net4j.util.lifecycle.Lifecycle

      `USE_LABEL`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SerializingExecutor()`
    `SerializingExecutor(java.util.concurrent.Executor delegate)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `doActivate()`
    `protected void` | `doDeactivate()`
    `void` | `execute(java.lang.Runnable task)`
    `java.util.concurrent.Executor` | `getDelegate()`
    `protected void` | `handleFailedTask(java.lang.Runnable task, java.lang.Throwable failure)`
    `void` | `run()`
    `void` | `setDelegate(java.util.concurrent.Executor delegate)`

    - ### Methods inherited from class org.eclipse.net4j.util.lifecycle.Lifecycle

      `activate, checkActive, checkArg, checkArg, checkInactive, checkNull, checkState, checkState, deactivate, deferredActivate, doAfterActivate, doBeforeActivate, doBeforeDeactivate, dump, getLifecycleState, isActive, isDeferredActivation, toString`

    - ### Methods inherited from class org.eclipse.net4j.util.event.Notifier

      `addListener, fireEvent, fireEvent, fireEvent, fireThrowable, firstListenerAdded, getListeners, getNotificationService, hasListeners, lastListenerRemoved, removeListener`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface org.eclipse.net4j.util.event.INotifier

      `addListener, getListeners, hasListeners, removeListener`

- - ### Constructor Detail

    - #### SerializingExecutor

          public SerializingExecutor(java.util.concurrent.Executor delegate)

    - #### SerializingExecutor

          public SerializingExecutor()

  - ### Method Detail

    - #### getDelegate

          public final java.util.concurrent.Executor getDelegate()

    - #### setDelegate

          public final void setDelegate(java.util.concurrent.Executor delegate)

    - #### execute

          public final void execute(java.lang.Runnable task)

      Specified by:
        `execute` in interface `java.util.concurrent.Executor`

    - #### run

          public final void run()

      Specified by:
        `run` in interface `java.lang.Runnable`

    - #### handleFailedTask

          protected void handleFailedTask(java.lang.Runnable task,
                                          java.lang.Throwable failure)

    - #### doActivate

          protected void doActivate()
                             throws java.lang.Exception

      Overrides:
        `doActivate` in class `Lifecycle`
      Throws:
        `java.lang.Exception`

    - #### doDeactivate

          protected void doDeactivate()
                               throws java.lang.Exception

      Overrides:
        `doDeactivate` in class `Lifecycle`
      Throws:
        `java.lang.Exception`

Copyright (c) 2004-2019 Eike Stepper (Loehne, Germany) and others.
All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html