use of org.gradle.api.plugins.UnknownPluginException in project gradle by gradle.
the class DefaultPluginRequestApplicator method resolveToFoundResult.
private Result resolveToFoundResult(PluginResolver effectivePluginResolver, PluginRequestInternal request) {
Result result = new Result(request);
try {
effectivePluginResolver.resolve(request, result);
} catch (Exception e) {
throw new LocationAwareException(new GradleException(String.format("Error resolving plugin %s", request.getDisplayName()), e), request.getScriptDisplayName(), request.getLineNumber());
}
if (!result.isFound()) {
String message = buildNotFoundMessage(request, result);
Exception exception = new UnknownPluginException(message);
throw new LocationAwareException(exception, request.getScriptDisplayName(), request.getLineNumber());
}
return result;
}
use of org.gradle.api.plugins.UnknownPluginException in project gradle by gradle.
the class ClassPathPluginResolution method execute.
@Override
public void execute(PluginResolveContext pluginResolveContext) {
PluginRegistry pluginRegistry = new DefaultPluginRegistry(pluginInspector, parent);
PluginImplementation<?> plugin = pluginRegistry.lookup(pluginId);
if (plugin == null) {
throw new UnknownPluginException("Plugin with id '" + pluginId + "' not found.");
}
pluginResolveContext.add(plugin);
}
Aggregations