ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jsk...@apache.org
Subject cvs commit: jakarta-ant/src/main/org/apache/tools/ant UnknownElement.java AntClassLoader.java XmlLogger.java ProjectHelper.java NoBannerLogger.java TaskAdapter.java DirectoryScanner.java IntrospectionHelper.java
Date Wed, 27 Mar 2002 09:48:20 GMT
jskeet      02/03/27 01:48:20

  Modified:    src/main/org/apache/tools/ant UnknownElement.java
                        AntClassLoader.java XmlLogger.java
                        ProjectHelper.java NoBannerLogger.java
                        TaskAdapter.java DirectoryScanner.java
                        IntrospectionHelper.java
  Log:
  Fixed up JavaDoc comments again.
  
  Revision  Changes    Path
  1.25      +7 -0      jakarta-ant/src/main/org/apache/tools/ant/UnknownElement.java
  
  Index: UnknownElement.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/UnknownElement.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -r1.24 -r1.25
  --- UnknownElement.java	19 Mar 2002 23:18:03 -0000	1.24
  +++ UnknownElement.java	27 Mar 2002 09:48:20 -0000	1.25
  @@ -187,6 +187,11 @@
        *
        * @param parent The configured object for the parent. 
        *               Must not be <code>null</code>.
  +     * 
  +     * @param parentWrapper The wrapper containing child wrappers
  +     *                      to be configured. Must not be <code>null</code>
  +     *                      if there are any children.
  +     * 
        * @exception BuildException if the children cannot be configured.
        */
       protected void handleChildren(Object parent,
  @@ -286,6 +291,8 @@
        *             <code>"task"</code>. Should not be <code>null</code>.
        * @param elementName The name of the element which could not be found.
        *                    Should not be <code>null</code>.
  +     * 
  +     * @return a detailed description of what might have caused the problem.
        */
       protected BuildException getNotFoundException(String what,
                                                     String elementName) {
  
  
  
  1.50      +1 -1      jakarta-ant/src/main/org/apache/tools/ant/AntClassLoader.java
  
  Index: AntClassLoader.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/AntClassLoader.java,v
  retrieving revision 1.49
  retrieving revision 1.50
  diff -u -r1.49 -r1.50
  --- AntClassLoader.java	19 Mar 2002 22:45:06 -0000	1.49
  +++ AntClassLoader.java	27 Mar 2002 09:48:20 -0000	1.50
  @@ -971,7 +971,7 @@
        * reading the class from the stream.
        */
       private Class getClassFromStream(InputStream stream, String classname)
  -                throws IOException {
  +                throws IOException, SecurityException {
           ByteArrayOutputStream baos = new ByteArrayOutputStream();
           int bytesRead = -1;
           byte[] buffer = new byte[BUFFER_SIZE];
  
  
  
  1.26      +7 -0      jakarta-ant/src/main/org/apache/tools/ant/XmlLogger.java
  
  Index: XmlLogger.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/XmlLogger.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -r1.25 -r1.26
  --- XmlLogger.java	23 Mar 2002 19:52:09 -0000	1.25
  +++ XmlLogger.java	27 Mar 2002 09:48:20 -0000	1.26
  @@ -92,6 +92,8 @@
       /** 
        * Returns a default DocumentBuilder instance or throws an
        * ExceptionInInitializerError if it can't be created.
  +     * 
  +     * @return a default DocumentBuilder instance.
        */
       private static DocumentBuilder getDocumentBuilder() {
           try {
  @@ -141,7 +143,12 @@
   
       /** Utility class representing the time an element started. */
       private static class TimedElement {
  +        /** 
  +         * Start time in milliseconds 
  +         * (as returned by <code>System.currentTimeMillis()</code>). 
  +         */
           long startTime;
  +        /** Element created at the start time. */ 
           Element element;
       }
   
  
  
  
  1.81      +33 -11    jakarta-ant/src/main/org/apache/tools/ant/ProjectHelper.java
  
  Index: ProjectHelper.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/ProjectHelper.java,v
  retrieving revision 1.80
  retrieving revision 1.81
  diff -u -r1.80 -r1.81
  --- ProjectHelper.java	19 Mar 2002 06:30:52 -0000	1.80
  +++ ProjectHelper.java	27 Mar 2002 09:48:20 -0000	1.81
  @@ -140,11 +140,19 @@
       }
   
       
  -    /** Discover a project helper instance. Uses the same patterns
  -     *  as JAXP, commons-logging, etc: a system property, a JDK1.3
  -     *  service discovery, default.
  +    /** 
  +     * Discovers a project helper instance. Uses the same patterns
  +     * as JAXP, commons-logging, etc: a system property, a JDK1.3
  +     * service discovery, default.
  +     * 
  +     * @return a ProjectHelper, either a custom implementation
  +     * if one is available and configured, or the default implementation
  +     * otherwise.
  +     * 
  +     * @exception BuildException if a specified helper class cannot
  +     * be loaded/instantiated.
        */
  -    public static ProjectHelper getProjectHelper()
  +    public static ProjectHelper getProjectHelper() 
           throws BuildException {
           // Identify the class loader we will be using. Ant may be
           // in a webapp or embeded in a different app
  @@ -206,9 +214,18 @@
           }
       }
   
  -    /** Create a new helper. It'll first try the thread class loader,
  -     *  then Class.forName() will load from the same loader that
  -     *  loaded this class.
  +    /** 
  +     * Creates a new helper instance from the name of the class. 
  +     * It'll first try the thread class loader, then Class.forName() 
  +     * will load from the same loader that loaded this class.
  +     * 
  +     * @param helperClass The name of the class to create an instance
  +     *                    of. Must not be <code>null</code>.
  +     * 
  +     * @return a new instance of the specified class.
  +     * 
  +     * @exception BuildException if the class cannot be found or
  +     * cannot be appropriate instantiated.
        */
       private static ProjectHelper newHelper(String helperClass)
           throws BuildException {
  @@ -232,11 +249,13 @@
       }
   
       /**
  -     *  JDK1.1 compatible access to the context class loader.
  -     *  Cut&paste from Jaxp.
  +     * JDK1.1 compatible access to the context class loader.
  +     * Cut&paste from JAXP.
  +     * 
  +     * @return the current context class loader, or <code>null</code>
  +     * if the context class loader is unavailable.
        */
  -    public static ClassLoader getContextClassLoader()
  -        throws BuildException {
  +    public static ClassLoader getContextClassLoader() {
           if (!LoaderUtils.isContextLoaderAvailable()) {
               return null;
           }
  @@ -357,6 +376,9 @@
        * Replaces <code>${xxx}</code> style constructions in the given value
with 
        * the string value of the corresponding properties.
        *
  +     * @param project The project containing the properties to replace.
  +     *                Must not be <code>null</code>.
  +     * 
        * @param value The string to be scanned for property references.
        *              May be <code>null</code>.
        *
  
  
  
  1.7       +5 -1      jakarta-ant/src/main/org/apache/tools/ant/NoBannerLogger.java
  
  Index: NoBannerLogger.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/NoBannerLogger.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- NoBannerLogger.java	24 Feb 2002 08:55:28 -0000	1.6
  +++ NoBannerLogger.java	27 Mar 2002 09:48:20 -0000	1.7
  @@ -87,7 +87,11 @@
           targetName = event.getTarget().getName();
       }
   
  -    /** Resets the current target name to <code>null</code>. */
  +    /** 
  +     * Resets the current target name to <code>null</code>.
  +     * 
  +     * @param event Ignored in this implementation.
  +     */
       public void targetFinished(BuildEvent event) {
           targetName = null;
       }
  
  
  
  1.15      +3 -0      jakarta-ant/src/main/org/apache/tools/ant/TaskAdapter.java
  
  Index: TaskAdapter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/TaskAdapter.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- TaskAdapter.java	25 Feb 2002 17:59:09 -0000	1.14
  +++ TaskAdapter.java	27 Mar 2002 09:48:20 -0000	1.15
  @@ -108,6 +108,9 @@
       
       /**
        * Executes the proxied task.
  +     * 
  +     * @exception BuildException if the project could not be set
  +     * or the method could not be executed.
        */
       public void execute() throws BuildException {
           Method setProjectM = null;
  
  
  
  1.23      +1 -1      jakarta-ant/src/main/org/apache/tools/ant/DirectoryScanner.java
  
  Index: DirectoryScanner.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/DirectoryScanner.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -r1.22 -r1.23
  --- DirectoryScanner.java	18 Feb 2002 18:27:58 -0000	1.22
  +++ DirectoryScanner.java	27 Mar 2002 09:48:20 -0000	1.23
  @@ -758,7 +758,7 @@
        *            incorrectly (i.e. if it is <code>null</code>, doesn't exist,
        *            or isn't a directory).
        */
  -    public void scan() {
  +    public void scan() throws IllegalStateException {
           if (basedir == null) {
               throw new IllegalStateException("No basedir set");
           }
  
  
  
  1.38      +4 -1      jakarta-ant/src/main/org/apache/tools/ant/IntrospectionHelper.java
  
  Index: IntrospectionHelper.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/IntrospectionHelper.java,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -r1.37 -r1.38
  --- IntrospectionHelper.java	24 Feb 2002 08:57:02 -0000	1.37
  +++ IntrospectionHelper.java	27 Mar 2002 09:48:20 -0000	1.38
  @@ -430,7 +430,8 @@
        *                           method is available to handle it, or if
        *                           the handling method fails.
        */
  -    public void addText(Project project, Object element, String text) {
  +    public void addText(Project project, Object element, String text) 
  +        throws BuildException {
           if (addText == null) {
               // Element doesn't handle text content
               if ( text.trim().length() == 0 ) {
  @@ -845,6 +846,8 @@
       /**
        * Clears all storage used by this class, including the static cache of 
        * helpers.
  +     * 
  +     * @param event Ignored in this implementation.
        */
       public void buildFinished(BuildEvent event) {
           attributeTypes.clear();
  
  
  

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message