Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Kieker 1.10
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## kieker.monitoring.writer
Class AbstractAsyncThread

    java.lang.Object
      java.lang.Thread
          kieker.monitoring.writer.AbstractAsyncThread

All Implemented Interfaces:
  Runnable

Direct Known Subclasses:
  AbstractFsWriterThread, AbstractZipWriterThread

    public abstract class AbstractAsyncThread

extends Thread

Since:
  1.3
Author:
  Andre van Hoorn, Jan Waller

Nested Class Summary

Nested classes/interfaces inherited from class java.lang.Thread
`Thread.State, Thread.UncaughtExceptionHandler`

Field Summary

Fields inherited from class java.lang.Thread
`MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY`

Constructor Summary
`AbstractAsyncThread(IMonitoringController monitoringController, BlockingQueue<IMonitoringRecord> writeQueue)` Creates a new instance of this class using the given parameters.

Method Summary
`void` | `initShutdown(CountDownLatch cdl)` Initializes the shutdown of this thread if necessary.
`boolean` | `isFinished()` Can be used to determine whether the thread is in the finished state or not.
`void` | `run()`
`String` | `toString()` Returns a human-readable information string about the writer's configuration and state.

Methods inherited from class java.lang.Thread
`activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, yield`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### AbstractAsyncThread

    public AbstractAsyncThread(IMonitoringController monitoringController,
                               BlockingQueue<IMonitoringRecord> writeQueue)

  Creates a new instance of this class using the given parameters.

  Parameters:
    `monitoringController` - The monitoring controller for the current monitoring session.
    `writeQueue` - The queue containing the records (and the potential `end of monitoring` marker).

Method Detail

### initShutdown

    public final void initShutdown(CountDownLatch cdl)

  Initializes the shutdown of this thread if necessary. The method returns immediately in every case and counts the latch down eventually (assuming that no exception occurs).

  Parameters:
    `cdl` - The latch which will be count down once the thread has been terminated.

### isFinished

    public final boolean isFinished()

  Can be used to determine whether the thread is in the finished state or not.

  Returns:
    true iff the thread has set the finished flag.

### run

    public final void run()

  Specified by:
    `run` in interface `Runnable`
  Overrides:
    `run` in class `Thread`

### toString

    public String toString()

  Returns a human-readable information string about the writer's configuration and state.

  Overrides:
    `toString` in class `Thread`
  Returns:
    the information string.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Kieker 1.10
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright 2014 Kieker Project, http://kieker-monitoring.net