org.eclipse.net4j.util.om.monitor

## Class DelegatingMonitor

- java.lang.Object
- - org.eclipse.net4j.util.om.monitor.DelegatingMonitor

- All Implemented Interfaces:
    OMMonitor, OMMonitorProgress

      public class DelegatingMonitor
      extends java.lang.Object
      implements OMMonitor

  Since:
    2.0
  Author:
    Eike Stepper

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface org.eclipse.net4j.util.om.monitor.OMMonitor

      `OMMonitor.Async`

  - ### Field Summary

    - ### Fields inherited from interface org.eclipse.net4j.util.om.monitor.OMMonitor

      `DEFAULT_TIME_FACTOR, THOUSAND`

    - ### Fields inherited from interface org.eclipse.net4j.util.om.monitor.OMMonitorProgress

      `HUNDRED, ONE, TEN, ZERO`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `DelegatingMonitor(OMMonitor delegate)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `OMMonitor` | `begin()` Same as calling `begin(ONE)`.
    `OMMonitor` | `begin(double totalWork)`
    `void` | `checkCanceled()`
    `void` | `done()`
    `OMMonitor` | `fork()` Same as calling `fork(ONE)`.
    `OMMonitor` | `fork(double work)`
    `OMMonitor.Async` | `forkAsync()` Same as calling `forkAsync(ONE)`.
    `OMMonitor.Async` | `forkAsync(double work)`
    `OMMonitor` | `getDelegate()`
    `double` | `getTotalWork()`
    `double` | `getWork()`
    `double` | `getWorkPercent()`
    `boolean` | `hasBegun()`
    `boolean` | `isCanceled()`
    `void` | `worked()` Same as calling `worked(ONE)`.
    `void` | `worked(double work)`

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

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

- - ### Constructor Detail

    - #### DelegatingMonitor

          public DelegatingMonitor(OMMonitor delegate)

  - ### Method Detail

    - #### getDelegate

          public OMMonitor getDelegate()

    - #### hasBegun

          public boolean hasBegun()
                           throws MonitorCanceledException

      Specified by:
        `hasBegun` in interface `OMMonitor`
      Throws:
        `MonitorCanceledException`

    - #### begin

          public OMMonitor begin()
                          throws MonitorCanceledException

      Description copied from interface: `OMMonitor`
      Same as calling `begin(ONE)`.
      Specified by:
        `begin` in interface `OMMonitor`
      Throws:
        `MonitorCanceledException`

    - #### begin

          public OMMonitor begin(double totalWork)
                          throws MonitorCanceledException

      Specified by:
        `begin` in interface `OMMonitor`
      Throws:
        `MonitorCanceledException`

    - #### checkCanceled

          public void checkCanceled()
                             throws MonitorCanceledException

      Specified by:
        `checkCanceled` in interface `OMMonitor`
      Throws:
        `MonitorCanceledException`

    - #### done

          public void done()

      Specified by:
        `done` in interface `OMMonitor`

    - #### fork

          public OMMonitor fork()

      Description copied from interface: `OMMonitor`
      Same as calling `fork(ONE)`.
      Specified by:
        `fork` in interface `OMMonitor`

    - #### fork

          public OMMonitor fork(double work)

      Specified by:
        `fork` in interface `OMMonitor`

    - #### forkAsync

          public OMMonitor.Async forkAsync()

      Description copied from interface: `OMMonitor`
      Same as calling `forkAsync(ONE)`.
      Specified by:
        `forkAsync` in interface `OMMonitor`

    - #### forkAsync

          public OMMonitor.Async forkAsync(double work)

      Specified by:
        `forkAsync` in interface `OMMonitor`

    - #### getTotalWork

          public double getTotalWork()

      Specified by:
        `getTotalWork` in interface `OMMonitorProgress`

    - #### getWork

          public double getWork()

      Specified by:
        `getWork` in interface `OMMonitorProgress`

    - #### getWorkPercent

          public double getWorkPercent()

      Specified by:
        `getWorkPercent` in interface `OMMonitorProgress`

    - #### isCanceled

          public boolean isCanceled()

      Specified by:
        `isCanceled` in interface `OMMonitor`

    - #### worked

          public void worked()
                      throws MonitorCanceledException

      Description copied from interface: `OMMonitor`
      Same as calling `worked(ONE)`.
      Specified by:
        `worked` in interface `OMMonitor`
      Throws:
        `MonitorCanceledException`

    - #### worked

          public void worked(double work)
                      throws MonitorCanceledException

      Specified by:
        `worked` in interface `OMMonitor`
      Throws:
        `MonitorCanceledException`

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