Package org.sonatype.aether.resolution

Examples of org.sonatype.aether.resolution.DependencyResult


         Artifact artifact = dependencyToMavenArtifact(dep);
         CollectRequest collectRequest = new CollectRequest(new org.sonatype.aether.graph.Dependency(artifact, null),
                  convertToMavenRepos(repositories));
         DependencyRequest request = new DependencyRequest(collectRequest, null);

         DependencyResult artifacts = system.resolveDependencies(session, request);

         for (ArtifactResult a : artifacts.getArtifactResults())
         {
            File file = a.getArtifact().getFile();
            Dependency d = DependencyBuilder.create().setArtifactId(a.getArtifact().getArtifactId())
                     .setGroupId(a.getArtifact().getGroupId()).setVersion(a.getArtifact().getVersion());
            DependencyResource resource = new DependencyResource(factory, file, d);
View Full Code Here


                    collectRequest.setRepositories(projectRepos);

                    DependencyNode rootNode = repoSystem.collectDependencies( session, collectRequest ).getRoot();

                    DependencyRequest request = new DependencyRequest(rootNode,null);
                    DependencyResult result = repoSystem.resolveDependencies(session,request);


                    getLog().info("Artifact: " + aetherArtifact);
                    for(DependencyNode child : result.getRoot().getChildren()) {
                        if(child.getDependency().getArtifact().getGroupId().equals(moduleGroupId)) {
                            processModule(child);
                        }
                    }
                    processModule(result.getRoot());
                    /*
                    deps = aether.resolve(aetherArtifact, JavaScopes.RUNTIME);

                    getLog().info("Artifact: "+aetherArtifact);
                    for(Artifact dep : deps) {
View Full Code Here

        try {
            // collect all the dependency graph for the module, and print it until we reach a dependency to a local module
            DependencyNode rootNode = repoSystem.collectDependencies( session, collectRequest ).getRoot();

            DependencyRequest request = new DependencyRequest(rootNode,null);
            DependencyResult result = repoSystem.resolveDependencies(session,request);

            // add entry to module dependencies
            moduleLibraries.put(moduleNode.getDependency().getArtifact(), new HashSet<Artifact>());
            moduleDependencies.put(moduleNode.getDependency().getArtifact(), new HashSet<Artifact>());

            getLog().info("processing module "+moduleNode.getDependency().getArtifact().getArtifactId()+":");
            for(DependencyNode child : result.getRoot().getChildren()) {
                collectModuleDependencies(child,moduleNode.getDependency().getArtifact());
            }
            for(DependencyNode child : result.getRoot().getChildren()) {
                collectLibraryDependencies(child, moduleNode.getDependency().getArtifact());
            }

            // information output
            /*
 
View Full Code Here

                    collectRequest.setRepositories(projectRepos);

                    DependencyNode rootNode = repoSystem.collectDependencies( session, collectRequest ).getRoot();

                    DependencyRequest request = new DependencyRequest(rootNode,null);
                    DependencyResult result = repoSystem.resolveDependencies(session,request);


                    getLog().info("Artifact: " + aetherArtifact);
                    for(DependencyNode child : result.getRoot().getChildren()) {
                        if(child.getDependency().getArtifact().getGroupId().equals(moduleGroupId)) {
                            processModule(child);
                        }
                    }
                    processModule(result.getRoot());
                    /*
                    deps = aether.resolve(aetherArtifact, JavaScopes.RUNTIME);

                    getLog().info("Artifact: "+aetherArtifact);
                    for(Artifact dep : deps) {
View Full Code Here

        try {
            // collect all the dependency graph for the module, and print it until we reach a dependency to a local module
            DependencyNode rootNode = repoSystem.collectDependencies( session, collectRequest ).getRoot();

            DependencyRequest request = new DependencyRequest(rootNode,null);
            DependencyResult result = repoSystem.resolveDependencies(session,request);

            // add entry to module dependencies
            moduleLibraries.put(moduleNode.getDependency().getArtifact(), new HashSet<Artifact>());
            moduleDependencies.put(moduleNode.getDependency().getArtifact(), new HashSet<Artifact>());

            getLog().info("processing module "+moduleNode.getDependency().getArtifact().getArtifactId()+":");
            for(DependencyNode child : result.getRoot().getChildren()) {
                collectModuleDependencies(child,moduleNode.getDependency().getArtifact());
            }
            for(DependencyNode child : result.getRoot().getChildren()) {
                collectLibraryDependencies(child, moduleNode.getDependency().getArtifact());
            }

            // information output
            /*
 
View Full Code Here

         Artifact artifact = dependencyToMavenArtifact(dep);
         CollectRequest collectRequest = new CollectRequest(new org.sonatype.aether.graph.Dependency(artifact, null),
                  convertToMavenRepos(repositories));
         DependencyRequest request = new DependencyRequest(collectRequest, null);

         DependencyResult artifacts = system.resolveDependencies(session, request);

         for (ArtifactResult a : artifacts.getArtifactResults())
         {
            File file = a.getArtifact().getFile();
            Dependency d = DependencyBuilder.create().setArtifactId(a.getArtifact().getArtifactId())
                     .setGroupId(a.getArtifact().getGroupId()).setVersion(a.getArtifact().getVersion());
            DependencyResource resource = new DependencyResource(factory, file, d);
View Full Code Here

         Artifact artifact = dependencyToMavenArtifact(dep);
         CollectRequest collectRequest = new CollectRequest(new org.sonatype.aether.graph.Dependency(artifact, null),
                  convertToMavenRepos(repositories));
         DependencyRequest request = new DependencyRequest(collectRequest, null);

         DependencyResult artifacts = system.resolveDependencies(session, request);

         for (ArtifactResult a : artifacts.getArtifactResults())
         {
            File file = a.getArtifact().getFile();
            Dependency d = DependencyBuilder.create().setArtifactId(a.getArtifact().getArtifactId())
                     .setGroupId(a.getArtifact().getGroupId()).setVersion(a.getArtifact().getVersion())
                     .setPackagingType(a.getArtifact().getExtension());
View Full Code Here

        }

        List<File> files = new ArrayList<File>();
        Properties props = new Properties();
        props.setProperty("timestamp",String.valueOf(System.currentTimeMillis()));
        DependencyResult dependencies = forceResolve(gav);
        int i=0;
        for (ArtifactResult ar : dependencies.getArtifactResults()) {
            Artifact a = ar.getArtifact();
            Artifact pom = new DefaultArtifact(a.getGroupId(),a.getArtifactId(),"pom",a.getVersion());

            props.put("pom."+i, resolveArtifact(pom).getAbsolutePath());
            props.put("jar." + i, a.getFile().getAbsolutePath());
View Full Code Here

         Artifact artifact = dependencyToMavenArtifact(dep);
         CollectRequest collectRequest = new CollectRequest(new org.sonatype.aether.graph.Dependency(
                  artifact, null), convertToMavenRepos(repositories));
         DependencyRequest request = new DependencyRequest(collectRequest, null);

         DependencyResult artifacts = system.resolveDependencies(session, request);

         for (ArtifactResult a : artifacts.getArtifactResults())
         {
            File file = a.getArtifact().getFile();
            Dependency d = DependencyBuilder.create().setArtifactId(a.getArtifact().getArtifactId())
                     .setGroupId(a.getArtifact().getGroupId())
                     .setVersion(a.getArtifact().getVersion());
View Full Code Here

         Artifact artifact = dependencyToMavenArtifact(dep);
         CollectRequest collectRequest = new CollectRequest(new org.sonatype.aether.graph.Dependency(artifact, null),
                  convertToMavenRepos(repositories));
         DependencyRequest request = new DependencyRequest(collectRequest, null);

         DependencyResult artifacts = system.resolveDependencies(session, request);

         for (ArtifactResult a : artifacts.getArtifactResults())
         {
            File file = a.getArtifact().getFile();
            Dependency d = DependencyBuilder.create().setArtifactId(a.getArtifact().getArtifactId())
                     .setGroupId(a.getArtifact().getGroupId()).setVersion(a.getArtifact().getVersion())
                     .setPackagingType(a.getArtifact().getExtension());
View Full Code Here

TOP

Related Classes of org.sonatype.aether.resolution.DependencyResult

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.