jvanzyl 2002/11/24 15:41:12
Modified: src/java/org/apache/maven CreateDependencyClasspath.java
MavenUtils.java
src/java/org/apache/maven/app PluginManager.java
ProjectVerifier.java
src/java/org/apache/maven/cli App.java
src/java/org/apache/maven/jelly/tags/project ReactorTag.java
Log:
o more checkstyle fixes.
Revision Changes Path
1.17 +22 -8
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.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- CreateDependencyClasspath.java 24 Nov 2002 19:00:37 -0000 1.16
+++ CreateDependencyClasspath.java 24 Nov 2002 23:41:12 -0000 1.17
@@ -102,7 +102,9 @@
// --------------------------------------------------------------
/**
- * Sets the context attribute of the CreateDependencyClasspath object
+ * Set the maven context.
+ *
+ * @param context The maven jelly context.
*/
public void setContext( MavenJellyContext context )
{
@@ -110,7 +112,9 @@
}
/**
- * Gets the context attribute of the CreateDependencyClasspath object
+ * Set the jelly context.
+ *
+ * @return The maven jelly context.
*/
public MavenJellyContext getContext()
{
@@ -118,7 +122,9 @@
}
/**
- * Sets the refid attribute of the CreateDependencyClasspath object
+ * Set the ref id.
+ *
+ * @param refid The reference id for the classpath.
*/
public void setRefid( String refid )
{
@@ -126,7 +132,9 @@
}
/**
- * Gets the refid attribute of the CreateDependencyClasspath object
+ * Get the ref id for the classpath.
+ *
+ * @return String The reference id.
*/
public String getRefid()
{
@@ -134,7 +142,9 @@
}
/**
- * Sets the mavenProject attribute of the CreateDependencyClasspath object
+ * Set the maven project.
+ *
+ * @param mavenProject The maven project.
*/
public void setMavenProject( Project mavenProject )
{
@@ -142,7 +152,9 @@
}
/**
- * Gets the mavenProject attribute of the CreateDependencyClasspath object
+ * Get the maven project.
+ *
+ * @return The maven project.
*/
public Project getMavenProject()
{
@@ -154,7 +166,9 @@
// --------------------------------------------------------------
/**
- * Create the dependency classpath
+ * Create the dependency classpath.
+ *
+ * @throws Exception If an error occurs while creating the classpath.
*/
public void execute()
throws Exception
1.69 +29 -12 jakarta-turbine-maven/src/java/org/apache/maven/MavenUtils.java
Index: MavenUtils.java
===================================================================
RCS file: /home/cvs/jakarta-turbine-maven/src/java/org/apache/maven/MavenUtils.java,v
retrieving revision 1.68
retrieving revision 1.69
diff -u -r1.68 -r1.69
--- MavenUtils.java 24 Nov 2002 19:19:37 -0000 1.68
+++ MavenUtils.java 24 Nov 2002 23:41:12 -0000 1.69
@@ -115,10 +115,10 @@
private static final Log logger = LogFactory.getLog( MavenUtils.class );
/** Internal encoding used for Jelly interpolation. */
- private final static String INTERNAL_ENCODING = "ISO-8859-1";
+ private static final String INTERNAL_ENCODING = "ISO-8859-1";
/** we want to parse something */
- private final static ThreadLocal xmlReaderPool = new ThreadLocal();
+ private static final ThreadLocal xmlReaderPool = new ThreadLocal();
/** Should we cache and reuse the introspector */
private static boolean cacheIntrospector = true;
@@ -193,7 +193,6 @@
* Process the project descriptor using Jelly itself.
*
* @param project the maven POM
- * @param parentContext a context to resolve variables
* @return Jelly interpolated project.
* @throws Exception when anything goes wrong. FIXME this is bad
*/
@@ -405,7 +404,7 @@
*
* @param clazz the class to register with the reader
* @return a {@link BeanReader bean reader}
- * @throws IntrospectionException when an error occurs trying to determine
+ * @throws Exception when an error occurs trying to determine
* properties of the class provided
* @throws Exception when anything goes wrong. FIXME this is bad
*/
@@ -424,6 +423,8 @@
/**
* If caching is enabled then this method will return a pooled introspector
+ *
+ * @return XMLIntrospector used for processing the Maven xml-based POM.
*/
public static XMLIntrospector getXMLIntrospector()
{
@@ -456,7 +457,10 @@
}
/**
+ * Get the XMLReader to use for processing XML related resources.
+ *
* @return an XMLReader which is pooled per thread
+ * @throws Exception If an error occurs while creating the XMLReader.
*/
public static XMLReader getXMLReader()
throws Exception
@@ -472,6 +476,9 @@
/**
* Creates a new XMLReader instance
+ *
+ * @return XMLReader used for parsing XML related maven resource.
+ * @throws Exception If an error occurs while creating the reader.
*/
private static XMLReader createXMLReader()
throws Exception
@@ -498,9 +505,9 @@
*
* resultantKeys = { a, b, c, d, e, f, x, y, z }
*
- * @param dominantMap
- * @param recessiveMap
- * @return Map
+ * @param dominantMap Dominant Map.
+ * @param recessiveMap Recessive Map.
+ * @return The result map with combined dominant and recessive values.
*/
public static Map mergeMaps( Map dominantMap, Map recessiveMap )
{
@@ -580,11 +587,14 @@
/**
* Process properties in dominant order.
+ *
+ * @param descriptorDirectory The directory from which to pull the standard
maven
+ * properties files from.
+ * @return The generated maven based on the contents of the standard maven
+ * properties files.
*/
public static MavenJellyContext createContext( File descriptorDirectory )
{
- System.out.println( "descriptorDirectory: " + descriptorDirectory );
-
// System properties
Properties systemProperties = System.getProperties();
@@ -634,8 +644,8 @@
* The values in the Map may be <code>CompositeExpression</code>s that need
* to be evaluated before being placed into the context.
*
- * @param map
- * @param context
+ * @param map Map to integrate into the provided jelly context.
+ * @param context Jelly context to integrate the map into.
*/
public static void integrateMapInContext( Map map, MavenJellyContext context )
{
@@ -680,6 +690,9 @@
/**
* Load properties from a <code>File</code>.
+ *
+ * @param file Propertie file to load.
+ * @return The loaded Properties.
*/
private static Properties loadProperties( File file )
{
@@ -697,6 +710,9 @@
/**
* Load properties from an <code>InputStream</code>.
+ *
+ * @param is InputStream from which load properties.
+ * @return The loaded Properties.
*/
private static Properties loadProperties( InputStream is )
{
@@ -739,6 +755,7 @@
static class MetaPropertiesRule
extends Rule
{
+ /** The body of the found property. */
private String value;
/**
1.57 +6 -3
jakarta-turbine-maven/src/java/org/apache/maven/app/PluginManager.java
Index: PluginManager.java
===================================================================
RCS file:
/home/cvs/jakarta-turbine-maven/src/java/org/apache/maven/app/PluginManager.java,v
retrieving revision 1.56
retrieving revision 1.57
diff -u -r1.56 -r1.57
--- PluginManager.java 24 Nov 2002 20:48:11 -0000 1.56
+++ PluginManager.java 24 Nov 2002 23:41:12 -0000 1.57
@@ -840,6 +840,9 @@
* atomic.</p>
*
* @since 1.21, Ant 1.5
+ * @param f New file to create.
+ * @return booelan Indicate whether file creation was successful.
+ * @throws IOException If an error occurs while creating the new file.
*/
public boolean createNewFile( File f )
throws IOException
@@ -1182,7 +1185,7 @@
/**
* Set Jelly context.
*
- * @param jellyContext
+ * @param jellyContext The maven jelly context.
*/
public void setJellyContext( MavenJellyContext jellyContext )
{
@@ -1202,7 +1205,7 @@
/**
* Sets the XMLOutput attribute of the PluginManager object
*
- * @param output
+ * @param output Jelly XMLOutput.
*/
public void setXMLOutput( XMLOutput output )
{
1.21 +24 -5
jakarta-turbine-maven/src/java/org/apache/maven/app/ProjectVerifier.java
Index: ProjectVerifier.java
===================================================================
RCS file:
/home/cvs/jakarta-turbine-maven/src/java/org/apache/maven/app/ProjectVerifier.java,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- ProjectVerifier.java 24 Nov 2002 19:00:38 -0000 1.20
+++ ProjectVerifier.java 24 Nov 2002 23:41:12 -0000 1.21
@@ -158,13 +158,21 @@
failedDependencies = new ArrayList();
}
- /** Set the Maven project. */
+ /**
+ * Set the Maven project.
+ *
+ * @param mavenProject The maven project.
+ */
public void setMavenProject( Project mavenProject )
{
this.mavenProject = mavenProject;
}
- /** Get the Maven project. */
+ /**
+ * Get the Maven project.
+ *
+ * @return The maven project.
+ */
public Project getMavenProject()
{
return mavenProject;
@@ -172,7 +180,7 @@
/**
* Sets the context attribute.
- * @param the Maven Jelly Context to use
+ * @param context The Maven Jelly Context to use
*/
public void setContext( MavenJellyContext context )
{
@@ -258,6 +266,7 @@
/**
* Get the maven remote repository list of URLs.
+ *
* @return the remote repositories as a {@link List} of strings
*/
public List getMavenRemoteRepo()
@@ -266,7 +275,9 @@
}
/**
- * @see ProjectExecutor#doExecute()
+ * Execute the verification process.
+ *
+ * @throws Exception If an error occurs while verifying.
*/
public void doExecute()
throws Exception
@@ -278,6 +289,9 @@
/**
* Verify user settings before attempting to verify the project.
+ *
+ * @throws Exception If an error occurs while trying to verify some basic
+ * maven settings.
*/
private void verifySettings()
throws Exception
@@ -333,6 +347,11 @@
setMavenLocalRepo( localRepoProp );
}
+ /**
+ * Set the context for the project verifier.
+ *
+ * @param context The maven jelly context.
+ */
private void contextualize( MavenJellyContext context )
{
// The project may have already been set by the plugin manager.
1.7 +14 -11 jakarta-turbine-maven/src/java/org/apache/maven/cli/App.java
Index: App.java
===================================================================
RCS file: /home/cvs/jakarta-turbine-maven/src/java/org/apache/maven/cli/App.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- App.java 24 Nov 2002 21:09:36 -0000 1.6
+++ App.java 24 Nov 2002 23:41:12 -0000 1.7
@@ -274,14 +274,15 @@
/** Perform initialization.
*
- * @param args The command-line arguments.
+ * @param args The command-line arguments.
*
- * @throws ParseException If there is an error parsing the
+ * @throws ParseException If there is an error parsing the
* command-line.
- * @throws IOException If there is an error while
+ * @throws IOException If there is an error while
* reading the project descriptor.
- * @throws MalformedURLException If any of the the URLs denoting
+ * @throws MalformedURLException If any of the the URLs denoting
* the local or remote repositories is malformed.
+ * @throws Exception If any other exceptions occur.
*/
public void initializeCore( String[] args )
throws ParseException, IOException, MalformedURLException, Exception
@@ -357,8 +358,8 @@
{
if ( projectFile.length() == 0 )
{
- throw new Exception( "The " + projectFile.getName() +
- " file you specified has a length of zero." );
+ throw new Exception( "The " + projectFile.getName()
+ + " file you specified has a length of zero." );
}
getMaven().setProject( MavenUtils.getProject( projectFile,
getDescriptorDirectory() ) );
@@ -685,7 +686,8 @@
* From the CWD search through the directory hierarchy for
* an XML-based POM.
*
- * @param filename
+ * @param filename The filename to find.
+ * @return The found file.
*/
private File find( String filename )
{
@@ -697,8 +699,9 @@
* From the CWD search through the directory hierarchy for
* an XML-based POM.
*
- * @param start
- * @param suffix
+ * @param start The starting directory for the POM search.
+ * @param suffix The suffix for the file to be searched for.
+ * @return The found project.xml file.
*/
private File find( File start, String suffix )
{
@@ -1043,7 +1046,7 @@
/**
* Main CLI entry point for Maven.
*
- * @param args
+ * @param args CLI arguments.
*/
public static void main( String[] args )
{
1.4 +29 -7
jakarta-turbine-maven/src/java/org/apache/maven/jelly/tags/project/ReactorTag.java
Index: ReactorTag.java
===================================================================
RCS file:
/home/cvs/jakarta-turbine-maven/src/java/org/apache/maven/jelly/tags/project/ReactorTag.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- ReactorTag.java 24 Nov 2002 19:00:38 -0000 1.3
+++ ReactorTag.java 24 Nov 2002 23:41:12 -0000 1.4
@@ -82,7 +82,14 @@
*/
-
+/**
+ * Used for building a set of projects in the correct order to satisfy any
+ * dependencies among the projects being processed.
+ *
+ * @author <a href="mailto:[EMAIL PROTECTED]">Jason van Zyl</a>
+ *
+ * @version $Id$
+ */
public class ReactorTag
extends MavenTag
{
@@ -95,7 +102,12 @@
/** Storage for processed projects. */
private ArrayList reactorProjects = new ArrayList();
- /** Description of the Method */
+ /**
+ * Execute the body of the reactor tag.
+ *
+ * @param output The output sink.
+ * @throws Exception If an error occurs while processing the tag.
+ */
public void doTag( XMLOutput output )
throws Exception
{
@@ -165,7 +177,9 @@
// ------------------------------------------------------------
/**
- * Sets the glob attribute of the ReactorTag object
+ * Set the glob used to find projects.
+ *
+ * @param glob The glob used to find projects.
*/
public void setGlob( String glob )
{
@@ -173,7 +187,9 @@
}
/**
- * Gets the glob attribute of the ReactorTag object
+ * Get the glob used to find projects.
+ *
+ * @return String The glob.
*/
public String getGlob()
{
@@ -181,7 +197,10 @@
}
/**
- * Sets the banner attribute of the ReactorTag object
+ * Set the banner to be displayed for each project while
+ * it is being processed.
+ *
+ * @param banner The banner to use for each processed project.
*/
public void setBanner( String banner )
{
@@ -189,7 +208,10 @@
}
/**
- * Gets the banner attribute of the ReactorTag object
+ * Get the banner to be displayed for project while it
+ * is being processed.
+ *
+ * @return String The banner.
*/
public String getBanner()
{
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>