jskeet 02/02/24 00:56:14
Modified: src/main/org/apache/tools/ant ProjectComponent.java
Log:
JavaDoc comments.
Note that the comments for setProject say that only Project should use this
method - whereas there are *lots* of uses outside Project...
Revision Changes Path
1.2 +15 -10
jakarta-ant/src/main/org/apache/tools/ant/ProjectComponent.java
Index: ProjectComponent.java
===================================================================
RCS file:
/home/cvs/jakarta-ant/src/main/org/apache/tools/ant/ProjectComponent.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- ProjectComponent.java 4 Aug 2001 14:30:36 -0000 1.1
+++ ProjectComponent.java 24 Feb 2002 08:56:14 -0000 1.2
@@ -1,7 +1,7 @@
/*
* The Apache Software License, Version 1.1
*
- * Copyright (c) 2001 The Apache Software Foundation. All rights
+ * Copyright (c) 2001,2002 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -55,30 +55,36 @@
package org.apache.tools.ant;
/**
- * Base class for components of a project, including tasks and data types.
Provides
- * common facilities.
+ * Base class for components of a project, including tasks and data types.
+ * Provides common facilities.
*
* @author <a href="mailto:[EMAIL PROTECTED]">Conor MacNeill</a>
*/
public abstract class ProjectComponent {
+ /** Project object of this component. */
protected Project project = null;
+ /** Sole constructor. */
+ public ProjectComponent() {
+ }
+
/**
* Sets the project object of this component. This method is used by
- * project when a component is added to it so that the component has
+ * Project when a component is added to it so that the component has
* access to the functions of the project. It should not be used
* for any other purpose.
*
* @param project Project in whose scope this component belongs.
+ * Must not be <code>null</code>.
*/
public void setProject(Project project) {
this.project = project;
}
/**
- * Get the Project to which this component belongs
+ * Returns the project to which this component belongs.
*
* @return the components's project.
*/
@@ -87,18 +93,18 @@
}
/**
- * Log a message with the default (INFO) priority.
+ * Logs a message with the default (INFO) priority.
*
- * @param the message to be logged.
+ * @param msg The message to be logged. Should not be <code>null</code>.
*/
public void log(String msg) {
log(msg, Project.MSG_INFO);
}
/**
- * Log a mesage with the give priority.
+ * Logs a mesage with the given priority.
*
- * @param the message to be logged.
+ * @param msg The message to be logged. Should not be <code>null</code>.
* @param msgLevel the message priority at which this message is to be
logged.
*/
public void log(String msg, int msgLevel) {
@@ -107,4 +113,3 @@
}
}
}
-
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>