jvanzyl     2004/04/02 10:41:24

  Modified:    maven-core/src/main/java/org/apache/maven DefaultMaven.java
  Log:
  o allow information about goals and plugins to be accessed for help and integration 
purposes.
  
  Revision  Changes    Path
  1.11      +31 -10    
maven-components/maven-core/src/main/java/org/apache/maven/DefaultMaven.java
  
  Index: DefaultMaven.java
  ===================================================================
  RCS file: 
/home/cvs/maven-components/maven-core/src/main/java/org/apache/maven/DefaultMaven.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- DefaultMaven.java 2 Apr 2004 18:31:44 -0000       1.10
  +++ DefaultMaven.java 2 Apr 2004 18:41:24 -0000       1.11
  @@ -17,6 +17,8 @@
    */
   
   import org.apache.maven.plugin.PluginExecutionResponse;
  +import org.apache.maven.plugin.descriptor.PluginDescriptor;
  +import org.apache.maven.plugin.descriptor.GoalDescriptor;
   import org.apache.maven.plugin.manager.PluginManagerManager;
   import org.apache.maven.project.MavenProject;
   import org.apache.maven.project.MavenProjectBuilder;
  @@ -30,6 +32,7 @@
   import java.util.Iterator;
   import java.util.List;
   import java.util.Set;
  +import java.util.Map;
   
   public class DefaultMaven
       implements Maven
  @@ -40,16 +43,6 @@
   
       private I18N i18n;
   
  -    public Set getAllGoalNames()
  -    {
  -        return new HashSet();
  -    }
  -
  -    public String getGoalDescription( String goalName )
  -    {
  -        return "desc";
  -    }
  -
       // ----------------------------------------------------------------------
       //
       // ----------------------------------------------------------------------
  @@ -75,6 +68,34 @@
           {
               response.getException().printStackTrace();
           }
  +    }
  +
  +    // ----------------------------------------------------------------------
  +    // Plugin descriptors
  +    // ----------------------------------------------------------------------
  +
  +    public Map getPluginDescriptors()
  +    {
  +        return pluginMM.getPluginDescriptors();
  +    }
  +
  +    public PluginDescriptor getPluginDescriptor( String pluginId )
  +    {
  +        return pluginMM.getPluginDescriptor( pluginId );
  +    }
  +
  +    // ----------------------------------------------------------------------
  +    // Goal descriptors
  +    // ----------------------------------------------------------------------
  +
  +    public Map getGoalDescriptors()
  +    {
  +        return pluginMM.getGoalDescriptors();
  +    }
  +
  +    public GoalDescriptor getGoalDescriptor( String goalId )
  +    {
  +        return pluginMM.getGoalDescriptor( goalId );
       }
   
       // ----------------------------------------------------------------------
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to