當前位置: 首頁>>代碼示例>>Java>>正文


Java ConflictManager類代碼示例

本文整理匯總了Java中org.apache.ivy.plugins.conflict.ConflictManager的典型用法代碼示例。如果您正苦於以下問題:Java ConflictManager類的具體用法?Java ConflictManager怎麽用?Java ConflictManager使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


ConflictManager類屬於org.apache.ivy.plugins.conflict包,在下文中一共展示了ConflictManager類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: getConflictManager

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public synchronized ConflictManager getConflictManager(ModuleId moduleId) {
    ModuleSettings ms = moduleSettings.getRule(moduleId, new Filter<ModuleSettings>() {
        public boolean accept(ModuleSettings o) {
            return o.getConflictManager() != null;
        }
    });
    if (ms == null) {
        return getDefaultConflictManager();
    } else {
        ConflictManager cm = getConflictManager(ms.getConflictManager());
        if (cm == null) {
            throw new IllegalStateException("ivy badly configured: unknown conflict manager "
                    + ms.getConflictManager());
        }
        return cm;
    }
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:18,代碼來源:IvySettings.java

示例2: addConflict

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
void addConflict(DefaultModuleDescriptor md, IvySettings settings) {
    String matcherName = (matcher == null) ? PatternMatcher.EXACT : matcher;
    String orgPattern = (org == null) ? PatternMatcher.ANY_EXPRESSION : org;
    String modulePattern = (module == null) ? PatternMatcher.ANY_EXPRESSION : module;
    ConflictManager cm = null;
    if (rev != null) {
        cm = new FixedConflictManager(splitToArray(rev));
    } else if (manager != null) {
        cm = settings.getConflictManager(manager);
    }
    md.addConflictManager(new ModuleId(orgPattern, modulePattern),
        settings.getMatcher(matcherName), cm);
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:14,代碼來源:IvyConflict.java

示例3: resolveConflicts

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
private Collection<IvyNode> resolveConflicts(VisitNode node, VisitNode ancestor,
        Collection<IvyNode> conflicts, ConflictManager conflictManager) {
    if (node.getParent() != ancestor
    // we are not handling the direct parent

            && conflictManager == settings.getConflictManager(node.getModuleId())
            // the conflict manager is the default one

            && node.getParent().getNode()
                    .getResolvedNodes(node.getModuleId(), node.getRootModuleConf())
                    .equals(conflicts)
    // there is no new conflict in this ancestor

    ) {
        // IVY-465 case
        if (settings.debugConflictResolution()) {
            Message.debug("no new conflicting revisions for " + node + " in " + ancestor + ": "
                    + conflicts);
        }

        return conflicts;
    } else {
        if (settings.debugConflictResolution()) {
            Message.debug("found conflicting revisions for " + node + " in " + ancestor + ": "
                    + conflicts);
        }

        return conflictManager.resolveConflicts(ancestor.getNode(), conflicts);
    }
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:31,代碼來源:ResolveEngine.java

示例4: getAllEvictingConflictManagers

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public Collection<ConflictManager> getAllEvictingConflictManagers() {
    Collection<ConflictManager> ret = new HashSet<>();
    for (EvictionData ed : evicted.values()) {
        ret.add(ed.getConflictManager());
    }
    return ret;
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:8,代碼來源:IvyNodeEviction.java

示例5: getConflictManager

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public ConflictManager getConflictManager(ModuleId mid) {
    if (md == null) {
        throw new IllegalStateException(
                "impossible to get conflict manager when data has not been loaded. IvyNode = "
                        + this);
    }
    ConflictManager cm = md.getConflictManager(mid);
    return cm == null ? settings.getConflictManager(mid) : cm;
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:10,代碼來源:IvyNode.java

示例6: managerStarted

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
protected void managerStarted(Attributes attributes, String managerAtt) {
    String org = settings.substitute(attributes.getValue("org"));
    if (org == null) {
        org = PatternMatcher.ANY_EXPRESSION;
    }
    String mod = settings.substitute(attributes.getValue("module"));
    if (mod == null) {
        mod = PatternMatcher.ANY_EXPRESSION;
    }
    ConflictManager cm;
    String name = settings.substitute(attributes.getValue(managerAtt));
    String rev = settings.substitute(attributes.getValue("rev"));
    if (rev != null) {
        cm = new FixedConflictManager(splitToArray(rev));
    } else if (name != null) {
        cm = settings.getConflictManager(name);
        if (cm == null) {
            addError("unknown conflict manager: " + name);
            return;
        }
    } else {
        addError("bad conflict manager: no manager nor rev");
        return;
    }
    String matcherName = settings.substitute(attributes.getValue("matcher"));
    PatternMatcher matcher = (matcherName == null) ? defaultMatcher
            : settings.getMatcher(matcherName);
    if (matcher == null) {
        addError("unknown matcher: " + matcherName);
        return;
    }
    getMd().addConflictManager(new ModuleId(org, mod), matcher, cm);
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:34,代碼來源:XmlModuleDescriptorParser.java

示例7: getConflictManager

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public ConflictManager getConflictManager(String name) {
    return settings.getConflictManager(name);
}
 
開發者ID:Pushjet,項目名稱:Pushjet-Android,代碼行數:4,代碼來源:LegacyResolverParserSettings.java

示例8: getConflictManager

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public ConflictManager getConflictManager() {
    return conflictManager;
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:4,代碼來源:IvyNodeEviction.java

示例9: getAllEvictingConflictManagers

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public Collection<ConflictManager> getAllEvictingConflictManagers() {
    return eviction.getAllEvictingConflictManagers();
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:4,代碼來源:IvyNode.java

示例10: markEvicted

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public void markEvicted(String rootModuleConf, IvyNode node, ConflictManager conflictManager,
        Collection<IvyNode> resolved) {
    EvictionData evictionData = new EvictionData(rootModuleConf, node, conflictManager,
            resolved);
    markEvicted(evictionData);
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:7,代碼來源:IvyNode.java

示例11: getConflictManager

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public ConflictManager getConflictManager(ModuleId moduleId) {
    return conflictManagers.getRule(moduleId);
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:4,代碼來源:DefaultModuleDescriptor.java

示例12: getConflictManager

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public ConflictManager getConflictManager(String name) {
    return delegate.getConflictManager(name);
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:4,代碼來源:DefaultResolutionCacheManager.java

示例13: getConflictManager

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public ConflictManager getConflictManager(String name) {
    return delegatedSettings.getConflictManager(name);
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:4,代碼來源:ParserSettingsMonitor.java

示例14: addConfigured

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public synchronized void addConfigured(ConflictManager cm) {
    addConflictManager(cm.getName(), cm);
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:4,代碼來源:IvySettings.java

示例15: addConflictManager

import org.apache.ivy.plugins.conflict.ConflictManager; //導入依賴的package包/類
public synchronized void addConflictManager(String name, ConflictManager cm) {
    init(cm);
    conflictsManager.put(name, cm);
}
 
開發者ID:apache,項目名稱:ant-ivy,代碼行數:5,代碼來源:IvySettings.java


注:本文中的org.apache.ivy.plugins.conflict.ConflictManager類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。