Class DefaultAsyncConsumerActionExecutor
- java.lang.Object
-
- org.gradle.tooling.internal.consumer.async.DefaultAsyncConsumerActionExecutor
-
- All Implemented Interfaces:
AsyncConsumerActionExecutor
public class DefaultAsyncConsumerActionExecutor extends java.lang.Object implements AsyncConsumerActionExecutor
Adapts aConsumerActionExecutor
to anAsyncConsumerActionExecutor
.
-
-
Constructor Summary
Constructors Constructor Description DefaultAsyncConsumerActionExecutor(ConsumerActionExecutor actionExecutor, org.gradle.internal.concurrent.ExecutorFactory executorFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
disconnect()
Requests cancellation on the current operation and send a 'stop when idle' message to the daemon.java.lang.String
getDisplayName()
<T> void
run(ConsumerAction<? extends T> action, ResultHandlerVersion1<? super T> handler)
Runs some operation asynchronously against a consumer connection.void
stop()
Stops this connection, blocking until all operations on the connection have completed.
-
-
-
Constructor Detail
-
DefaultAsyncConsumerActionExecutor
public DefaultAsyncConsumerActionExecutor(ConsumerActionExecutor actionExecutor, org.gradle.internal.concurrent.ExecutorFactory executorFactory)
-
-
Method Detail
-
getDisplayName
public java.lang.String getDisplayName()
- Specified by:
getDisplayName
in interfaceAsyncConsumerActionExecutor
-
stop
public void stop()
Description copied from interface:AsyncConsumerActionExecutor
Stops this connection, blocking until all operations on the connection have completed.- Specified by:
stop
in interfaceAsyncConsumerActionExecutor
-
disconnect
public void disconnect()
Description copied from interface:AsyncConsumerActionExecutor
Requests cancellation on the current operation and send a 'stop when idle' message to the daemon.- Specified by:
disconnect
in interfaceAsyncConsumerActionExecutor
-
run
public <T> void run(ConsumerAction<? extends T> action, ResultHandlerVersion1<? super T> handler)
Description copied from interface:AsyncConsumerActionExecutor
Runs some operation asynchronously against a consumer connection. Notifies the provided handler when complete. Note that the action may have completed by the time this method returns.- Specified by:
run
in interfaceAsyncConsumerActionExecutor
-
-