本文整理汇总了Java中org.apache.ivy.core.module.descriptor.DefaultDependencyDescriptor.addExcludeRule方法的典型用法代码示例。如果您正苦于以下问题:Java DefaultDependencyDescriptor.addExcludeRule方法的具体用法?Java DefaultDependencyDescriptor.addExcludeRule怎么用?Java DefaultDependencyDescriptor.addExcludeRule使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.apache.ivy.core.module.descriptor.DefaultDependencyDescriptor
的用法示例。
在下文中一共展示了DefaultDependencyDescriptor.addExcludeRule方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: addExcludes
import org.apache.ivy.core.module.descriptor.DefaultDependencyDescriptor; //导入方法依赖的package包/类
private void addExcludes(String configuration, Set<ExcludeRule> excludeRules,
DefaultDependencyDescriptor dependencyDescriptor) {
for (ExcludeRule excludeRule : excludeRules) {
dependencyDescriptor.addExcludeRule(configuration, excludeRuleConverter.createExcludeRule(configuration,
excludeRule));
}
}
示例2: addArtifact
import org.apache.ivy.core.module.descriptor.DefaultDependencyDescriptor; //导入方法依赖的package包/类
public void addArtifact(String groupId, String artifactId, String version) throws Exception {
String[] dep = null;
dep = new String[] { groupId, artifactId, version };
if (md == null) {
md = DefaultModuleDescriptor.newDefaultInstance(ModuleRevisionId.newInstance(dep[0], dep[1] + "-caller",
"working"));
}
DefaultDependencyDescriptor dd = new DefaultDependencyDescriptor(md, ModuleRevisionId.newInstance(dep[0],
dep[1], dep[2]), false, false, true);
md.addDependency(dd);
ExcludeRule er = new DefaultExcludeRule(new ArtifactId(new ModuleId("org.walkmod", "walkmod-core"),
PatternMatcher.ANY_EXPRESSION, PatternMatcher.ANY_EXPRESSION, PatternMatcher.ANY_EXPRESSION),
ExactPatternMatcher.INSTANCE, null);
dd.addExcludeRule(null, er);
}