jvanzyl 2002/11/10 18:42:10
Modified: src/java/org/apache/maven/app App.java Maven.java
PluginManager.java ProjectVerifier.java
Log:
o Just some general cleanup, making some notes for some changes i hope
to make this week.
Revision Changes Path
1.25 +13 -6 jakarta-turbine-maven/src/java/org/apache/maven/app/App.java
Index: App.java
===================================================================
RCS file: /home/cvs/jakarta-turbine-maven/src/java/org/apache/maven/app/App.java,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- App.java 26 Oct 2002 05:16:44 -0000 1.24
+++ App.java 11 Nov 2002 02:42:10 -0000 1.25
@@ -88,9 +88,21 @@
import com.werken.werkz.UnattainableGoalException;
/**
+ * The CLI wrapper for controlling Maven processes which are
+ * encapsulated in the Maven bean.
+ *
* @author <a href="mailto:jason@;zenplex.com">Jason van Zyl</a>
* @author dIon Gillard
+ *
* @version $Id$
+ *
+ * @todo Get rid of while iterator idiom.
+ * @todo Separate the computation of the available goals from the display
+ * of the goals. The goal computation logic needs to be moved
+ * out of this class and be placed in Maven.java proper.
+ * @todo All logging needs to be done via commons-logging. No
+ * System.out.* and Jelly needs to be taught to take a
+ * logger. In an attempt to isolate everything in Maven.java.
*/
public class App
{
@@ -562,11 +574,6 @@
*/
protected void printConsoleProjectHeader(Project mavenProject)
{
- /*
- System.out.println(mavenProject.getName() + " ("
- + mavenProject.getId() + ") "
- + mavenProject.getCurrentVersion());
- */
System.out.println(getMaven().getDir());
}
1.121 +9 -3 jakarta-turbine-maven/src/java/org/apache/maven/app/Maven.java
Index: Maven.java
===================================================================
RCS file: /home/cvs/jakarta-turbine-maven/src/java/org/apache/maven/app/Maven.java,v
retrieving revision 1.120
retrieving revision 1.121
diff -u -r1.120 -r1.121
--- Maven.java 4 Nov 2002 14:59:38 -0000 1.120
+++ Maven.java 11 Nov 2002 02:42:10 -0000 1.121
@@ -100,13 +100,19 @@
import com.werken.werkz.Session;
/**
- * Command-line entry-point to maven.
+ * This class should represent the single place to access everything that
+ * Maven provides and control any options provided by Maven. Currently
+ * this is not entirely the case: there are bits of logic that need to
+ * be moved out of App.java and some code that needs to be shuffled
+ * between the PluginManager and Maven proper.
*
* @author <a href="mailto:bob@;eng.werken.com">bob mcwhirter</a>
* @author <a href="mailto:jason@;zenplex.com">Jason van Zyl</a>
* @author <a href="mailto:evenisse@;ifrance.com">Emmanuel Venisse</a>
+ *
* @version $Id$
- * @task filter the Maven version number into a Java constant that will change
+ *
+ * @todo filter the Maven version number into a Java constant that will change
* during compilation
*/
public class Maven
1.48 +18 -52
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.47
retrieving revision 1.48
diff -u -r1.47 -r1.48
--- PluginManager.java 22 Oct 2002 17:28:30 -0000 1.47
+++ PluginManager.java 11 Nov 2002 02:42:10 -0000 1.48
@@ -109,83 +109,54 @@
* @author <a href="mailto:bob@;eng.werken.com">bob mcwhirter</a>
*
* @version $Id$
+ *
+ * @todo Get rid of while iterator idiom.
*/
public class PluginManager
{
- /**
- * Plug-in main script name.
- */
+ /** Plug-in main script name. */
public final static String PLUGIN_SCRIPT_NAME = "plugin.jelly";
- /**
- * Plug-in default properties name.
- */
+ /** Plug-in default properties name. */
public final static String PLUGIN_PROPERTIES_NAME = "plugin.properties";
- /**
- * Plug-in descriptor.
- */
+ /** Plug-in descriptor. */
public final static String PLUGIN_DESCRIPTOR = "plugin.xml";
- /**
- * Plug-in directory property tag
- */
+ /** Plug-in directory property tag */
public final static String PLUGIN_DIR = "maven.plugin.dir";
- /**
- * Plug-in cache
- */
+ /** Plug-in cache */
public final static String PLUGINS_CACHE = "plugins.cache";
- /**
- * Goal cache
- */
+ /** Goal cache */
public final static String GOALS_CACHE = "goals.cache";
- /**
- * Callbacks cache
- */
+ /** Callbacks cache */
public final static String CALLBACKS_CACHE = "callbacks.cache";
- /**
- * Taglibs cache
- */
+ /** Taglibs cache */
public final static String TAGLIBS_CACHE = "taglibs.cache";
- /**
- /**
- * Log.
- */
+ /** Logger */
private final static Log log = LogFactory.getLog(PluginManager.class);
- /**
- * ${maven.home}/bin/plugins directory.
- */
+ /** ${maven.home}/bin/plugins directory. */
private File pluginsDir;
- /**
- * Jelly's output.
- */
+ /** Jelly's output. */
private XMLOutput output;
- /**
- * Jelly conext.
- */
+ /** Jelly conext. */
private MavenJellyContext jellyContext;
- /**
- * The Ant project.
- */
+ /** The Ant project. */
private GrantProject antProject;
- /**
- * ${maven.home}/ directory.
- */
+ /** ${maven.home}/ directory. */
private File mavenHome;
- /**
- * Project verifier
- */
+ /** Project verifier */
private ProjectVerifier projectVerifier;
/** Plugins cache. */
@@ -205,11 +176,6 @@
/** Plugin-loading tracker. */
private Set loadedPlugins;
-
- /**
- * classloaders
- */
- //private HashMap classloaders = new HashMap();
/**
* Construct.
1.12 +22 -46
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.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- ProjectVerifier.java 21 Oct 2002 23:37:33 -0000 1.11
+++ ProjectVerifier.java 11 Nov 2002 02:42:10 -0000 1.12
@@ -88,77 +88,55 @@
*
* @author <a href="[EMAIL PROTECTED]">Jason van Zyl</a>
* @author <a href="[EMAIL PROTECTED]">Vincent Massol</a>
+ *
* @version $Id$
- * @task Create a list of all things that could go wrong and then protect
+ *
+ * @todo Create a list of all things that could go wrong and then protect
* against them.
- * @task Merge the XML POM validation mechanism in here.
+ * @todo Merge the XML POM validation mechanism in here.
*/
public class ProjectVerifier
{
/** Log. */
private static final Log log = LogFactory.getLog(ProjectVerifier.class);
+ /** Maven project. */
private Project mavenProject;
/** Maven local repo */
private String mavenLocalRepo;
- /**
- * Maven remote repo locations
- */
+ /** Maven remote repo locations */
private List mavenRemoteRepos = new ArrayList();
- /**
- * Verbosity during downloading of missing resources.
- */
+ /** Verbosity during downloading of missing resources. */
private boolean verbose = false;
- /**
- * Control the use of timestamp comparison when downloading
- * missing resources.
- */
+ /** Control the use of timestamp comparison when downloading missing resources.
*/
private boolean useTimestamp = true;
- /**
- * Control continuation upon errors during the
- * downloading of missing resources.
- */
+ /** Control continuation upon errors during the downloading of missing
resources. */
private boolean ignoreErrors = true;
- /**
- * Container for storing warnings about JARs that cannot be
- * distributed by Maven.
- */
+ /** Container for storing warnings about JARs that cannot be distributed by
Maven. */
private StringBuffer warnings = new StringBuffer();
- /**
- * List of failed deps.
- */
+ /** List of failed deps. */
private List failedDependencies;
- /**
- * Map of failed downloads. Key is URL, value is Boolean
- */
+ /** Map of failed downloads. Key is URL, value is Boolean */
private Map failedDownloads = new HashMap();
- /**
- * Proxy host
- */
+ /** Proxy host */
private String proxyHost;
- /**
- * Proxy port
- */
+ /** Proxy port */
private String proxyPort;
- /**
- * Proxy userName
- */
+ /** Proxy userName */
private String proxyUserName;
- /**
- * Proxy password
- */
+ /** Proxy password */
private String proxyPassword;
/**
@@ -171,24 +149,22 @@
/** whether the user is 'online' */
private boolean online = true;
- /**
- * Maven Jelly context being used.
- */
+ /** Maven Jelly context being used. */
private MavenJellyContext context;
- /**
- * Default ctor.
- */
+ /** Default ctor. */
public ProjectVerifier()
{
failedDependencies = new ArrayList();
}
-
+
+ /** Set the Maven project. */
public void setMavenProject(Project mavenProject)
{
this.mavenProject = mavenProject;
}
+ /** Get the Maven project. */
public Project getMavenProject()
{
return mavenProject;
--
To unsubscribe, e-mail: <mailto:turbine-maven-dev-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:turbine-maven-dev-help@;jakarta.apache.org>