maven-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jvan...@apache.org
Subject cvs commit: jakarta-turbine-maven/src/java/org/apache/maven CreateDependencyClasspath.java
Date Sun, 01 Dec 2002 04:34:29 GMT
jvanzyl     2002/11/30 20:34:29

  Modified:    src/java/org/apache/maven CreateDependencyClasspath.java
  Log:
  refactoring
  
  Revision  Changes    Path
  1.19      +5 -28     jakarta-turbine-maven/src/java/org/apache/maven/CreateDependencyClasspath.java
  
  Index: CreateDependencyClasspath.java
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/java/org/apache/maven/CreateDependencyClasspath.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- CreateDependencyClasspath.java	25 Nov 2002 18:30:24 -0000	1.18
  +++ CreateDependencyClasspath.java	1 Dec 2002 04:34:29 -0000	1.19
  @@ -94,9 +94,6 @@
       /** Jelly context */
       private MavenJellyContext context;
   
  -    /** Maven project (POM) */
  -    private Project mavenProject;
  -
       // --------------------------------------------------------------
       // A C C E S S O R S
       // --------------------------------------------------------------
  @@ -141,26 +138,6 @@
           return refid;
       }
   
  -    /**
  -     * Set the maven project.
  -     *
  -     * @param mavenProject The maven project.
  -     */
  -    public void setMavenProject( Project mavenProject )
  -    {
  -        this.mavenProject = mavenProject;
  -    }
  -
  -    /**
  -     * Get the maven project.
  -     *
  -     * @return The maven project.
  -     */
  -    public Project getMavenProject()
  -    {
  -        return mavenProject;
  -    }
  -
       // --------------------------------------------------------------
       // I M P L E M E N T A T I O N
       // --------------------------------------------------------------
  @@ -179,9 +156,9 @@
   
               // If a maven project hasn't been set explicity then use the one
               // in the jelly context.
  -            if ( getMavenProject() == null )
  +            if ( getContext().getProject() == null )
               {
  -                setMavenProject( (Project) context.getVariable( MavenConstants.MAVEN_POM
) );
  +                getContext().setProject( (Project) context.getVariable( MavenConstants.MAVEN_POM
) );
               }
   
               Object b = context.getVariable( MavenConstants.JAR_OVERRIDE );
  @@ -199,7 +176,7 @@
   
               Path classpath = new Path( antProject );
   
  -            for ( Iterator i = mavenProject.getDependencies().iterator();
  +            for ( Iterator i = getContext().getProject().getDependencies().iterator();
                     i.hasNext(); )
               {
                   Dependency d = (Dependency) i.next();
  @@ -233,7 +210,7 @@
   
                   classpath.append( path );
   
  -                getMavenProject().setDependencyPath( d.getId(), path.toString() );
  +                getContext().getProject().setDependencyPath( d.getId(), path.toString()
);
               }
   
               if ( refid != null )
  
  
  

Mime
View raw message