org.gradle.api.artifacts.Configuration.getState()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(1.7k)|赞(0)|评价(0)|浏览(122)

本文整理了Java中org.gradle.api.artifacts.Configuration.getState()方法的一些代码示例,展示了Configuration.getState()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Configuration.getState()方法的具体详情如下:
包路径:org.gradle.api.artifacts.Configuration
类名称:Configuration
方法名:getState

Configuration.getState介绍

暂无

代码示例

代码示例来源:origin: com.netflix.nebula/nebula-dependency-recommender

@Override
public void execute(final Configuration conf) {
  final RecommendationStrategyFactory rsFactory = new RecommendationStrategyFactory(project);
  if (conf.getState() == Configuration.State.UNRESOLVED) {
    ConfigurationsKt.onResolve(conf, new Function1<ResolvableDependencies, Unit>() {
      @Override

代码示例来源:origin: com.android.tools.build/gradle-core

if (getAnnotationProcessorConfiguration().getState() != Configuration.State.RESOLVED
    && includeClasspath) {
  getAnnotationProcessorConfiguration().extendsFrom(

代码示例来源:origin: com.netflix.nebula/nebula-dependency-recommender

@Override
  public void execute(Configuration configuration) {
    if (container.getExcludedConfigurations().contains(configuration.getName())) {
      return;
    }

    if (configuration.getState() == Configuration.State.UNRESOLVED) {
      Configuration toExtend = bom;
      if (!project.getRootProject().equals(project)) {
        toExtend = bom.copy();
        toExtend.setVisible(false);
        project.getConfigurations().add(toExtend);
      }
      configuration.extendsFrom(toExtend);
    } else {
      logger.info("Configuration '" + configuration.getName() + "' has already been resolved and cannot be included for recommendation");
    }
  }
}

代码示例来源:origin: MinecraftForge/ForgeGradle

if (project.getConfigurations().getByName(CONFIG_MC_DEPS).getState() == State.UNRESOLVED)
if (project.getConfigurations().getByName(CONFIG_NATIVES).getState() == State.UNRESOLVED)

相关文章