ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From xav...@apache.org
Subject svn commit: r679833 [2/3] - in /ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse: ./ META-INF/ src/java/org/apache/ivyde/common/ src/java/org/apache/ivyde/common/completion/ src/java/org/apache/ivyde/common/ivyfile/ src/java/org/apache/ivyde/common/model/ ...
Date Fri, 25 Jul 2008 15:26:56 GMT
Copied: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModel.java (from r669878, ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/IvyModel.java)
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModel.java?p2=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModel.java&p1=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/IvyModel.java&r1=669878&r2=679833&rev=679833&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/IvyModel.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModel.java Fri Jul 25 08:26:55 2008
@@ -15,13 +15,9 @@
  *  limitations under the License.
  *
  */
-package org.apache.ivyde.eclipse.ui.core.model;
+package org.apache.ivyde.common.model;
 
 import java.io.IOException;
-import java.text.ParseException;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Date;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
@@ -29,669 +25,16 @@
 import java.util.Properties;
 
 import org.apache.ivy.Ivy;
-import org.apache.ivy.core.IvyPatternHelper;
-import org.apache.ivy.core.module.descriptor.DefaultDependencyDescriptor;
-import org.apache.ivy.core.module.id.ModuleRevisionId;
-import org.apache.ivy.core.resolve.ResolveData;
-import org.apache.ivy.core.resolve.ResolveOptions;
-import org.apache.ivy.core.resolve.ResolvedModuleRevision;
-import org.apache.ivy.plugins.resolver.DependencyResolver;
-import org.apache.ivyde.eclipse.IvyPlugin;
-import org.apache.ivyde.eclipse.cpcontainer.IvyClasspathContainer;
-import org.apache.ivyde.eclipse.cpcontainer.IvyClasspathUtil;
-import org.apache.ivyde.eclipse.ui.preferences.PreferenceConstants;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jdt.core.IJavaProject;
-
-public class IvyModel {
-    private IJavaProject _javaProject;
 
+public abstract class IvyModel {
     private final Map MODEL = new HashMap();
 
     private Properties _defaults;
+    private IvyModelSettings settings;
 
-    public IvyModel(IJavaProject javaProject) {
-        _javaProject = javaProject;
-
+    public IvyModel(IvyModelSettings settings) {
         loadDefaults();
-        // ivy-module
-        IvyTag ivyTag = new IvyTag("ivy-module", "root tag of ivy file");
-        ivyTag.setDoc("Root tag of any ivy-file.");
-        ivyTag
-                .addAttribute(new IvyTagAttribute(
-                        "version",
-                        "The version of the ivy file specification \nshould be '1.0' with current version of ivy",
-                        true));
-        MODEL.put(ivyTag.getName(), ivyTag);
-
-        // info
-        IvyTagAttribute orgTagAttribute = new IvyTagAttribute("organisation",
-                "the name of the organisation that is the owner of this module.", true);
-        orgTagAttribute.setValueProvider(new PreferenceValueProvider(
-                PreferenceConstants.ORGANISATION));
-        IvyTagAttribute statusTagAttribute = new IvyTagAttribute("status",
-                "the status of this module.");
-        statusTagAttribute.setValueProvider(new ListValueProvider(_defaults.getProperty("status")));
-        IvyTagAttribute pubTagAttribute = new IvyTagAttribute("publication",
-                "the date of publication of this module. \nIt should be given in this format: yyyyMMddHHmmss");
-        pubTagAttribute.setValueProvider(new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                return new String[] {Ivy.DATE_FORMAT.format(new Date())};
-            }
-        });
-        IvyTagAttribute moduleTagAttribute = new IvyTagAttribute("module",
-                "the name of the module described by this ivy file.", true);
-        IValueProvider projectNameValueProvider = new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                return new String[] {ivyFile.getProjectName()};
-            }
-        };
-        moduleTagAttribute.setValueProvider(projectNameValueProvider);
-        IvyTag info = new IvyTag("info", "gives general information about the described module",
-                new IvyTagAttribute[] {orgTagAttribute, moduleTagAttribute,
-                        new IvyTagAttribute("branch", "the branch of this module."),
-                        new IvyTagAttribute("revision", "the revision of this module."),
-                        statusTagAttribute, pubTagAttribute});
-        MODEL.put(info.getName(), info);
-        IvyTag child = new IvyTag("license",
-                "gives information about the licenses of the described module");
-        child
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of the license. \nTry to respect spelling when using a classical license.",
-                        true, new ListValueProvider(_defaults.getProperty("license"))));
-        child
-                .addAttribute(new IvyTagAttribute("url", "an url pointing to the license text.",
-                        false));
-        MODEL.put(child.getName(), child);
-        info.addChildIvyTag(child);
-        child = new IvyTag("ivyauthor", "describes who has contributed to write the ivy file");
-        child.addAttribute(new IvyTagAttribute("name",
-                "the name of the author, as a person or a company.", true,
-                new PreferenceValueProvider(PreferenceConstants.ORGANISATION)));
-        child.addAttribute(new IvyTagAttribute("url",
-                "an url pointing to where the author can be reached.", false,
-                new PreferenceValueProvider(PreferenceConstants.ORGANISATION_URL)));
-        MODEL.put(child.getName(), child);
-        info.addChildIvyTag(child);
-        child = new IvyTag("repository",
-                "describes on which public repositories this module can be found");
-        child
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of the repository. \nTry to respect spelling for common repositories (ibiblio, ivyrep, ...)",
-                        true, new IValueProvider() {
-                            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                                return new String[] {"ibiblio", "ivyrep"};
-                            }
-                        }));
-        child.addAttribute(new IvyTagAttribute("url", "an url pointing to the repository.", true,
-                new IValueProvider() {
-                    public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                        Map allAttsValues = ivyFile.getAllAttsValues();
-                        if (allAttsValues != null) {
-                            String name = (String) allAttsValues.get("name");
-                            if ("ibiblio".equals(name)) {
-                                return new String[] {"http://www.ibiblio.org/maven/"};
-                            } else if ("ivyrep".equals(name)) {
-                                return new String[] {"http://www.jayasoft.fr/org/ivyrep/"};
-                            }
-                        }
-                        return null;
-                    }
-
-                }));
-        IvyTagAttribute reppatternTagAttribute = new IvyTagAttribute("pattern",
-                "an ivy pattern to find modules on this repository", false);
-        reppatternTagAttribute.setValueProvider(new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                Map allAttsValues = ivyFile.getAllAttsValues();
-                if (allAttsValues != null) {
-                    String name = (String) allAttsValues.get("name");
-                    if ("ibiblio".equals(name)) {
-                        return new String[] {"[module]/[type]s/[artifact]-[revision].[ext]"};
-                    } else if ("ivyrep".equals(name)) {
-                        return new String[] {"[organisation]/[module]/[artifact]-[revision].[ext]"};
-                    }
-                }
-                return null;
-            }
-        });
-        child.addAttribute(reppatternTagAttribute);
-        child.addAttribute(new IvyBooleanTagAttribute("ivys",
-                "true if ivy file can be found on this repository", false));
-        child.addAttribute(new IvyBooleanTagAttribute("artifacts",
-                "true if module artifacts can be found on this repository", false));
-        MODEL.put(child.getName(), child);
-        info.addChildIvyTag(child);
-        child = new IvyTag("description", "gives general description about the module");
-        child.addAttribute(new IvyTagAttribute("homepage", "the url of the homepage of the module",
-                false, new PreferenceValueProvider(PreferenceConstants.ORGANISATION_URL)));
-        MODEL.put(child.getName(), child);
-        info.addChildIvyTag(child);
-        ivyTag.addChildIvyTag(info);
-
-        // configurations
-        IvyTag configurations = new IvyTag("configurations", "container for configuration elements");
-        IvyTag conf = new IvyTag("conf", "declares a configuration of this module");
-        conf.addAttribute(new IvyTagAttribute("name", "the name of the declared configuration",
-                true));
-        conf.addAttribute(new IvyTagAttribute("description",
-                "a short description for the declared configuration", false));
-        IvyTagAttribute visibilityTagAttribute = new IvyTagAttribute(
-                "visibility",
-                "the visibility of the declared configuration.\n'public' means that this configuration can be used by other modules, \nwhile 'private' means that this configuration is used only in the module itself, \nand is not exposed to other modules",
-                false);
-        visibilityTagAttribute.setValueProvider(new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                return new String[] {"public", "private"};
-            }
-        });
-        conf.addAttribute(visibilityTagAttribute);
-        IvyTagAttribute confExtTagAttribute = new IvyTagAttribute(
-                "extends",
-                "a comma separated list of configurations of this module \nthat the current configuration extends",
-                false);
-        IValueProvider masterConfsValueProvider = new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                StringBuffer base = new StringBuffer();
-                String qualifier = ivyFile.getAttributeValueQualifier();
-                int comma = qualifier.lastIndexOf(",") + 1;
-                base.append(qualifier.substring(0, comma));
-                qualifier = qualifier.substring(comma);
-                while (qualifier.length() > 0 && qualifier.charAt(0) == ' ') {
-                    base.append(' ');
-                    qualifier = qualifier.substring(1);
-                }
-                String[] confs = ivyFile.getConfigurationNames();
-                for (int i = 0; i < confs.length; i++) {
-                    confs[i] = base + confs[i];
-                }
-                return confs;
-            }
-        };
-        IValueProvider masterConfValueProvider = new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                return ivyFile.getConfigurationNames();
-            }
-        };
-        confExtTagAttribute.setValueProvider(masterConfsValueProvider);
-        conf.addAttribute(confExtTagAttribute);
-        IvyTagAttribute deprecatedTagAttribute = new IvyTagAttribute(
-                "deprecated",
-                "indicates that this conf has been deprecated \nby giving the date of the deprecation. \nIt should be given in this format: yyyyMMddHHmmss",
-                false);
-        deprecatedTagAttribute.setValueProvider(new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                return new String[] {Ivy.DATE_FORMAT.format(new Date())};
-            }
-        });
-        conf.addAttribute(deprecatedTagAttribute);
-        configurations.addChildIvyTag(conf);
-        List allConf = new ArrayList();
-        allConf.add(conf);
-        MODEL.put(conf.getName(), allConf);
-        ivyTag.addChildIvyTag(configurations);
-        MODEL.put(configurations.getName(), configurations);
-
-        // configurations
-        IvyTag publications = new IvyTag("publications",
-                "container for published artifact elements");
-        IvyTag artifact = new IvyTag("artifact", "declares a published artifact for this module");
-        artifact.addAttribute(new IvyTagAttribute("name",
-                "the name of the published artifact. This name must not include revision.", true,
-                projectNameValueProvider));
-        artifact
-                .addAttribute(new IvyTagAttribute(
-                        "type",
-                        "the type of the published artifact. \nIt's usually its extension, but not necessarily. \nFor instance, ivy files are of type 'ivy' but have 'xml' extension",
-                        true, new ListValueProvider(_defaults.getProperty("type"))));
-        artifact.addAttribute(new IvyTagAttribute("ext", "the extension of the published artifact",
-                false, new ListValueProvider(_defaults.getProperty("ext"))));
-        artifact
-                .addAttribute(new IvyTagAttribute(
-                        "conf",
-                        "comma separated list of public configurations in which this artifact is published. \n'*' wildcard can be used to designate all public configurations of this module",
-                        false, masterConfsValueProvider));
-        IvyTag conf2 = new IvyTag("conf",
-                "indicates a public configuration in which this artifact is published");
-        conf2
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of a module public configuration in which this artifact is published. \n'*' wildcard can be used to designate all public configurations of this module",
-                        true, masterConfValueProvider));
-        allConf.add(conf2);
-        artifact.addChildIvyTag(conf2);
-        publications.addChildIvyTag(artifact);
-        MODEL.put(publications.getName(), publications);
-        MODEL.put(artifact.getName(), artifact);
-        ivyTag.addChildIvyTag(publications);
-
-        // dependencies
-        IvyTag dependencies = new IvyTag("dependencies", "container for dependency elements");
-        // dependency
-        IvyTag dependency = new IvyTag("dependency", "declares a dependency for this module") {
-            public String[] getPossibleValuesForAttribute(String att, IvyFile ivyfile) {
-                String[] r = super.getPossibleValuesForAttribute(att, ivyfile);
-                if (r == null) { // listing can be used even for extra attributes
-                    List ret = listDependencyTokenValues(att, ivyfile);
-                    return (String[]) ret.toArray(new String[ret.size()]);
-                } else {
-                    return r;
-                }
-            }
-        };
-        IvyTagAttribute orgAtt = new IvyTagAttribute("org",
-                "the name of the organisation of the dependency.", false);
-        orgAtt.setValueProvider(new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                List ret = listDependencyTokenValues(att.getName(), ivyFile);
-                ret.add(IvyPlugin.getDefault().getPreferenceStore().getString(
-                    PreferenceConstants.ORGANISATION));
-                String org = ivyFile.getOrganisation();
-                if (org != null) {
-                    ret.add(org);
-                }
-                return (String[]) ret.toArray(new String[ret.size()]);
-            }
-
-        });
-        dependency.addAttribute(orgAtt);
-        IvyTagAttribute module = new IvyTagAttribute("name", "the module name of the dependency",
-                true);
-        module.setValueProvider(new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                List ret = listDependencyTokenValues(att.getName(), ivyFile);
-                return (String[]) ret.toArray(new String[ret.size()]);
-            }
-        });
-        dependency.addAttribute(module);
-        IvyTagAttribute branch = new IvyTagAttribute("branch",
-                "the branch of the dependency. \nDo not set if not needed.", false);
-        branch.setValueProvider(new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                List ret = listDependencyTokenValues(att.getName(), ivyFile);
-                return (String[]) ret.toArray(new String[ret.size()]);
-            }
-        });
-        dependency.addAttribute(branch);
-        IvyTagAttribute rev = new IvyTagAttribute(
-                "rev",
-                "the revision of the dependency. \nUse 'latest.integration' to get the latest version of the dependency. \nYou can also end the revision asked with a '+' to get the latest matching revision.",
-                true);
-        rev.setValueProvider(new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                List ret = listDependencyTokenValues(att.getName(), ivyFile);
-                ret.add("latest.integration");
-                return (String[]) ret.toArray(new String[ret.size()]);
-            }
-        });
-        dependency.addAttribute(rev);
-        dependency
-                .addAttribute(new IvyBooleanTagAttribute(
-                        "force",
-                        "a boolean to give an indication to conflict manager \nthat this dependency should be forced to this revision",
-                        false));
-        dependency.addAttribute(new IvyBooleanTagAttribute("transitive",
-                "a boolean indicating if this dependency should be resolved transitively or not",
-                false));
-        IvyTagAttribute confAtt = new IvyTagAttribute("conf",
-                "an inline mapping configuration spec", false);
-        dependency.addAttribute(confAtt);
-        confAtt.setValueProvider(new IValueProvider() {
-            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                String qualifier = ivyFile.getAttributeValueQualifier();
-                int index = qualifier.lastIndexOf(';') + 1;
-                StringBuffer base = new StringBuffer(qualifier.substring(0, index));
-                qualifier = qualifier.substring(index);
-                int arrowIndex = qualifier.indexOf("->");
-                if (arrowIndex > -1) {
-                    // we are looking for a dep conf
-                    String org = ivyFile.getDependencyOrganisation();
-                    Map otherAttValues = ivyFile.getAllAttsValues();
-                    if (org != null && otherAttValues != null && otherAttValues.get("name") != null
-                            && otherAttValues.get("rev") != null) {
-                        otherAttValues.remove("org");
-                        String branch = (String) otherAttValues.remove("branch");
-                        otherAttValues.remove("conf");
-                        otherAttValues.remove("force");
-                        otherAttValues.remove("transitive");
-                        otherAttValues.remove("changing");
-                        return getDependencyConfs(org, (String) otherAttValues.remove("name"),
-                            branch, (String) otherAttValues.remove("rev"), otherAttValues,
-                            qualifier, base, arrowIndex);
-                    }
-
-                } else {
-                    // we are looking for a master conf
-                    return getMasterConfs(ivyFile, qualifier, base, arrowIndex);
-                }
-
-                return null;
-            }
-
-            private String[] getMasterConfs(IvyFile ivyFile, String qualifier, StringBuffer base,
-                    int arrowIndex) {
-                // search for word after last comma
-                int comma = qualifier.lastIndexOf(",") + 1;
-                base.append(qualifier.substring(0, comma));
-                qualifier = qualifier.substring(comma);
-                while (qualifier.length() > 0 && qualifier.charAt(0) == ' ') {
-                    base.append(' ');
-                    qualifier = qualifier.substring(1);
-                }
-                String[] confs = ivyFile.getConfigurationNames();
-                for (int i = 0; i < confs.length; i++) {
-                    confs[i] = base + confs[i];
-                }
-                List ret = new ArrayList(Arrays.asList(confs));
-                ret.add("*");
-                return (String[]) ret.toArray(new String[ret.size()]);
-            }
-
-            private String[] getDependencyConfs(String org, String name, String branch, String rev,
-                    Map otherAtts, String qualifier, StringBuffer base, int arrowIndex) {
-                Ivy ivy = getIvy();
-                if (ivy == null) {
-                    return null;
-                }
-                base.append(qualifier.substring(0, arrowIndex + 2));
-                qualifier = qualifier.substring(arrowIndex + 2);
-                // search for word after last comma
-                int comma = qualifier.lastIndexOf(",") + 1;
-                base.append(qualifier.substring(0, comma));
-                qualifier = qualifier.substring(comma);
-                while (qualifier.length() > 0 && qualifier.charAt(0) == ' ') {
-                    base.append(' ');
-                    qualifier = qualifier.substring(1);
-                }
-                ResolveData data = new ResolveData(ivy.getResolveEngine(), new ResolveOptions());
-                ModuleRevisionId mrid = ModuleRevisionId.newInstance(org, name, branch, rev,
-                    otherAtts);
-                DefaultDependencyDescriptor ddd = new DefaultDependencyDescriptor(mrid, false);
-                try {
-                    DependencyResolver resolver = ivy.getSettings().getResolver(mrid);
-                    if (resolver == null) {
-                        return null;
-                    }
-                    ResolvedModuleRevision dep = resolver.getDependency(ddd, data);
-                    if (dep == null) {
-                        return null;
-                    }
-                    String[] confs = dep.getDescriptor().getConfigurationsNames();
-                    for (int i = 0; i < confs.length; i++) {
-                        confs[i] = base + confs[i];
-                    }
-                    List ret = new ArrayList(Arrays.asList(confs));
-                    ret.add("*");
-                    return (String[]) ret.toArray(new String[ret.size()]);
-                } catch (ParseException e) {
-                    IvyPlugin.log(IStatus.ERROR, "The dependencies of " + mrid
-                            + " could not be parsed", e);
-                    return null;
-                }
-            }
-
-        });
-        IvyTag conf3 = new IvyTag("conf", "defines configuration mapping has sub element");
-        conf3
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of the master configuration to map. \n'*' wildcard can be used to designate all configurations of this module",
-                        true, masterConfValueProvider));
-        conf3
-                .addAttribute(new IvyTagAttribute(
-                        "mapped",
-                        "a comma separated list of dependency configurations \nto which this master configuration should be mapped",
-                        false, new IValueProvider() {
-                            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                                Ivy ivy = getIvy();
-                                int[] indexes = ivyFile.getParentTagIndex();
-                                if (indexes != null && ivy != null) {
-                                    Map otherAttValues = ivyFile.getAllAttsValues(indexes[0] + 1);
-                                    String org = ivyFile.getDependencyOrganisation(otherAttValues);
-                                    if (org != null && otherAttValues != null
-                                            && otherAttValues.get("name") != null
-                                            && otherAttValues.get("rev") != null) {
-                                        StringBuffer base = new StringBuffer();
-                                        String qualifier = ivyFile.getAttributeValueQualifier();
-                                        // search for word after last comma
-                                        int comma = qualifier.lastIndexOf(",") + 1;
-                                        base.append(qualifier.substring(0, comma));
-                                        qualifier = qualifier.substring(comma);
-                                        while (qualifier.length() > 0 && qualifier.charAt(0) == ' ') {
-                                            base.append(' ');
-                                            qualifier = qualifier.substring(1);
-                                        }
-                                        ResolveData data = new ResolveData(ivy.getResolveEngine(),
-                                                new ResolveOptions());
-                                        ModuleRevisionId mrid = ModuleRevisionId.newInstance(org,
-                                            (String) otherAttValues.get("name"),
-                                            (String) otherAttValues.get("rev"));
-                                        DefaultDependencyDescriptor ddd = new DefaultDependencyDescriptor(
-                                                mrid, false);
-                                        try {
-                                            String[] confs = ivy.getSettings().getResolver(mrid)
-                                                    .getDependency(ddd, data).getDescriptor()
-                                                    .getConfigurationsNames();
-                                            for (int i = 0; i < confs.length; i++) {
-                                                confs[i] = base + confs[i];
-                                            }
-                                            List ret = new ArrayList(Arrays.asList(confs));
-                                            ret.add("*");
-                                            return (String[]) ret.toArray(new String[ret.size()]);
-                                        } catch (ParseException e) {
-                                            IvyPlugin.log(IStatus.ERROR, "The dependencies of "
-                                                    + mrid + " could not be parsed", e);
-                                            return new String[] {"*"};
-                                        }
-                                    }
-                                }
-                                return new String[] {"*"};
-                            }
-
-                        }));
-        allConf.add(conf3);
-        IvyTag mapped = new IvyTag("mapped",
-                "map dependency configurations for this master configuration");
-        mapped
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of the dependency configuration mapped. \n'*' wildcard can be used to designate all configurations of this module",
-                        true, new IValueProvider() {
-                            public String[] getValuesfor(IvyTagAttribute att, IvyFile ivyFile) {
-                                Ivy ivy = getIvy();
-                                int[] indexes = ivyFile.getParentTagIndex();
-                                if (indexes != null && ivy != null) {
-                                    indexes = ivyFile.getParentTagIndex(indexes[0]);
-                                    if (indexes != null) {
-                                        Map otherAttValues = ivyFile
-                                                .getAllAttsValues(indexes[0] + 1);
-                                        String org = ivyFile
-                                                .getDependencyOrganisation(otherAttValues);
-                                        if (org != null && otherAttValues != null
-                                                && otherAttValues.get("name") != null
-                                                && otherAttValues.get("rev") != null) {
-                                            ResolveData data = new ResolveData(ivy
-                                                    .getResolveEngine(), new ResolveOptions());
-                                            ModuleRevisionId mrid = ModuleRevisionId.newInstance(
-                                                org, (String) otherAttValues.get("name"),
-                                                (String) otherAttValues.get("rev"));
-                                            DefaultDependencyDescriptor ddd = new DefaultDependencyDescriptor(
-                                                    mrid, false);
-                                            try {
-                                                String[] confs = ivy.getSettings()
-                                                        .getResolver(mrid).getDependency(ddd, data)
-                                                        .getDescriptor().getConfigurationsNames();
-                                                List ret = new ArrayList(Arrays.asList(confs));
-                                                ret.add("*");
-                                                return (String[]) ret
-                                                        .toArray(new String[ret.size()]);
-                                            } catch (ParseException e) {
-                                                IvyPlugin.log(IStatus.ERROR, "The dependencies of "
-                                                        + mrid + " could not be parsed", e);
-                                                return new String[] {"*"};
-                                            }
-                                        }
-                                    }
-                                }
-                                return new String[] {"*"};
-                            }
-
-                        }));
-        conf3.addChildIvyTag(mapped);
-        MODEL.put(mapped.getName(), mapped);
-
-        String[] matcherNames = new String[0];
-        Ivy ivy = getIvy();
-        if (ivy != null) {
-            matcherNames = (String[]) ivy.getSettings().getMatcherNames().toArray(new String[0]);
-        }
-        ListValueProvider matcherNamesProvider = new ListValueProvider(matcherNames);
-
-        IvyTag artifact2 = new IvyTag("artifact",
-                "defines artifacts restriction \nuse only if you do not control dependency ivy file");
-        artifact2
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of an artifact of the \ndependency module to add to the include list, \nor a regexp matching this name",
-                        false));
-        artifact2
-                .addAttribute(new IvyTagAttribute(
-                        "type",
-                        "the type of the artifact of the \ndependency module to add to the include list, \nor a regexp matching this name",
-                        false, new ListValueProvider(_defaults.getProperty("type"))));
-        artifact2
-                .addAttribute(new IvyTagAttribute(
-                        "ext",
-                        "the extension of the artifact of the \ndependency module to add to the include list, \nor a regexp matching this name",
-                        false, new ListValueProvider(_defaults.getProperty("ext"))));
-        artifact2
-                .addAttribute(new IvyTagAttribute(
-                        "url",
-                        "an url where this artifact can be found \nif it isn't present at the standard \nlocation in the repository",
-                        false));
-        artifact2
-                .addAttribute(new IvyTagAttribute(
-                        "conf",
-                        "comma separated list of the master configurations \nin which this artifact should be included. \n'*' wildcard can be used to designate all configurations of this module",
-                        false, masterConfsValueProvider));
-        IvyTag conf4 = new IvyTag("conf", "configuration in which the artifact should be included");
-        conf4
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of the master configuration in which \nthe enclosing artifact should be included",
-                        true, masterConfValueProvider));
-        allConf.add(conf4);
-        artifact2.addChildIvyTag(conf4);
-        MODEL.put(artifact2.getName(), artifact2);
-        IvyTag include = new IvyTag("include",
-                "defines artifacts restriction \nuse only if you do not control dependency ivy file");
-        include
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of an artifact of the \ndependency module to add to the include list, \nor a regexp matching this name",
-                        false));
-        include
-                .addAttribute(new IvyTagAttribute(
-                        "type",
-                        "the type of the artifact of the \ndependency module to add to the include list, \nor a regexp matching this name",
-                        false, new ListValueProvider(_defaults.getProperty("type"))));
-        include
-                .addAttribute(new IvyTagAttribute(
-                        "ext",
-                        "the extension of the artifact of the \ndependency module to add to the include list, \nor a regexp matching this name",
-                        false, new ListValueProvider(_defaults.getProperty("ext"))));
-        include.addAttribute(new IvyTagAttribute("matcher",
-                "the matcher to use to match the modules to include", false, matcherNamesProvider));
-        include
-                .addAttribute(new IvyTagAttribute(
-                        "conf",
-                        "comma separated list of the master configurations \nin which this artifact should be included. \n'*' wildcard can be used to designate all configurations of this module",
-                        false, masterConfsValueProvider));
-        IvyTag conf5 = new IvyTag("conf", "configuration in which the artifact should be included");
-        conf5
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of the master configuration in which \nthe enclosing artifact should be included",
-                        true, masterConfValueProvider));
-        include.addChildIvyTag(conf5);
-        MODEL.put(include.getName(), include);
-        allConf.add(conf5);
-        IvyTag exclude = new IvyTag("exclude",
-                "defines artifacts restriction \nuse only if you do not control dependency ivy file");
-        exclude
-                .addAttribute(new IvyTagAttribute(
-                        "org",
-                        "the organisation of the dependency \nmodule or artifact to exclude, \nor a pattern matching this organisation",
-                        false));
-        exclude
-                .addAttribute(new IvyTagAttribute(
-                        "module",
-                        "the name of the dependency \nmodule or the artifact to exclude, \nor a pattern matching this module name",
-                        false));
-        exclude
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of an artifact of the \ndependency module to add to the exclude list, \nor a pattern matching this name",
-                        false));
-        exclude
-                .addAttribute(new IvyTagAttribute(
-                        "type",
-                        "the type of the artifact of the \ndependency module to add to the exclude list, \nor a pattern matching this name",
-                        false, new ListValueProvider(_defaults.getProperty("type"))));
-        exclude
-                .addAttribute(new IvyTagAttribute(
-                        "ext",
-                        "the extension of the artifact of the \ndependency module to add to the exclude list, \nor a pattern matching this name",
-                        false, new ListValueProvider(_defaults.getProperty("ext"))));
-        exclude.addAttribute(new IvyTagAttribute("matcher",
-                "the matcher to use to match the modules to include", false, matcherNamesProvider));
-        exclude
-                .addAttribute(new IvyTagAttribute(
-                        "conf",
-                        "comma separated list of the master configurations \nin which this artifact should be excluded. \n'*' wildcard can be used to designate all configurations of this module",
-                        false, masterConfsValueProvider));
-        IvyTag conf6 = new IvyTag("conf", "configuration in which the artifact should be excluded");
-        conf6
-                .addAttribute(new IvyTagAttribute(
-                        "name",
-                        "the name of the master configuration in which \nthe enclosing artifact should be excluded",
-                        true, masterConfValueProvider));
-        allConf.add(conf6);
-        exclude.addChildIvyTag(conf6);
-        MODEL.put(exclude.getName(), exclude);
-        dependency.addChildIvyTag(conf3);
-        dependency.addChildIvyTag(artifact2);
-        dependency.addChildIvyTag(include);
-        dependency.addChildIvyTag(exclude);
-        dependencies.addChildIvyTag(dependency);
-        ivyTag.addChildIvyTag(dependencies);
-        MODEL.put(dependency.getName(), dependency);
-        MODEL.put(dependencies.getName(), dependencies);
-
-        // dependencies
-
-        IvyTag conflicts = new IvyTag("conflicts", "conflicts managers definition section");
-        IvyTag manager = new IvyTag("manager", "declares a conflict manager for this module");
-        manager
-                .addAttribute(new IvyTagAttribute(
-                        "org",
-                        "the name, or a regexp matching the name of organisation \nto which this conflict manager should apply",
-                        false));
-        manager
-                .addAttribute(new IvyTagAttribute(
-                        "module",
-                        "the name, or a regexp matching the name of module \nto which this conflict manager should apply",
-                        false));
-        manager.addAttribute(new IvyTagAttribute("name", "the name of the conflict manager to use",
-                false));
-        manager.addAttribute(new IvyTagAttribute("rev",
-                "a comma separated list of revisions this conflict manager should select", false));
-        conflicts.addChildIvyTag(manager);
-        ivyTag.addChildIvyTag(conflicts);
-        MODEL.put(conflicts.getName(), conflicts);
-        MODEL.put(manager.getName(), manager);
+        this.settings = settings;
     }
 
     public IvyTag getIvyTag(String tagName, String parentName) {
@@ -715,68 +58,53 @@
             _defaults.load(IvyModel.class.getResourceAsStream("defaults.properties"));
         } catch (IOException e) {
             // should never never happen
-            IvyPlugin.log(IStatus.ERROR, "The default properties could not be loaded", e);
+            settings.logError("The default properties could not be loaded", e);
         }
     }
 
     public IvyTag getRootIvyTag() {
-        return (IvyTag) MODEL.get("ivy-module");
+        return (IvyTag) MODEL.get(getRootIvyTagName());
     }
 
