@Nullable
  private static DataNode<? extends ExternalEntityData> createDependencyDataNode(UnresolvedExternalDependency unresolvedDep,
                                                                                 @NotNull ProjectResolverContext resolverCtx,
                                                                                 @NotNull DataNode<? extends ExternalEntityData> ownerDataNode,
                                                                                 @Nullable DataNode<ProjectData> ideProject,
                                                                                 AtomicInteger classpathOrderShift) {

    final ModuleData ownerModule = getOwnerModule(ownerDataNode);

    reportUnresolvedDependencyError(resolverCtx, unresolvedDep, ownerModule.getId());

    String libraryName = unresolvedDep.getId().getPresentableName();
    DependencyScope dependencyScope = getDependencyScope(unresolvedDep.getScope());
    final LibraryData library = new LibraryData(GradleConstants.SYSTEM_ID, libraryName, true);
    LibraryLevel level = linkProjectLibrary(ideProject, library) ? LibraryLevel.PROJECT : LibraryLevel.MODULE;
    LibraryDependencyData libraryDependencyData = new LibraryDependencyData(ownerModule, library, level);
    libraryDependencyData.setScope(dependencyScope);
    libraryDependencyData.setOrder(unresolvedDep.getClasspathOrder() + classpathOrderShift.get());
    ownerDataNode.createChild(ProjectKeys.LIBRARY_DEPENDENCY, libraryDependencyData);
    return null;
  }
@Nullable
  private static DataNode<? extends ExternalEntityData> createDependencyDataNode(UnresolvedExternalDependency unresolvedDep,
                                                                                 @NotNull ProjectResolverContext resolverCtx,
                                                                                 @NotNull DataNode<? extends ExternalEntityData> ownerDataNode,
                                                                                 @Nullable DataNode<ProjectData> ideProject,
                                                                                 AtomicInteger classpathOrderShift)