Class ComThread
java.lang.Object
com.sun.jna.platform.win32.COM.util.ComThread
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) ExecutorService(package private) Runnable(package private) boolean(package private) long(package private) Thread.UncaughtExceptionHandler -
Constructor Summary
ConstructorsConstructorDescriptionComThread(String threadName, long timeoutMilliseconds, Thread.UncaughtExceptionHandler uncaughtExceptionHandler) ComThread(String threadName, long timeoutMilliseconds, Thread.UncaughtExceptionHandler uncaughtExceptionHandler, int coinitialiseExFlag) -
Method Summary
Modifier and TypeMethodDescription<T> Tprotected voidfinalize()(package private) static voidsetComThread(boolean value) voidterminate(long timeoutMilliseconds) Stop the COM Thread.
-
Field Details
-
executor
ExecutorService executor -
firstTask
Runnable firstTask -
requiresInitialisation
boolean requiresInitialisation -
timeoutMilliseconds
long timeoutMilliseconds -
uncaughtExceptionHandler
Thread.UncaughtExceptionHandler uncaughtExceptionHandler
-
-
Constructor Details
-
ComThread
public ComThread(String threadName, long timeoutMilliseconds, Thread.UncaughtExceptionHandler uncaughtExceptionHandler) -
ComThread
public ComThread(String threadName, long timeoutMilliseconds, Thread.UncaughtExceptionHandler uncaughtExceptionHandler, int coinitialiseExFlag)
-
-
Method Details
-
terminate
public void terminate(long timeoutMilliseconds) Stop the COM Thread.- Parameters:
timeoutMilliseconds- number of milliseconds to wait for a clean shutdown before a forced shutdown is attempted
-
finalize
-
setComThread
static void setComThread(boolean value) -
execute
public <T> T execute(Callable<T> task) throws TimeoutException, InterruptedException, ExecutionException
-