-    Ivy getIvy() {
-        return IvyPlugin.getIvy(_javaProject);
-    }
+    protected abstract String getRootIvyTagName();
 
-    List listDependencyTokenValues(String att, IvyFile ivyfile) {
-        Map allAttsValues = ivyfile.getAllAttsValues();
-        String org = ivyfile.getOrganisation();
-        if (org != null && !allAttsValues.containsKey("org")) {
-            allAttsValues.put("org", org);
-        }
-        return listDependencyTokenValues(att, allAttsValues);
+    protected Ivy getIvy() {
+        return settings.getIvyInstance();
+    }
+    
+    public IvyModelSettings getSettings() {
+        return settings;
     }
+    
 
-    private List listDependencyTokenValues(String att, Map otherAttValues) {
-        List ret = new ArrayList();
-        Ivy ivy = getIvy();
-        if (ivy != null) {
-            replaceToken(otherAttValues, "org", IvyPatternHelper.ORGANISATION_KEY);
-            replaceToken(otherAttValues, "name", IvyPatternHelper.MODULE_KEY);
-            replaceToken(otherAttValues, "rev", IvyPatternHelper.REVISION_KEY);
-
-            if (!otherAttValues.containsKey(IvyPatternHelper.BRANCH_KEY)) {
-                otherAttValues.put(IvyPatternHelper.BRANCH_KEY, ivy.getSettings()
-                        .getDefaultBranch());
-            }
+    protected void addTag(String name, List list) {
+        MODEL.put(name, list);
+    }
 
-            String stdAtt = standardiseDependencyAttribute(att);
-            otherAttValues.remove(stdAtt);
-            String[] revs = ivy.listTokenValues(stdAtt, otherAttValues);
-            if (revs != null) {
-                ret.addAll(Arrays.asList(revs));
+    protected void addTag(IvyTag ivyTag) {
+        if (!MODEL.containsKey(ivyTag.getName())) {
+            MODEL.put(ivyTag.getName(), ivyTag);
+            for (Iterator it = ivyTag.getChilds().iterator(); it.hasNext();) {
+                IvyTag child = (IvyTag) it.next();
+                addTag(child);
             }
+        } else {
+            // the model already contains a tag for this name... maybe we should add it to a list, 
+            // but we still have problem of tags with infinite children hierarchy (like chain of chain)
+            // where we need to stop adding children somewhere.
         }
-        return ret;
     }
-
-    private void replaceToken(Map otherAttValues, String oldToken, String newToken) {
-        String val = (String) otherAttValues.remove(oldToken);
-        if (val != null) {
-            otherAttValues.put(newToken, val);
-        }
+    
+    protected String getDefault(String name) {
+        return _defaults.getProperty(name);
     }
 
-    private String standardiseDependencyAttribute(String att) {
-        if ("org".equals(att)) {
-            return IvyPatternHelper.ORGANISATION_KEY;
-        }
-        if ("name".equals(att)) {
-            return IvyPatternHelper.MODULE_KEY;
-        }
-        if ("rev".equals(att)) {
-            return IvyPatternHelper.REVISION_KEY;
-        }
-        return att;
-    }
+    public abstract IvyFile newIvyFile(String name, String content, int documentOffset);
 
+    public void refreshIfNeeded(IvyFile file) {
+    }
+    
+    protected void clearModel() {
+        MODEL.clear();
+    }
 }

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModel.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModelSettings.java
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModelSettings.java?rev=679833&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModelSettings.java (added)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModelSettings.java Fri Jul 25 08:26:55 2008
@@ -0,0 +1,27 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+package org.apache.ivyde.common.model;
+
+import org.apache.ivy.Ivy;
+
+public interface IvyModelSettings {
+    public String getDefaultOrganization();
+    public String getDefaultOrganizationURL();
+    public Ivy getIvyInstance();
+    public void logError(String message, Exception e);
+}

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModelSettings.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyModelSettings.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyReferenceTag.java
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyReferenceTag.java?rev=679833&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyReferenceTag.java (added)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyReferenceTag.java Fri Jul 25 08:26:55 2008
@@ -0,0 +1,27 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+package org.apache.ivyde.common.model;
+
+public class IvyReferenceTag extends IvyTag {
+
+    public IvyReferenceTag(String name) {
+        super(name);
+        addAttribute(new IvyTagAttribute("ref"));
+    }
+
+}

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyReferenceTag.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyReferenceTag.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Copied: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyTag.java (from r669878, ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/IvyTag.java)
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyTag.java?p2=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyTag.java&p1=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/IvyTag.java&r1=669878&r2=679833&rev=679833&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/IvyTag.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyTag.java Fri Jul 25 08:26:55 2008
@@ -15,16 +15,23 @@
  *  limitations under the License.
  *
  */
-package org.apache.ivyde.eclipse.ui.core.model;
+package org.apache.ivyde.common.model;
 
+import java.io.IOException;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.List;
 import java.util.Map;
+import java.util.MissingResourceException;
+import java.util.Properties;
+import java.util.ResourceBundle;
 import java.util.Set;
 
 public class IvyTag {
+    private final static ResourceBundle doc = ResourceBundle.getBundle(
+        IvyTag.class.getPackage().getName() + ".tagsdoc");
+    
     private IvyTag _parent;
 
     private String _name;
@@ -79,9 +86,10 @@
         _attributes.put(attribute.getName(), attribute);
     }
 
-    public void addChildIvyTag(IvyTag att) {
+    public IvyTag addChildIvyTag(IvyTag att) {
         att.setParent(this);
         _childs.add(att);
+        return this;
     }
 
     public boolean hasChild() {
@@ -109,9 +117,23 @@
     }
 
     public String getDoc() {
+        if (_doc == null) {
+            try {
+                _doc = doc.getString(getId());
+            } catch (MissingResourceException ex) {
+                _doc = "";
+            }
+        }
         return _doc;
     }
 
+    public String getId() {
+        if (getParent() != null) {
+            return getParent().getId() + "." + getName();
+        }
+        return getName();
+    }
+
     public void setDoc(String doc) {
         _doc = doc;
     }

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyTag.java
------------------------------------------------------------------------------
    svn:eol-style = native

Copied: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyTagAttribute.java (from r669878, ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/IvyTagAttribute.java)
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyTagAttribute.java?p2=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyTagAttribute.java&p1=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/IvyTagAttribute.java&r1=669878&r2=679833&rev=679833&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/IvyTagAttribute.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyTagAttribute.java Fri Jul 25 08:26:55 2008
@@ -15,14 +15,20 @@
  *  limitations under the License.
  *
  */
-package org.apache.ivyde.eclipse.ui.core.model;
+package org.apache.ivyde.common.model;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
 
 public class IvyTagAttribute {
+    private final static ResourceBundle doc = ResourceBundle.getBundle(
+        IvyTagAttribute.class.getPackage().getName() + ".tagsdoc");
+    
     private IvyTag _container;
 
     private String _name;
 
-    private String _doc = "";
+    private String _doc;
 
     private boolean _mandatory = false;
 
@@ -48,6 +54,11 @@
         _doc = doc;
     }
 
+    public IvyTagAttribute(String name, boolean mandatory) {
+        _name = name;
+        _mandatory = mandatory;
+    }
+
     public IvyTagAttribute(String name, String doc, boolean mandatory) {
         super();
         _name = name;
@@ -75,9 +86,23 @@
     }
 
     public String getDoc() {
+        if (_doc == null) {
+            try {
+                _doc = doc.getString(getId());
+            } catch (MissingResourceException ex) {
+                _doc = "";
+            }
+        }
         return _doc;
     }
 
+    private String getId() {
+        if (getContainer() != null) {
+            return getContainer().getId() + ".@" + getName();
+        }
+        return "@" + getName();
+    }
+
     public void setDoc(String doc) {
         _doc = doc;
     }

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/IvyTagAttribute.java
------------------------------------------------------------------------------
    svn:eol-style = native

Copied: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/ListValueProvider.java (from r669878, ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/ListValueProvider.java)
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/ListValueProvider.java?p2=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/ListValueProvider.java&p1=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/ListValueProvider.java&r1=669878&r2=679833&rev=679833&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/ListValueProvider.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/ListValueProvider.java Fri Jul 25 08:26:55 2008
@@ -15,7 +15,7 @@
  *  limitations under the License.
  *
  */
-package org.apache.ivyde.eclipse.ui.core.model;
+package org.apache.ivyde.common.model;
 
 public class ListValueProvider implements IValueProvider {
 

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/ListValueProvider.java
------------------------------------------------------------------------------
    svn:eol-style = native

Copied: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/Proposal.java (from r669878, ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/Proposal.java)
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/Proposal.java?p2=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/Proposal.java&p1=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/Proposal.java&r1=669878&r2=679833&rev=679833&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/Proposal.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/Proposal.java Fri Jul 25 08:26:55 2008
@@ -15,7 +15,7 @@
  *  limitations under the License.
  *
  */
-package org.apache.ivyde.eclipse.ui.core.model;
+package org.apache.ivyde.common.model;
 
 public class Proposal {
     private int _cursor;

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/Proposal.java
------------------------------------------------------------------------------
    svn:eol-style = native

Copied: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/SingleValueProvider.java (from r669878, ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/SingleValueProvider.java)
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/SingleValueProvider.java?p2=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/SingleValueProvider.java&p1=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/SingleValueProvider.java&r1=669878&r2=679833&rev=679833&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/SingleValueProvider.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/SingleValueProvider.java Fri Jul 25 08:26:55 2008
@@ -15,7 +15,7 @@
  *  limitations under the License.
  *
  */
-package org.apache.ivyde.eclipse.ui.core.model;
+package org.apache.ivyde.common.model;
 
 public class SingleValueProvider extends ListValueProvider {
     public SingleValueProvider(String value) {

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/SingleValueProvider.java
------------------------------------------------------------------------------
    svn:eol-style = native

Copied: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/defaults.properties (from r669878, ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/defaults.properties)
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/defaults.properties?p2=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/defaults.properties&p1=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/core/model/defaults.properties&r1=669878&r2=679833&rev=679833&view=diff
==============================================================================
    (empty)

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/defaults.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Added: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/tagsdoc.properties
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/tagsdoc.properties?rev=679833&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/tagsdoc.properties (added)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/tagsdoc.properties Fri Jul 25 08:26:55 2008
@@ -0,0 +1,199 @@
+# This file is built using the generate-tagsdoc target of the ivy-site build.xml
+
+##### ivysettings.resolvers.chain
+ivysettings.resolvers.chain = This resolver is only a container of a chain of other resolvers.
+ivysettings.resolvers.chain.@returnFirst = true if the first found should be returned.
+ivysettings.resolvers.chain.@dual = true if the chain should behave like a dual chain. since 1.3
+##### ivysettings.resolvers.dual
+ivysettings.resolvers.dual = This resolver delegates its job to one resolver for ivy files and another for artifacts.
+ivysettings.resolvers.dual.@allownomd = true if the absence of module descriptor (usually an ivy file) is authorised for this resolver, false to refuse modules without module descriptor since 1.4
+##### ivysettings.resolvers.filesystem
+ivysettings.resolvers.filesystem = This resolver uses the file system to resolve ivy files and artifacts.
+ivysettings.resolvers.filesystem.@m2compatible = True if this resolver should be maven2 compatible, false otherwise since 1.3
+ivysettings.resolvers.filesystem.@local = True if this resolver should be considered local, false otherwise since 1.4. See useOrigin attribute on the caches element for details.
+ivysettings.resolvers.filesystem.@transactional = true to force the use of transaction, false to prevent the use of transaction, auto to get transaction when possible since 2.0. See above for details.
+##### ivysettings.resolvers.ibiblio
+ivysettings.resolvers.ibiblio = This resolver usually uses ibiblio to find artifacts. 
+ivysettings.resolvers.ibiblio.@root = the root of the artifacts repository.
+ivysettings.resolvers.ibiblio.@pattern = a pattern describing the layout of the artifacts repository.
+ivysettings.resolvers.ibiblio.@m2compatible = True if this resolver should be maven2 compatible, false otherwise since 1.3
+ivysettings.resolvers.ibiblio.@usepoms = True if this resolver should use maven poms when it is already in m2compatible mode, false otherwise since 1.4
+ivysettings.resolvers.ibiblio.@useMavenMetadata = True if this resolver should use maven-metadata.xml files to list available revisions, false to use directory listing since 2.0
+##### ivysettings.resolvers.ivyrep
+ivysettings.resolvers.ivyrep = This resolver usually uses an URL based repository usually similar in structure to ivyrep to find ivy files, and ibiblio to find artifacts.
+ivysettings.resolvers.ivyrep.@ivyroot = the root of the ivy repository.
+ivysettings.resolvers.ivyrep.@ivypattern = a pattern describing the layout of the ivy repository.
+ivysettings.resolvers.ivyrep.@artroot = the root of the artifacts repository.
+ivysettings.resolvers.ivyrep.@artpattern = a pattern describing the layout of the artifacts repository.
+##### ivysettings.resolvers.packager
+ivysettings.resolvers.packager = This resolver accesses ivy files and "packaging instructions" from an online "packager" repository.
+ivysettings.resolvers.packager.@buildRoot = Defines the root of the temporary build directory hierarchy
+ivysettings.resolvers.packager.@resourceCache = Directory where downloaded resources should be cached
+ivysettings.resolvers.packager.@resourceURL = Ivy pattern that specifies a base URL to use for downloading all resources; overrides the URLs in the packaging instructions
+ivysettings.resolvers.packager.@verbose = True to run ant with the -verbose flag
+ivysettings.resolvers.packager.@quiet = True to run ant with the -quiet flag
+ivysettings.resolvers.packager.@validate = True if this resolver should validate (via XSD) the downloaded XML packaging instructions
+ivysettings.resolvers.packager.@preserveBuildDirectories = True if this resolver should not delete the temporary build directories in which the ant tasks are executed (for debugging purposes)
+##### ivysettings.resolvers.sftp
+ivysettings.resolvers.sftp = This resolver can be used when your ivy repository is located on a server accessible via sftp.
+ivysettings.resolvers.sftp.@user = The username to provide as credential
+ivysettings.resolvers.sftp.@userPassword = The password to provide as credential
+ivysettings.resolvers.sftp.@keyFile = Path to the keyfile to use for authentication
+ivysettings.resolvers.sftp.@keyFilePassword = the password used to protect the key file
+ivysettings.resolvers.sftp.@host = The host to connect to
+ivysettings.resolvers.sftp.@port = The port to connect to
+##### ivysettings.resolvers.ssh
+ivysettings.resolvers.ssh = This resolver can be used when your ivy repository is located on a server accessible via ssh.
+ivysettings.resolvers.ssh.@user = The username to provide as credential
+ivysettings.resolvers.ssh.@userPassword = The password to provide as credential
+ivysettings.resolvers.ssh.@keyFile = Path to the keyfile to use for authentication
+ivysettings.resolvers.ssh.@keyFilePassword = the password used to protect the key file
+ivysettings.resolvers.ssh.@host = The host to connect to
+ivysettings.resolvers.ssh.@port = The port to connect to
+ivysettings.resolvers.ssh.@publishPermissions = A four digit string (e.g., 0644, see "man chmod", "man open") specifying the permissions of the published files. (since 2.0)
+
+##### ivysettings.resolvers.url
+ivysettings.resolvers.url = This resolver is one of the most generic, in fact most of the previous resolvers can be obtained by a particular configuration of this one.
+ivysettings.resolvers.url.@m2compatible = True if this resolver should be maven2 compatible, false otherwise since 1.3
+##### ivysettings.resolvers.vfs
+ivysettings.resolvers.vfs = This resolver is certainly the most capable, since it relies on Apache commons VFS, which gives an uniform access to a good number of file systems, including ftp, webdav, zip, ...
+##### ivysettings.caches
+ivysettings.caches = Configures the Ivy cache system.
+ivysettings.caches.@default = the name of the default cache to use on all resolvers not defining the cache instance to use
+ivysettings.caches.@defaultCacheDir = a path to a directory to use as default basedir for both resolution and repository cache(s)
+ivysettings.caches.@resolutionCacheDir = the path of the directory to use for all resolution cache data
+ivysettings.caches.@repositoryCacheDir = the path of the default directory to use for repository cache data. This should not point to a directory used as a repository!
+ivysettings.caches.@ivyPattern = default pattern used to indicate where ivy files should be put in the repository cache(s)
+ivysettings.caches.@artifactPattern = default pattern used to indicate where artifact files should be put in the repository cache(s)
+ivysettings.caches.@checkUpToDate = Indicates if date should be checked before retrieving artifacts from cache
+ivysettings.caches.@useOrigin = the default value to use for useOrigin for caches in which it isn't specifically defined.    	Use true to avoid the copy of local artifacts to the cache and use directly their original location.
+ivysettings.caches.@lockStrategy = the name of the default lock strategy to use when accessing repository cache(s)
+##### ivysettings.caches.cache
+ivysettings.caches.cache = Defines a repository cache instance based on the default repository cache implementation.
+ivysettings.caches.cache.@name = name of the cache instance
+ivysettings.caches.cache.@basedir = the path of the base directory to use to put repository cache data. This should not point to a directory used as a repository!
+ivysettings.caches.cache.@ivyPattern = the pattern to use to store cached ivy files
+ivysettings.caches.cache.@artifactPattern = the pattern to use to store cached artifacts
+ivysettings.caches.cache.@useOrigin = true to avoid the copy of local artifacts to the cache and use directly their original location, false otherwise. To know if an artifact is local ivy asks to the resolver. Only filesystem resolver is considered local by default, but this can be disabled if you want to force the copy on one filesystem resolver and use the original location on another. Note that it is safe to use useOrigin even if you use the cache for some non local resolvers. In this case the cache will behave as usual, copying files to the cache. Note also that this only applies to artifacts, not to ivy files, which are still copied in the cache.
+ivysettings.caches.cache.@lockStrategy = the name of the lock strategy to use for this cache
+ivysettings.caches.cache.@defaultTTL = the default TTL to use when no specific one is defined
+##### ivysettings.caches.cache.TTL
+ivysettings.caches.cache.TTL = Defines a TTL (Time To Live) rule for resolved revision caching.
+ivysettings.caches.cache.TTL.@organisation = the organisation to match to apply the rule.
+ivysettings.caches.cache.TTL.@module = the module's name to match to apply the rule.
+ivysettings.caches.cache.TTL.@revision = the module's revision to match to apply the rule. Note that the version is not resolved when evaluating the rule ('latest.integration' for instance).
+ivysettings.caches.cache.TTL.@any extra attribute = an extra attribute to match to apply the rule.
+ivysettings.caches.cache.TTL.@matcher = the matcher to use to match the modules to which the resolver should be applied
+ivysettings.caches.cache.TTL.@duration = the TTL to apply
+##### ivysettings.classpath
+ivysettings.classpath = Includes a jar in the classpath used to load plugins.
+ivysettings.classpath.@url = the url of a jar to add to the classpath
+ivysettings.classpath.@file = a jar to add to the classpath
+##### ivysettings.conflict-managers
+ivysettings.conflict-managers = Defines a list of conflicts managers usable in ivy.
+##### ivysettings.include
+ivysettings.include = Includes another ivysettings file as if it were part of this one.
+ivysettings.include.@url = a URL to the ivysettings file to include
+ivysettings.include.@file = a path to the ivysettings file to include
+##### ivysettings.latest-strategies
+ivysettings.latest-strategies = Defines a list of latest strategies usable in ivy.
+##### ivysettings.lock-strategies
+ivysettings.lock-strategies = Defines a list of lock strategies usable in Ivy.
+##### ivysettings.macrodef
+ivysettings.macrodef = Defines a new dependency resolver type based upon an other one.
+ivysettings.macrodef.@name = name of the resover type created
+##### ivysettings.macrodef.attribute
+ivysettings.macrodef.attribute = Defines a macrodef attribute.
+ivysettings.macrodef.attribute.@name = the name of the attribute
+ivysettings.macrodef.attribute.@default = the default value of the attribute if none is specified
+##### ivysettings.modules.module
+ivysettings.modules.module = Define a module set rule.
+ivysettings.modules.module.@organisation = the organisation to match to apply the rule.
+ivysettings.modules.module.@name = the module's name to match to apply the rule.
+ivysettings.modules.module.@revision = the module's revision to match to apply the rule. Note that the version may not be resolved yet (be latest.integration for instance), so be very careful when using this attribute. since 2.0
+ivysettings.modules.module.@any extra attribute = an extra attribute to match to apply the rule. since 2.0
+ivysettings.modules.module.@matcher = the matcher to use to match the modules to which the resolver should be applied since 1.3
+ivysettings.modules.module.@resolver = the name of the resolver to apply. The resolver must have been defined in the resolvers section of the configuration file.
+ivysettings.modules.module.@conflict-manager = the name of the conflict manager to apply. since 1.4
+ivysettings.modules.module.@branch = the default branch to apply. since 1.4
+ivysettings.modules.module.@resolveMode = the resolve mode to use. since 2.0
+##### ivysettings.modules
+ivysettings.modules = Defines per module or module set settings.
+##### ivysettings.namespaces.namespace
+ivysettings.namespaces.namespace = Defines a new namespace. A namespace is identified by a name, which is used to reference the namespace in the resolvers using the namespace.
+ivysettings.namespaces.namespace.@name = the namespace name
+ivysettings.namespaces.namespace.@chainrules = true to indicate that namespaces rules should be chained, false otherwise
+##### ivysettings.namespaces.namespace.rule.fromsystem.dest
+ivysettings.namespaces.namespace.rule.fromsystem.dest = Defines the translation part of a translation rule. If a name has matched a corresponding src, it will be translated using this dest part.
+ivysettings.namespaces.namespace.rule.fromsystem.dest.@org = the new organisation name
+ivysettings.namespaces.namespace.rule.fromsystem.dest.@module = the new module name
+ivysettings.namespaces.namespace.rule.fromsystem.dest.@rev = the new revision
+##### ivysettings.namespaces.namespace.fromsystem
+ivysettings.namespaces.namespace.fromsystem = Defines a one way translation rule, i.e. a translation from system namespace to the defined namespace or vice versa.
+##### ivysettings.namespaces.namespace.rule
+ivysettings.namespaces.namespace.rule = Defines a new namespace rule. A rule defines a translation between system namespace and the defined namespace, and vice versa.
+##### ivysettings.namespaces.namespace.rule.fromsystem.src
+ivysettings.namespaces.namespace.rule.fromsystem.src = Defines the acceptation part of a translation rule.
+ivysettings.namespaces.namespace.rule.fromsystem.src.@org = the organisation to match as a regexp
+ivysettings.namespaces.namespace.rule.fromsystem.src.@module = the module name to match as a regexp
+ivysettings.namespaces.namespace.rule.fromsystem.src.@rev = the revision to match as a regexp
+##### ivysettings.namespaces
+ivysettings.namespaces = Namespaces are an advanced feature of Ivy which let you use resolvers in which module names and organisations are not consistent between each other.
+##### ivysettings.outputters
+ivysettings.outputters = Defines a list of report outputters usable in ivy. 
+##### ivysettings.parsers
+ivysettings.parsers = Defines a list of module descriptor parsers usable in ivy.
+##### ivysettings.properties
+ivysettings.properties = Loads a properties file into ivy variables.
+ivysettings.properties.@file = a path to a properties file to load
+ivysettings.properties.@environment = the prefix to use when retrieving environment variables (since 2.0)
+ivysettings.properties.@override = indicates if the variable found in the properties file should override their previous value, if any (since 1.3)
+##### ivysettings.property
+ivysettings.property = Defines an ivy variable.
+ivysettings.property.@name = the name of the variable to define
+ivysettings.property.@value = the new value the variable must take
+ivysettings.property.@override = true if the previous value (if any) of the variable should overriden, false otherwise
+##### ivysettings.resolvers
+ivysettings.resolvers = Defines a list of dependency resolvers usable in ivy.
+ivysettings.resolvers.@IvyRep = Standard
+ivysettings.resolvers.@IBiblio = Standard
+ivysettings.resolvers.@Packager = Standard
+ivysettings.resolvers.@FileSystem = Standard
+ivysettings.resolvers.@Url = Standard
+ivysettings.resolvers.@Vfs = Standard
+ivysettings.resolvers.@ssh = Standard
+ivysettings.resolvers.@sftp = Standard
+ivysettings.resolvers.@Chain = Composite
+ivysettings.resolvers.@Dual = Composite
+##### ivysettings.settings
+ivysettings.settings = Configures some important ivy info: default resolver, latest strategy, conflict manager...
+ivysettings.settings.@defaultResolver = the name of the default resolver to use
+ivysettings.settings.@defaultLatestStrategy = the name of the default latest strategy to use
+ivysettings.settings.@defaultConflictManager = the name of the default conflict manager to use
+ivysettings.settings.@defaultBranch = the default branch to use for all modules, except if they have a module specific branch setting. since 1.4
+ivysettings.settings.@defaultResolveMode = the default resolve mode to use for all modules, except if they have a module specific resolve mode setting. since 2.0
+ivysettings.settings.@circularDependencyStrategy = the name of the circular dependency strategy to use since 1.4
+ivysettings.settings.@validate = Indicates if ivy files should be validated against ivy.xsd or not.
+ivysettings.settings.@useRemoteConfig = true to configure ivyrep and ibiblio resolver from a remote configuration file (updated with changes in those repository structure if any) (since 1.2)
+ivysettings.settings.@defaultCache = a path to a directory to use as default basedir for both resolution and repository cache(s).	    Deprecated, we recommend using defaultCacheDir on the caches tag instead
+ivysettings.settings.@checkUpToDate = Indicates if date should be checked before retrieving artifacts from cache.    	Deprecated, we recommend using checkUpToDate on the caches tag instead
+ivysettings.settings.@cacheIvyPattern = a pattern to indicate where ivy files should be put in cache.    	Deprecated, we recommend using ivyPattern on the caches tag instead
+ivysettings.settings.@cacheArtifactPattern = a pattern to indicate where artifact files should be put in cache.    	Deprecated, we recommend using artifactPattern on the caches tag instead
+##### ivysettings.statuses.status
+ivysettings.statuses.status = Define one available module status.
+ivysettings.statuses.status.@name = name of status defined
+ivysettings.statuses.status.@integration = true if this is an integration status, false otherwise
+##### ivysettings.statuses
+ivysettings.statuses = Defines the list of available statuses.
+ivysettings.statuses.@default = the name of the status to use when none is declared in an ivy file
+##### ivysettings.triggers
+ivysettings.triggers = Defines a list of triggers to activate on some Ivy events.
+ivysettings.triggers.@ant-build = Triggers an ant build.
+ivysettings.triggers.@ant-call = Calls a target in the current ant build.
+ivysettings.triggers.@log = Logs a message on the console or in a log file.
+##### ivysettings.typedef
+ivysettings.typedef = Defines a new type in ivy. Useful to define new dependency resolvers, in particular, but also latest strategies.
+ivysettings.typedef.@name = the name of the type to define. This name is then used as an xml tag.
+ivysettings.typedef.@classname = the fully qualified class name of the type to define.
+##### ivysettings.version-matchers
+ivysettings.version-matchers = Defines a list of version matchers.
\ No newline at end of file

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/tagsdoc.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/common/model/tagsdoc.properties
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Copied: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyModuleDescriptorEditor.java (from r669878, ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyEditor.java)
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyModuleDescriptorEditor.java?p2=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyModuleDescriptorEditor.java&p1=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyEditor.java&r1=669878&r2=679833&rev=679833&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyEditor.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyModuleDescriptorEditor.java Fri Jul 25 08:26:55 2008
@@ -17,11 +17,15 @@
  */
 package org.apache.ivyde.eclipse.ui.editors;
 
+import org.apache.ivyde.common.ivyfile.IvyModuleDescriptorModel;
+import org.apache.ivyde.common.model.IvyModel;
 import org.apache.ivyde.eclipse.IvyPlugin;
 import org.apache.ivyde.eclipse.cpcontainer.IvyClasspathContainer;
 import org.apache.ivyde.eclipse.cpcontainer.IvyClasspathUtil;
 import org.apache.ivyde.eclipse.ui.core.IvyFileEditorInput;
 import org.apache.ivyde.eclipse.ui.editors.pages.OverviewFormPage;
+import org.apache.ivyde.eclipse.ui.editors.xml.EclipseIvyModelSettings;
+import org.apache.ivyde.eclipse.ui.editors.xml.IvyContentAssistProcessor;
 import org.apache.ivyde.eclipse.ui.editors.xml.XMLEditor;
 import org.eclipse.core.resources.IFile;
 import org.eclipse.core.resources.IMarker;
@@ -49,7 +53,7 @@
 import org.eclipse.ui.ide.IDE;
 import org.eclipse.ui.part.FileEditorInput;
 
-public class IvyEditor extends FormEditor implements IResourceChangeListener {
+public class IvyModuleDescriptorEditor extends FormEditor implements IResourceChangeListener {
     public final static String ID = "org.apache.ivyde.editors.IvyEditor";
 
     private XMLEditor xmlEditor;
@@ -59,7 +63,7 @@
     /**
      * Creates a multi-page editor example.
      */
-    public IvyEditor() {
+    public IvyModuleDescriptorEditor() {
         super();
         ResourcesPlugin.getWorkspace().addResourceChangeListener(this);
     }
@@ -85,7 +89,12 @@
 
     void createPageXML() {
         try {
-            xmlEditor = new XMLEditor();
+            xmlEditor = new XMLEditor(new IvyContentAssistProcessor() {
+                protected IvyModel newCompletionModel(IFile file) {
+                    return new IvyModuleDescriptorModel(
+                        new EclipseIvyModelSettings(getJavaProject()));
+                }
+            });
             xmlEditor.setFile(((IvyFileEditorInput) getEditorInput()).getFile());
             int index = addPage(xmlEditor, getEditorInput());
             setPageText(index, xmlEditor.getTitle());

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyModuleDescriptorEditor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Copied: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyModuleDescriptorEditorContributor.java (from r669878, ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyEditorContributor.java)
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyModuleDescriptorEditorContributor.java?p2=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyModuleDescriptorEditorContributor.java&p1=ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyEditorContributor.java&r1=669878&r2=679833&rev=679833&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyEditorContributor.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyModuleDescriptorEditorContributor.java Fri Jul 25 08:26:55 2008
@@ -33,14 +33,14 @@
  * the redirection of global actions to the active editor. Multi-page contributor replaces the
  * contributors for the individual editors in the multi-page editor.
  */
-public class IvyEditorContributor extends MultiPageEditorActionBarContributor {
+public class IvyModuleDescriptorEditorContributor extends MultiPageEditorActionBarContributor {
     private IEditorPart activeEditorPart;
 
     // private Action sampleAction;
     /**
      * Creates a multi-page contributor.
      */
-    public IvyEditorContributor() {
+    public IvyModuleDescriptorEditorContributor() {
         super();
         createActions();
     }

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/IvyModuleDescriptorEditorContributor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/xml/EclipseIvyModelSettings.java
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/xml/EclipseIvyModelSettings.java?rev=679833&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/xml/EclipseIvyModelSettings.java (added)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/xml/EclipseIvyModelSettings.java Fri Jul 25 08:26:55 2008
@@ -0,0 +1,53 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+package org.apache.ivyde.eclipse.ui.editors.xml;
+
+import org.apache.ivy.Ivy;
+import org.apache.ivyde.common.model.IvyModelSettings;
+import org.apache.ivyde.eclipse.IvyPlugin;
+import org.apache.ivyde.eclipse.ui.preferences.PreferenceConstants;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.jdt.core.IJavaProject;
+
+public class EclipseIvyModelSettings implements IvyModelSettings {
+    
+    private IJavaProject javaProject;
+    
+    public EclipseIvyModelSettings(IJavaProject javaProject) {
+        this.javaProject = javaProject;
+    }
+
+    public String getDefaultOrganization() {
+        return IvyPlugin.getDefault().getPreferenceStore()
+                        .getString(PreferenceConstants.ORGANISATION);
+    }
+
+    public String getDefaultOrganizationURL() {
+        return IvyPlugin.getDefault().getPreferenceStore()
+            .getString(PreferenceConstants.ORGANISATION_URL);
+    }
+
+    public Ivy getIvyInstance() {
+        return IvyPlugin.getIvy(javaProject);
+    }
+
+    public void logError(String message, Exception e) {
+        IvyPlugin.log(Status.ERROR, message, e);
+    }
+
+}

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/xml/EclipseIvyModelSettings.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/editors/xml/EclipseIvyModelSettings.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain



Mime
View raw message