Search in sources :

Example 1 with DefaultTaskDescriptor

use of org.gradle.internal.build.event.types.DefaultTaskDescriptor in project gradle by gradle.

the class TaskOperationMapper method createDescriptor.

@Override
public DefaultTaskDescriptor createDescriptor(ExecuteTaskBuildOperationDetails details, BuildOperationDescriptor buildOperation, @Nullable OperationIdentifier parent) {
    OperationIdentifier id = buildOperation.getId();
    String taskIdentityPath = buildOperation.getName();
    String displayName = buildOperation.getDisplayName();
    String taskPath = details.getTask().getIdentityPath().getPath();
    Set<InternalOperationDescriptor> dependencies = operationDependenciesResolver.resolveDependencies(details.getTaskNode());
    InternalPluginIdentifier originPlugin = taskOriginTracker.getOriginPlugin(details.getTask().getTaskIdentity());
    DefaultTaskDescriptor descriptor = new DefaultTaskDescriptor(id, taskIdentityPath, taskPath, displayName, parent, dependencies, originPlugin);
    descriptors.put(details.getTask().getTaskIdentity(), descriptor);
    return descriptor;
}
Also used : InternalOperationDescriptor(org.gradle.tooling.internal.protocol.events.InternalOperationDescriptor) OperationIdentifier(org.gradle.internal.operations.OperationIdentifier) DefaultTaskDescriptor(org.gradle.internal.build.event.types.DefaultTaskDescriptor) InternalPluginIdentifier(org.gradle.tooling.internal.protocol.events.InternalPluginIdentifier)

Aggregations

DefaultTaskDescriptor (org.gradle.internal.build.event.types.DefaultTaskDescriptor)1 OperationIdentifier (org.gradle.internal.operations.OperationIdentifier)1 InternalOperationDescriptor (org.gradle.tooling.internal.protocol.events.InternalOperationDescriptor)1 InternalPluginIdentifier (org.gradle.tooling.internal.protocol.events.InternalPluginIdentifier)1