Package org.apache.ivy.core.retrieve

Examples of org.apache.ivy.core.retrieve.RetrieveOptions


        }

        IvyDEMessage.info("Retrieving files into " + pattern);

        monitor.setTaskName("retrieving dependencies in " + pattern);
        RetrieveOptions options = new RetrieveOptions();
        options.setSync(retrieveSync);
        if (!result.isPreviousUsed()) {
            options.setResolveId(result.getReport().getResolveId());
        }
        options.setConfs(confs);
        if (retrieveTypes != null && !retrieveTypes.equals("*")) {
            List typeList = IvyClasspathUtil.split(retrieveTypes);
            options.setArtifactFilter(new ArtifactTypeFilter(typeList));
        }
        options.setResolveId(IvyClasspathUtil.buildResolveId(useExtendedResolveId, md));

        String refreshPath = IvyPatternHelper.getTokenRoot(retrievePattern);
        if (retrieveSync && refreshPath.length() == 0) {
            // the root folder of the retrieve pattern is the the project itself
            // so let's prevent from deleting the entire project
View Full Code Here


    private void maybeRetrieve(ModuleDescriptor md, String[] confs) throws IOException {
        if (conf.getInheritedDoRetrieve()) {
            String pattern = conf.javaProject.getProject().getLocation().toPortableString() + "/"
                    + conf.getInheritedRetrievePattern();
            _monitor.setTaskName("retrieving dependencies in " + pattern);
            ivy.retrieve(md.getModuleRevisionId(), pattern, new RetrieveOptions().setConfs(confs));
        }
    }
View Full Code Here

            if (line.hasOption("retrieve")) {
                String retrievePattern = settings.substitute(line.getOptionValue("retrieve"));
                if (retrievePattern.indexOf("[") == -1) {
                    retrievePattern = retrievePattern + "/lib/[conf]/[artifact].[ext]";
                }
                ivy.retrieve(md.getModuleRevisionId(), retrievePattern, new RetrieveOptions()
                        .setConfs(confs).setSync(line.hasOption("sync"))
                        .setUseOrigin(line.hasOption("useOrigin")));
            }
            if (line.hasOption("cachepath")) {
                outputCachePath(ivy, cache, md, confs, line.getOptionValue("cachepath",
View Full Code Here

    public Map determineArtifactsToCopy(ModuleId moduleId, String[] confs, File cache,
            String destFilePattern, String destIvyPattern) throws ParseException, IOException {
        return ivy.getRetrieveEngine().determineArtifactsToCopy(
            new ModuleRevisionId(moduleId, Ivy.getWorkingRevision()),
            destFilePattern,
            new RetrieveOptions().setConfs(confs).setDestIvyPattern(
                destIvyPattern));
    }
View Full Code Here

    public int retrieve(ModuleId moduleId, String[] confs, File cache, String destFilePattern,
            String destIvyPattern, Filter artifactFilter, boolean sync, boolean useOrigin,
            boolean makeSymlinks) {
        try {
            return ivy.retrieve(new ModuleRevisionId(moduleId, Ivy.getWorkingRevision()),
                destFilePattern, new RetrieveOptions().setConfs(confs).setDestIvyPattern(
                    destIvyPattern).setArtifactFilter(artifactFilter).setSync(sync).setUseOrigin(
                    useOrigin).setMakeSymlinks(makeSymlinks));
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
View Full Code Here

    public int retrieve(ModuleId moduleId, String[] confs, File cache, String destFilePattern,
            String destIvyPattern, Filter artifactFilter, boolean sync, boolean useOrigin) {
        try {
            return ivy.retrieve(new ModuleRevisionId(moduleId, Ivy.getWorkingRevision()),
                destFilePattern, new RetrieveOptions().setConfs(confs).setDestIvyPattern(
                    destIvyPattern).setArtifactFilter(artifactFilter).setSync(sync).setUseOrigin(
                    useOrigin));
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
View Full Code Here

    public int retrieve(ModuleId moduleId, String[] confs, File cache, String destFilePattern,
            String destIvyPattern, Filter artifactFilter) {
        try {
            return ivy.retrieve(new ModuleRevisionId(moduleId, Ivy.getWorkingRevision()),
                destFilePattern, new RetrieveOptions().setConfs(confs).setDestIvyPattern(
                    destIvyPattern).setArtifactFilter(artifactFilter));
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
View Full Code Here

    public int retrieve(ModuleId moduleId, String[] confs, File cache, String destFilePattern,
            String destIvyPattern) {
        try {
            return ivy.retrieve(new ModuleRevisionId(moduleId, Ivy.getWorkingRevision()),
                destFilePattern, new RetrieveOptions().setConfs(confs).setDestIvyPattern(
                    destIvyPattern));
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
View Full Code Here

    }

    public int retrieve(ModuleId moduleId, String[] confs, File cache, String destFilePattern) {
        try {
            return ivy.retrieve(new ModuleRevisionId(moduleId, Ivy.getWorkingRevision()),
                destFilePattern, new RetrieveOptions().setConfs(confs));
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
View Full Code Here

            String destFilePattern, String destIvyPattern, Filter artifactFilter)
            throws ParseException, IOException {
        return ivy.getRetrieveEngine().determineArtifactsToCopy(
            new ModuleRevisionId(moduleId, Ivy.getWorkingRevision()),
            destFilePattern,
            new RetrieveOptions().setConfs(confs).setDestIvyPattern(
                destIvyPattern).setArtifactFilter(artifactFilter));
    }
View Full Code Here

TOP

Related Classes of org.apache.ivy.core.retrieve.RetrieveOptions

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.