org.eclipse.emf.emfstore.internal.client.ui.common
Class RunInUI

java.lang.Object
  extended by org.eclipse.emf.emfstore.internal.client.ui.common.RunInUI

public final class RunInUI
extends Object

Utility class for executing Callables within the UI Thread.

Author:
emueller

Nested Class Summary
static class RunInUI.WithException
          The Callable to be executed may throw an exception.
 
Method Summary
static void run(Callable<Void> callable)
          Executes the given Callable and returns the result.
static
<T> T
runWithResult(Callable<T> callable)
          Executes the given callable and returns the result.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

run

public static void run(Callable<Void> callable)
Executes the given Callable and returns the result.

Parameters:
callable - the Callable to be executed

runWithResult

public static <T> T runWithResult(Callable<T> callable)
Executes the given callable and returns the result.

Type Parameters:
T - the return type of the callable
Parameters:
callable - the callable to be execued
Returns:
the return value of the Callable


Copyright © 2015. All Rights Reserved.