org.littleshoot.util
Class ThreadUtils

java.lang.Object
  extended by org.littleshoot.util.ThreadUtils

public final class ThreadUtils
extends Object

An implementation of the thread utilities interface.


Method Summary
static String dumpStack()
          Returns the stack trace as a string.
static String dumpStack(Throwable cause)
          Returns the stack trace as a string.
static void safeSleep(long milliseconds)
           
static void safeWait(Object object)
           
static void safeWait(Object object, int millis)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

safeWait

public static void safeWait(Object object)

safeWait

public static void safeWait(Object object,
                            int millis)

safeSleep

public static void safeSleep(long milliseconds)

dumpStack

public static String dumpStack()
Returns the stack trace as a string.

Returns:
The stack trace as a string.

dumpStack

public static String dumpStack(Throwable cause)
Returns the stack trace as a string.

Parameters:
cause - The thread to dump.
Returns:
The stack trace as a string.


Copyright © 2011-2013 LittleShoot. All Rights Reserved.