Package org.apache.maven.model

Examples of org.apache.maven.model.Exclusion


                art.setFile(new File(dependency.getSystemPath()));
            }

            List<String> exclusions = new ArrayList<String>();
            for (Iterator j = dependency.getExclusions().iterator(); j.hasNext();) {
                Exclusion e = (Exclusion)j.next();
                exclusions.add(e.getGroupId() + ":" + e.getArtifactId());
            }

            ArtifactFilter newFilter = new ExcludesArtifactFilter(exclusions);

            art.setDependencyFilter(newFilter);
View Full Code Here


                art.setFile(new File(dependency.getSystemPath()));
            }

            List<String> exclusions = new ArrayList<String>();
            for (Iterator j = dependency.getExclusions().iterator(); j.hasNext();) {
                Exclusion e = (Exclusion)j.next();
                exclusions.add(e.getGroupId() + ":" + e.getArtifactId());
            }

            ArtifactFilter newFilter = new ExcludesArtifactFilter(exclusions);

            art.setDependencyFilter(newFilter);
View Full Code Here

                        {
                            Dependency dep = dependencies.get( x );
                            if ( dep.getArtifactId().equals( n2.getArtifact().getArtifactId() )
                                && dep.getGroupId().equals( n2.getArtifact().getGroupId() ) )
                            {
                                Exclusion exclusion = new Exclusion();
                                exclusion.setArtifactId( n3.getArtifact().getArtifactId() );
                                exclusion.setGroupId( n3.getArtifact().getGroupId() );
                                dep.addExclusion( exclusion );
                                modified = true;
                                break;
                            }
                        }
View Full Code Here

      mvnDep = new org.apache.maven.model.Dependency();
      mvnDep.setArtifactId("seam-forge");
      mvnDep.setGroupId("org.jboss.forge");
      mvnDep.setVersion("9");
      mvnDep.setScope("ComPiLe");
      Exclusion ex1 = new Exclusion();
      ex1.setArtifactId("sub-module");
      ex1.setGroupId("org.jboss.forge");
      mvnDep.addExclusion(ex1);
      Exclusion ex2 = new Exclusion();
      ex2.setArtifactId("sub-module-2");
      ex2.setGroupId("org.jboss.forge");
      mvnDep.addExclusion(ex2);
   }
View Full Code Here

      mvnDep.setArtifactId("seam-forge");
      mvnDep.setGroupId("org.jboss.forge");
      mvnDep.setVersion("9");
      mvnDep.setScope("ComPiLe");

      Exclusion ex1 = new Exclusion();
      ex1.setArtifactId("sub-module");
      ex1.setGroupId("org.jboss.forge");
      mvnDep.addExclusion(ex1);

      Exclusion ex2 = new Exclusion();
      ex2.setArtifactId("sub-module-2");
      ex2.setGroupId("org.jboss.forge");
      mvnDep.addExclusion(ex2);
   }
View Full Code Here

   private List<Exclusion> transformExclusions(List<Coordinate> excludedDependencies)
   {
      List<Exclusion> result = new ArrayList<Exclusion>(excludedDependencies.size());
      for (Coordinate dependency : excludedDependencies)
      {
         Exclusion exclusion = new Exclusion();
         exclusion.setArtifactId(dependency.getArtifactId());
         exclusion.setGroupId(dependency.getGroupId());
         result.add(exclusion);
      }
      return result;
   }
View Full Code Here

      if (dep.getExcludedCoordinates() != null)
      {
         for (Coordinate exclusion : dep.getExcludedCoordinates())
         {
            Exclusion temp = new Exclusion();
            temp.setArtifactId(exclusion.getArtifactId());
            temp.setGroupId(exclusion.getGroupId());
            this.getExclusions().add(temp);
         }
      }
   }
View Full Code Here

   private void setExclusions(final Collection<org.eclipse.aether.graph.Exclusion> exclusions)
   {
      List<Exclusion> result = new ArrayList<Exclusion>();
      for (org.eclipse.aether.graph.Exclusion exclusion : exclusions)
      {
         Exclusion temp = new Exclusion();
         temp.setArtifactId(exclusion.getArtifactId());
         temp.setGroupId(exclusion.getGroupId());
         result.add(temp);
      }
      super.setExclusions(result);
   }
View Full Code Here

      this.setClassifier(dep.getClassifier());
      this.setSystemPath(dep.getSystemPath());

      for (Dependency exclusion : dep.getExcludedDependencies())
      {
         Exclusion temp = new Exclusion();
         temp.setArtifactId(exclusion.getArtifactId());
         temp.setGroupId(exclusion.getGroupId());
         this.getExclusions().add(temp);
      }
   }
View Full Code Here

   private void setExclusions(final Collection<org.sonatype.aether.graph.Exclusion> exclusions)
   {
      List<Exclusion> result = new ArrayList<Exclusion>();
      for (org.sonatype.aether.graph.Exclusion exclusion : exclusions)
      {
         Exclusion temp = new Exclusion();
         temp.setArtifactId(exclusion.getArtifactId());
         temp.setGroupId(exclusion.getGroupId());
         result.add(temp);
      }
      super.setExclusions(result);
   }
View Full Code Here

TOP

Related Classes of org.apache.maven.model.Exclusion

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.