From 10a699cb4c2a27d1e0af6091b12cd39bed39b257 Mon Sep 17 00:00:00 2001 From: Jon Skeet Date: Sun, 24 Feb 2002 08:56:14 +0000 Subject: [PATCH] JavaDoc comments. Note that the comments for setProject say that only Project should use this method - whereas there are *lots* of uses outside Project... git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@271532 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/tools/ant/ProjectComponent.java | 25 +++++++++++-------- 1 file changed, 15 insertions(+), 10 deletions(-) diff --git a/src/main/org/apache/tools/ant/ProjectComponent.java b/src/main/org/apache/tools/ant/ProjectComponent.java index 8a3fd6e85..da1c3aa9e 100644 --- a/src/main/org/apache/tools/ant/ProjectComponent.java +++ b/src/main/org/apache/tools/ant/ProjectComponent.java @@ -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 Conor MacNeill */ 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 null. */ 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 @@ public abstract class ProjectComponent { } /** - * 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 null. */ 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 null. * @param msgLevel the message priority at which this message is to be logged. */ public void log(String msg, int msgLevel) { @@ -107,4 +113,3 @@ public abstract class ProjectComponent { } } } -