• 如果您觉得本站非常有看点,那么赶紧使用Ctrl+D 收藏吧

Java BuildableArtifactResolveResult类的典型用法和代码示例

java 1次浏览

本文整理汇总了Java中org.gradle.internal.resolve.result.BuildableArtifactResolveResult的典型用法代码示例。如果您正苦于以下问题:Java BuildableArtifactResolveResult类的具体用法?Java BuildableArtifactResolveResult怎么用?Java BuildableArtifactResolveResult使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。

BuildableArtifactResolveResult类属于org.gradle.internal.resolve.result包,在下文中一共展示了BuildableArtifactResolveResult类的36个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: resolveArtifact

点赞 3

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    if (isProjectModule(artifact.getComponentId())) {
        LocalComponentArtifactMetadata projectArtifact = (LocalComponentArtifactMetadata) artifact;

        // Run any registered actions to build this artifact
        artifactBuilder.build(projectArtifact);

        File localArtifactFile = projectArtifact.getFile();
        if (localArtifactFile != null) {
            result.resolved(localArtifactFile);
        } else {
            result.notFound(projectArtifact.getId());
        }
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:17,
代码来源:ProjectDependencyResolver.java

示例2: resolveArtifactFromCache

点赞 3

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
private void resolveArtifactFromCache(ComponentArtifactMetadata artifact, CachingModuleSource moduleSource, BuildableArtifactResolveResult result) {
    CachedArtifact cached = artifactAtRepositoryCachedResolutionIndex.lookup(artifactCacheKey(artifact));
    final BigInteger descriptorHash = moduleSource.getDescriptorHash();
    if (cached != null) {
        long age = timeProvider.getCurrentTime() - cached.getCachedAt();
        final boolean isChangingModule = moduleSource.isChangingModule();
        ArtifactIdentifier artifactIdentifier = ((ModuleComponentArtifactMetadata) artifact).toArtifactIdentifier();
        if (cached.isMissing()) {
            if (!cachePolicy.mustRefreshArtifact(artifactIdentifier, null, age, isChangingModule, descriptorHash.equals(cached.getDescriptorHash()))) {
                LOGGER.debug("Detected non-existence of artifact '{}' in resolver cache", artifact);
                for (String location : cached.attemptedLocations()) {
                    result.attempted(location);
                }
                result.notFound(artifact.getId());
            }
        } else {
            File cachedArtifactFile = cached.getCachedFile();
            if (!cachePolicy.mustRefreshArtifact(artifactIdentifier, cachedArtifactFile, age, isChangingModule, descriptorHash.equals(cached.getDescriptorHash()))) {
                LOGGER.debug("Found artifact '{}' in resolver cache: {}", artifact, cachedArtifactFile);
                result.resolved(cachedArtifactFile);
            }
        }
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:25,
代码来源:CachingModuleComponentRepository.java

示例3: resolveArtifact

点赞 3

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
protected void resolveArtifact(ComponentArtifactMetadata componentArtifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    ModuleComponentArtifactMetadata artifact = (ModuleComponentArtifactMetadata) componentArtifact;

    File localFile;
    try {
        localFile = download(artifact, moduleSource, result);
    } catch (Throwable e) {
        result.failed(new ArtifactResolveException(artifact.getId(), e));
        return;
    }

    if (localFile != null) {
        result.resolved(localFile);
    } else {
        result.notFound(artifact.getId());
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:18,
代码来源:ExternalResourceResolver.java

示例4: resolveArtifact

点赞 3

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact( ComponentArtifactMetadata artifact, ModuleSource module,
                             BuildableArtifactResolveResult result )
{
    ModuleVersionIdentifier moduleId =
        ( (DefaultModuleComponentArtifactMetadata) artifact ).toArtifactIdentifier().getModuleVersionIdentifier();
    String groupId = moduleId.getGroup();
    String artifactId = artifact.getName().getName();
    String extension = artifact.getName().getExtension();
    String classifier = artifact.getName().getClassifier();
    String version = moduleId.getVersion();

    Artifact artifact2 = new DefaultArtifact( groupId, artifactId, extension, classifier, version );
    Path path = resolve( artifact2 );

    if ( path == null )
    {
        logger.debug( "Unable to resolve artifact {}", artifact2 );
        result.failed( new ArtifactResolveException( artifact.getId(),
                                                     "XMvn was unable to resolve artifact " + artifact2 ) );
        return;
    }

    logger.debug( "Artifact {} was resolved to {}", artifact2, path );
    result.resolved( path.toFile() );
}
 

开发者ID:fedora-java
项目名称:xmvn,
代码行数:27,
代码来源:GradleResolver.java

示例5: resolveArtifact

点赞 3

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetaData artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
	LOG.trace("resolveArtifact");

	String artifactId = artifact.getName().getName();
	String gradleVersionRangeString = ((ModuleComponentIdentifier) artifact.getComponentId()).getVersion();
	String osgiVersionRangeString = gradleToOsgiVersion(gradleVersionRangeString);
	try {
		URI fileUri = this.fetchArtifact(artifactId, osgiVersionRangeString);
		if (null != fileUri) {
			result.resolved(Paths.get(fileUri).toFile());
		} else {
			LOG.error("Unable to find artifact " + artifactId);
			result.notFound(artifact.getId());
		}
	} catch (OsgiP2ResolverException e) {
		LOG.error("Unable to resolve artifact " + artifactId);
		result.attempted(this.getRepositoryUri().toString());
		result.failed(new ArtifactResolveException(artifact.getId(), e));
	}
}
 

开发者ID:dhakehurst,
项目名称:net.akehurst.build.gradle,
代码行数:22,
代码来源:AbstractP2RepositoryAccess.java

示例6: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    if (isLibrary(artifact.getComponentId())) {
        if (artifact instanceof PublishArtifactLocalArtifactMetadata) {
            result.resolved(((PublishArtifactLocalArtifactMetadata) artifact).getFile());
        } else {
            result.failed(new ArtifactResolveException("Unsupported artifact metadata type: " + artifact));
        }
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:11,
代码来源:LocalLibraryDependencyResolver.java

示例7: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(final ComponentArtifactMetadata artifact, final ModuleSource moduleSource, final BuildableArtifactResolveResult result) {
    String description = "Resolve ".concat(artifact.toString());
    lockingManager.useCache(description, new Runnable() {
        public void run() {
            delegate.resolveArtifact(artifact, moduleSource, result);
        }
    });
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:10,
代码来源:CacheLockingArtifactResolver.java

示例8: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    try {
        delegate.resolveArtifact(artifact, moduleSource, result);
    } catch (Throwable throwable) {
        result.failed(new ArtifactResolveException(artifact.getId(), throwable));
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:9,
代码来源:ErrorHandlingModuleComponentRepository.java

示例9: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(final ComponentArtifactMetadata artifact, final ModuleSource moduleSource, final BuildableArtifactResolveResult result) {
    cacheLockingManager.useCache("Resolve " + artifact, new Runnable() {
        public void run() {
            delegate.getArtifactResolver().resolveArtifact(artifact, moduleSource, result);
        }
    });
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:9,
代码来源:ResolveIvyFactory.java

示例10: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(final ComponentArtifactMetadata artifact, final ModuleSource moduleSource, final BuildableArtifactResolveResult result) {
    cacheLockingManager.longRunningOperation("Download " + artifact + " using repository " + name, new Runnable() {
        public void run() {
            delegate.resolveArtifact(artifact, moduleSource, result);
        }
    });
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:9,
代码来源:CacheLockReleasingModuleComponentsRepository.java

示例11: supplyArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public boolean supplyArtifact(ComponentArtifactIdentifier id, BuildableArtifactResolveResult result) {
    File fromCache = artifacts.get(id);
    if (fromCache != null) {
        result.resolved(fromCache);
        return true;
    }
    return false;
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:9,
代码来源:InMemoryArtifactsCache.java

示例12: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    if (!artifactsCache.supplyArtifact(artifact.getId(), result)) {
        super.resolveArtifact(artifact, moduleSource, result);
        artifactsCache.newArtifact(artifact.getId(), result);
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:8,
代码来源:InMemoryCachedModuleComponentRepository.java

示例13: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    final CachingModuleSource cachedModuleSource = (CachingModuleSource) moduleSource;

    // First try to determine the artifacts in-memory (e.g using the metadata): don't use the cache in this case
    delegate.getLocalAccess().resolveArtifact(artifact, cachedModuleSource.getDelegate(), result);
    if (result.hasResult()) {
        return;
    }

    resolveArtifactFromCache(artifact, cachedModuleSource, result);
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:13,
代码来源:CachingModuleComponentRepository.java

示例14: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource source, BuildableArtifactResolveResult result) {
    ModuleComponentRepository sourceRepository = findSourceRepository(source);
    ModuleSource unpackedSource = unpackSource(source);

    // First try to resolve the artifacts locally before going remote
    sourceRepository.getLocalAccess().resolveArtifact(artifact, unpackedSource, result);
    if (!result.hasResult()) {
        sourceRepository.getRemoteAccess().resolveArtifact(artifact, unpackedSource, result);
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:12,
代码来源:RepositoryChainArtifactResolver.java

示例15: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    try {
        resolver.resolveArtifact(artifact, moduleSource, result);
    } catch (Throwable t) {
        result.failed(new ArtifactResolveException(artifact.getId(), t));
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:9,
代码来源:ErrorHandlingArtifactResolver.java

示例16: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    delegate.getLocalAccess().resolveArtifact(artifact, moduleSource, result);
    if(!result.hasResult()) {
        delegate.getRemoteAccess().resolveArtifact(artifact, moduleSource, result);
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:8,
代码来源:LocalModuleComponentRepository.java

示例17: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    for (ArtifactResolver resolver : resolvers) {
        if (result.hasResult()) {
            return;
        }
        resolver.resolveArtifact(artifact, moduleSource, result);
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:10,
代码来源:ComponentResolversChain.java

示例18: addArtifacts

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
private <T extends Artifact> void addArtifacts(DefaultComponentArtifactsResult artifacts, Class<T> type, ComponentResolveMetadata component, ArtifactResolver artifactResolver) {
    BuildableArtifactSetResolveResult artifactSetResolveResult = new DefaultBuildableArtifactSetResolveResult();
    artifactResolver.resolveArtifactsWithType(component, convertType(type), artifactSetResolveResult);

    for (ComponentArtifactMetadata artifactMetaData : artifactSetResolveResult.getResult()) {
        BuildableArtifactResolveResult resolveResult = new DefaultBuildableArtifactResolveResult();
        artifactResolver.resolveArtifact(artifactMetaData, component.getSource(), resolveResult);
        if (resolveResult.getFailure() != null) {
            artifacts.addArtifact(new DefaultUnresolvedArtifactResult(artifactMetaData.getId(), type, resolveResult.getFailure()));
        } else {
            artifacts.addArtifact(new DefaultResolvedArtifactResult(artifactMetaData.getId(), type, resolveResult.getResult()));
        }
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:15,
代码来源:DefaultArtifactResolutionQuery.java

示例19: download

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
protected File download(ModuleComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    LocallyAvailableExternalResource artifactResource = createArtifactResolver(moduleSource).resolveArtifact(artifact, result);
    if (artifactResource == null) {
        return null;
    }

    return artifactResource.getLocalResource().getFile();
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:9,
代码来源:ExternalResourceResolver.java

示例20: resolveMetaDataArtifactFile

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
private File resolveMetaDataArtifactFile(ModuleComponentIdentifier moduleComponentIdentifier, ComponentMetaDataResolver componentResolver,
                                         ArtifactResolver artifactResolver, ArtifactType artifactType) {
    BuildableComponentResolveResult moduleVersionResolveResult = new DefaultBuildableComponentResolveResult();
    componentResolver.resolve(moduleComponentIdentifier, new DefaultComponentOverrideMetadata(), moduleVersionResolveResult);

    BuildableArtifactSetResolveResult moduleArtifactsResolveResult = new DefaultBuildableArtifactSetResolveResult();
    artifactResolver.resolveArtifactsWithType(moduleVersionResolveResult.getMetaData(), artifactType, moduleArtifactsResolveResult);

    BuildableArtifactResolveResult artifactResolveResult = new DefaultBuildableArtifactResolveResult();
    ComponentArtifactMetadata artifactMetaData = moduleArtifactsResolveResult.getResult().iterator().next();
    artifactResolver.resolveArtifact(artifactMetaData, moduleVersionResolveResult.getMetaData().getSource(), artifactResolveResult);
    return artifactResolveResult.getResult();
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:14,
代码来源:ExternalResourceResolverDescriptorParseContext.java

示例21: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void resolveArtifact(final ComponentArtifactMetaData artifact, final ModuleSource moduleSource, final BuildableArtifactResolveResult result) {
    executeInContext(String.format("Resolve %s", artifact), new Action<Ivy>() {
        public void execute(Ivy ivy) {
            delegate.resolveArtifact(artifact, moduleSource, result);
        }
    });
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:8,
代码来源:ContextualArtifactResolver.java

示例22: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void resolveArtifact(ComponentArtifactMetaData artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    if (isProjectModule(artifact.getComponentId())) {
        LocalArtifactMetaData localArtifact = (LocalArtifactMetaData) artifact;
        if (localArtifact.getFile() != null) {
            result.resolved(localArtifact.getFile());
        } else {
            result.notFound(artifact.getId());
        }
    } else {
        delegate.resolveArtifact(artifact, moduleSource, result);
    }
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:13,
代码来源:ProjectArtifactResolver.java

示例23: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void resolveArtifact(final ComponentArtifactMetaData artifact, final ModuleSource moduleSource, final BuildableArtifactResolveResult result) {
    cacheLockingManager.useCache(String.format("Resolve %s", artifact), new Runnable() {
        public void run() {
            artifactResolver.resolveArtifact(artifact, moduleSource, result);
        }
    });
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:8,
代码来源:ResolveIvyFactory.java

示例24: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void resolveArtifact(final ComponentArtifactMetaData artifact, final ModuleSource moduleSource, final BuildableArtifactResolveResult result) {
    cacheLockingManager.longRunningOperation(String.format("Download %s using repository %s", artifact, name), new Runnable() {
        public void run() {
            delegate.resolveArtifact(artifact, moduleSource, result);
        }
    });
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:8,
代码来源:CacheLockReleasingModuleComponentsRepository.java

示例25: supplyArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public boolean supplyArtifact(ComponentArtifactIdentifier id, BuildableArtifactResolveResult result) {
    File fromCache = artifacts.get(id);
    if (fromCache != null) {
        result.resolved(fromCache);
        stats.artifactsServed++;
        return true;
    }
    return false;
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:10,
代码来源:InMemoryArtifactsCache.java

示例26: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void resolveArtifact(ComponentArtifactMetaData artifact, ModuleSource source, BuildableArtifactResolveResult result) {
    ModuleComponentRepository sourceRepository = findSourceRepository(source);
    ModuleSource unpackedSource = unpackSource(source);

    // First try to resolve the artifacts locally before going remote
    sourceRepository.getLocalAccess().resolveArtifact(artifact, unpackedSource, result);
    if (!result.hasResult()) {
        sourceRepository.getRemoteAccess().resolveArtifact(artifact, unpackedSource, result);
    }
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:11,
代码来源:RepositoryChainArtifactResolver.java

示例27: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void resolveArtifact(ComponentArtifactMetaData artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    try {
        resolver.resolveArtifact(artifact, moduleSource, result);
    } catch (Throwable t) {
        result.failed(new ArtifactResolveException(artifact.getId(), t));
    }
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:8,
代码来源:ErrorHandlingArtifactResolver.java

示例28: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    result.failed(new ArtifactResolveException(artifact.getId(), "No cached version available for offline mode"));
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:5,
代码来源:StartParameterResolutionOverride.java

示例29: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    throw new UnsupportedOperationException();
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:5,
代码来源:NoRepositoriesResolver.java

示例30: newArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void newArtifact(ComponentArtifactIdentifier id, BuildableArtifactResolveResult result) {
    if (result.isSuccessful()) {
        artifacts.put(id, result.getResult());
    }
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:6,
代码来源:InMemoryArtifactsCache.java

示例31: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
@Override
public void resolveArtifact(ComponentArtifactMetadata artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    delegate.resolveArtifact(artifact, moduleSource, result);
}
 

开发者ID:lxxlxx888,
项目名称:Reer,
代码行数:5,
代码来源:BaseModuleComponentRepositoryAccess.java

示例32: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void resolveArtifact(ComponentArtifactMetaData artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    result.failed(new ArtifactResolveException(artifact.getId(), "No cached version available for offline mode"));
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:4,
代码来源:StartParameterResolutionOverride.java

示例33: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void resolveArtifact(ComponentArtifactMetaData artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    throw new UnsupportedOperationException();
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:4,
代码来源:NoRepositoriesResolver.java

示例34: newArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void newArtifact(ComponentArtifactIdentifier id, BuildableArtifactResolveResult result) {
    if (result.hasResult() && result.getFailure() == null) {
        artifacts.put(id, result.getFile());
    }
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:6,
代码来源:InMemoryArtifactsCache.java

示例35: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void resolveArtifact(ComponentArtifactMetaData artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    if (!artifactsCache.supplyArtifact(artifact.getId(), result)) {
        super.resolveArtifact(artifact, moduleSource, result);
        artifactsCache.newArtifact(artifact.getId(), result);
    }
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:7,
代码来源:InMemoryCachedModuleComponentRepository.java

示例36: resolveArtifact

点赞 2

import org.gradle.internal.resolve.result.BuildableArtifactResolveResult; //导入依赖的package包/类
public void resolveArtifact(ComponentArtifactMetaData artifact, ModuleSource moduleSource, BuildableArtifactResolveResult result) {
    delegate.getLocalAccess().resolveArtifact(artifact, moduleSource, result);
    if(!result.hasResult()) {
        delegate.getRemoteAccess().resolveArtifact(artifact, moduleSource, result);
    }
}
 

开发者ID:Pushjet,
项目名称:Pushjet-Android,
代码行数:7,
代码来源:LocalModuleComponentRepository.java


版权声明:本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系管理员进行删除。
喜欢 (0)