use of org.gradle.api.execution.internal.TaskOperationDescriptor in project gradle by gradle.
the class ClientForwardingTaskOperationListener method finished.
@Override
public void finished(BuildOperationInternal buildOperation, OperationResult finishEvent) {
if (skipEvents.remove(buildOperation.getId())) {
return;
}
if (buildOperation.getOperationDescriptor() instanceof TaskOperationDescriptor) {
TaskInternal task = ((TaskOperationDescriptor) buildOperation.getOperationDescriptor()).getTask();
eventConsumer.dispatch(new DefaultTaskFinishedProgressEvent(finishEvent.getEndTime(), toTaskDescriptor(buildOperation, task), toTaskResult(task, finishEvent)));
} else {
delegate.finished(buildOperation, finishEvent);
}
}
use of org.gradle.api.execution.internal.TaskOperationDescriptor in project gradle by gradle.
the class ClientForwardingTaskOperationListener method started.
@Override
public void started(BuildOperationInternal buildOperation, OperationStartEvent startEvent) {
if (skipEvents.contains(buildOperation.getParentId())) {
skipEvents.add(buildOperation.getId());
return;
}
if (buildOperation.getOperationDescriptor() instanceof TaskOperationDescriptor) {
if (clientSubscriptions.isSendTaskProgressEvents()) {
TaskInternal task = ((TaskOperationDescriptor) buildOperation.getOperationDescriptor()).getTask();
eventConsumer.dispatch(new DefaultTaskStartedProgressEvent(startEvent.getStartTime(), toTaskDescriptor(buildOperation, task)));
} else {
// Discard this operation and all children
skipEvents.add(buildOperation.getId());
}
} else {
delegate.started(buildOperation, startEvent);
}
}
use of org.gradle.api.execution.internal.TaskOperationDescriptor in project gradle by gradle.
the class ClientForwardingTestOperationListener method started.
@Override
public void started(BuildOperationInternal buildOperation, OperationStartEvent startEvent) {
if (!(buildOperation.getOperationDescriptor() instanceof TaskOperationDescriptor)) {
return;
}
TaskInternal task = ((TaskOperationDescriptor) buildOperation.getOperationDescriptor()).getTask();
if (!(task instanceof Test)) {
return;
}
runningTasks.put(buildOperation.getId(), task.getPath());
}
use of org.gradle.api.execution.internal.TaskOperationDescriptor in project gradle by gradle.
the class TestExecutionResultEvaluator method started.
@Override
public void started(BuildOperationInternal buildOperation, OperationStartEvent startEvent) {
if (!(buildOperation.getOperationDescriptor() instanceof TaskOperationDescriptor)) {
return;
}
TaskInternal task = ((TaskOperationDescriptor) buildOperation.getOperationDescriptor()).getTask();
runningTasks.put(buildOperation.getId(), task.getPath());
}
Aggregations