Package org.apache.ivy.core.resolve.IvyNodeEviction

Examples of org.apache.ivy.core.resolve.IvyNodeEviction.EvictionData


            details.append(XMLHelper.escape(
                dep.getModuleRevision().getArtifactResolver().getName()));
            details.append("\"");
        }
        if (dep.isEvicted(report.getConfiguration())) {
            EvictionData ed = dep.getEvictedData(report.getConfiguration());
            if (ed.getConflictManager() != null) {
                details.append(" evicted=\"").append(
                    XMLHelper.escape(ed.getConflictManager().toString())).append("\"");
            } else {
                details.append(" evicted=\"transitive\"");
            }
            details.append(" evicted-reason=\"")
                .append(XMLHelper.escape(ed.getDetail() == null ? "" : ed.getDetail()))
                .append("\"");
        }
        if (dep.hasProblem()) {
            details.append(" error=\"").append(
                XMLHelper.escape(dep.getProblem().getMessage())).append("\"");
View Full Code Here


    }

    private void outputEvictionInformation(ConfigurationResolveReport report, PrintWriter out,
            IvyNode dep) {
        if (dep.isEvicted(report.getConfiguration())) {
            EvictionData ed = dep.getEvictedData(report.getConfiguration());
            Collection selected = ed.getSelected();
            if (selected != null) {
                for (Iterator it3 = selected.iterator(); it3.hasNext();) {
                    IvyNode sel = (IvyNode) it3.next();
                    out.println("\t\t\t\t<evicted-by rev=\""
                            + XMLHelper.escape(sel.getResolvedId().getRevision()) + "\"/>");
View Full Code Here

                    Message.info("\t" + evicted[i] + " by " + allEvictingNodes + " in "
                            + Arrays.asList(evicted[i].getEvictedConfs()));
                }
                String[] confs = evicted[i].getEvictedConfs();
                for (int j = 0; j < confs.length; j++) {
                    EvictionData evictedData = evicted[i].getEvictedData(confs[j]);
                    if (evictedData.getParent() != null) {
                        Message.verbose("\t  in " + evictedData.getParent() + " with "
                                + evictedData.getConflictManager());
                    }
                }
            }
        }
View Full Code Here

            }

            String rootModuleConf =
                parent.getData().getReport().getConfiguration();
            evicted.markEvicted(
                new EvictionData(rootModuleConf, parent, this, Collections.singleton(selected),
                    "with blacklisting of " + blacklisted));

            if (settings.debugConflictResolution()) {
                Message.debug("evicting " + evicted + " by "
                    + evicted.getEvictedData(rootModuleConf));
View Full Code Here

            details.append(XMLHelper.escape(
                dep.getModuleRevision().getArtifactResolver().getName()));
            details.append("\"");
        }
        if (dep.isEvicted(report.getConfiguration())) {
            EvictionData ed = dep.getEvictedData(report.getConfiguration());
            if (ed.getConflictManager() != null) {
                details.append(" evicted=\"").append(
                    XMLHelper.escape(ed.getConflictManager().toString())).append("\"");
            } else {
                details.append(" evicted=\"transitive\"");
            }
            details.append(" evicted-reason=\"")
                .append(XMLHelper.escape(ed.getDetail() == null ? "" : ed.getDetail()))
                .append("\"");
        }
        if (dep.hasProblem()) {
            details.append(" error=\"").append(
                XMLHelper.escape(dep.getProblem().getMessage())).append("\"");
        }
        if (md != null && md.getHomePage() != null) {
            details.append(" homepage=\"").append(
                XMLHelper.escape(md.getHomePage())).append("\"");
        }
        extraAttributes = md != null ? md.getExtraAttributes() : dep.getResolvedId()
                .getExtraAttributes();
        for (Iterator iterator = extraAttributes.keySet().iterator(); iterator.hasNext();) {
            String attName = (String) iterator.next();
            details.append(" extra-").append(attName).append("=\"").append(
                XMLHelper.escape(extraAttributes.get(attName).toString())).append("\"");
        }
        String defaultValue = dep.getDescriptor() != null ? " default=\""
                + dep.getDescriptor().isDefault() + "\"" : "";
        int position = dependencies.indexOf(dep.getResolvedId());
        out.println("\t\t\t<revision name=\""
                + XMLHelper.escape(dep.getResolvedId().getRevision())
                + "\""
                + (dep.getResolvedId().getBranch() == null ? "" : " branch=\""
                        + XMLHelper.escape(
                            dep.getResolvedId().getBranch()) + "\"") + details
                + " downloaded=\"" + dep.isDownloaded() + "\"" + " searched=\""
                + dep.isSearched() + "\"" + defaultValue + " conf=\""
                + toString(dep.getConfigurations(report.getConfiguration())) + "\""
                + " position=\"" + position + "\">");
        if (md != null) {
            License[] licenses = md.getLicenses();
            for (int i = 0; i < licenses.length; i++) {
                String lurl;
                if (licenses[i].getUrl() != null) {
                    lurl = " url=\"" + XMLHelper.escape(licenses[i].getUrl()) + "\"";
                } else {
                    lurl = "";
                }
                out.println("\t\t\t\t<license name=\""
                    + XMLHelper.escape(licenses[i].getName()) + "\""
                        + lurl + "/>");
            }
        }
        if (dep.isEvicted(report.getConfiguration())) {
            EvictionData ed = dep.getEvictedData(report.getConfiguration());
            Collection selected = ed.getSelected();
            if (selected != null) {
                for (Iterator it3 = selected.iterator(); it3.hasNext();) {
                    IvyNode sel = (IvyNode) it3.next();
                    out.println("\t\t\t\t<evicted-by rev=\""
                            + XMLHelper.escape(sel.getResolvedId().getRevision()) + "\"/>");
View Full Code Here

TOP

Related Classes of org.apache.ivy.core.resolve.IvyNodeEviction.EvictionData

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.