Allow plugin annotations on mojo members' classes
-------------------------------------------------

                 Key: MNG-2610
                 URL: http://jira.codehaus.org/browse/MNG-2610
             Project: Maven 2
          Issue Type: Improvement
          Components: Bootstrap & Build, Plugin API, Plugin Creation Tools, 
Plugin Requests, Sites & Reporting
    Affects Versions: 2.0.4
            Reporter: Paul Jungwirth
            Priority: Minor


Right now, you can design a plugin to take nested xml in its <configuration> 
section. For example:

<configuration>
    ...
    <classPath>
        <mainClass>com.whatever.Main</mainClass>
        <cp>this.jar;that.jar</cp>
    </classPath>
    ...
</configuration>

This indicates that the mojo class has a classPath member of type ClassPath, 
and the ClassPath class has members named mainClass and cp.

Unfortuatenly, maven doesn't know anything more about mainClass and cp. It 
would be nice if these fields could have the same tags as top-level fields, so 
I could mark them @required, give them default-values, etc.

This would require changing the maven-plugin-plugin to read javadoc and add 
more data to plugin.xml. I think the extra data should be within the containing 
<parameter> tag, since adding new top-level <parameter> tags will probably 
break things.

Then we'd need to change how maven uses plugins, so it looks for these nested 
tags and honors them.

Then we should also change whatever auto-generates plugin documentation, so 
that the table of plugin parameters include the javadoc of nested fields.

It seems like a lot of work, but I'd be happy to start on a patch.


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to