avalon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mcconn...@apache.org
Subject cvs commit: avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/tools/ant FormatEnum.java MetaTask.java
Date Sat, 29 Mar 2003 10:13:37 GMT
mcconnell    2003/03/29 02:13:36

  Modified:    merlin/meta-tools .cvsignore
               merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder
                        DefaultServiceBuilder.java DefaultTypeBuilder.java
                        XMLServiceWriter.java XMLTypeWriter.java
               merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags
                        AbstractTag.java AttributeTag.java ContextTag.java
                        DependencyTag.java ExtensionTag.java
                        LifestyleTag.java LoggerTag.java NameTag.java
                        ServicesTag.java StageTag.java Tags.java
                        VersionTag.java
               merlin/meta-tools/src/java/org/apache/avalon/meta/tools/ant
                        FormatEnum.java MetaTask.java
  Log:
  Updates to resolve checkstyle compliance for the package.
  
  Revision  Changes    Path
  1.2       +1 -0      avalon-sandbox/merlin/meta-tools/.cvsignore
  
  Index: .cvsignore
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/.cvsignore,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- .cvsignore	29 Mar 2003 03:12:58 -0000	1.1
  +++ .cvsignore	29 Mar 2003 10:13:35 -0000	1.2
  @@ -1 +1,2 @@
   target
  +maven.log
  \ No newline at end of file
  
  
  
  1.2       +1 -4      avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/DefaultServiceBuilder.java
  
  Index: DefaultServiceBuilder.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/DefaultServiceBuilder.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DefaultServiceBuilder.java	29 Mar 2003 03:12:58 -0000	1.1
  +++ DefaultServiceBuilder.java	29 Mar 2003 10:13:35 -0000	1.2
  @@ -50,10 +50,7 @@
   package org.apache.avalon.meta.info.builder;
   
   import java.util.Properties;
  -import com.thoughtworks.qdox.model.DocletTag;
   import com.thoughtworks.qdox.model.JavaClass;
  -import com.thoughtworks.qdox.model.JavaMethod;
  -import java.util.ArrayList;
   import org.apache.avalon.framework.Version;
   import org.apache.avalon.meta.info.Service;
   import org.apache.avalon.meta.info.ReferenceDescriptor;
  
  
  
  1.2       +4 -6      avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/DefaultTypeBuilder.java
  
  Index: DefaultTypeBuilder.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/DefaultTypeBuilder.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DefaultTypeBuilder.java	29 Mar 2003 03:12:58 -0000	1.1
  +++ DefaultTypeBuilder.java	29 Mar 2003 10:13:35 -0000	1.2
  @@ -50,19 +50,14 @@
   package org.apache.avalon.meta.info.builder;
   
   import java.util.Properties;
  -import com.thoughtworks.qdox.model.DocletTag;
   import com.thoughtworks.qdox.model.JavaClass;
  -import com.thoughtworks.qdox.model.JavaMethod;
  -import java.util.ArrayList;
   import org.apache.avalon.framework.Version;
   import org.apache.avalon.meta.info.InfoDescriptor;
   import org.apache.avalon.meta.info.Type;
   import org.apache.avalon.meta.info.ContextDescriptor;
   import org.apache.avalon.meta.info.DependencyDescriptor;
  -import org.apache.avalon.meta.info.EntryDescriptor;
   import org.apache.avalon.meta.info.LoggerDescriptor;
   import org.apache.avalon.meta.info.ServiceDescriptor;
  -import org.apache.avalon.meta.info.ReferenceDescriptor;
   import org.apache.avalon.meta.info.StageDescriptor;
   import org.apache.avalon.meta.info.ExtensionDescriptor;
   import org.apache.avalon.meta.info.builder.tags.NameTag;
  @@ -86,6 +81,9 @@
    */
   public class DefaultTypeBuilder
   {
  +    /**
  +     * Context URN for the lifestyle policy.
  +     */
        public static final String LIFESTYLE_URN = "urn:avalon:lifestyle";
   
       /**
  
  
  
  1.2       +6 -6      avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/XMLServiceWriter.java
  
  Index: XMLServiceWriter.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/XMLServiceWriter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XMLServiceWriter.java	29 Mar 2003 03:13:00 -0000	1.1
  +++ XMLServiceWriter.java	29 Mar 2003 10:13:35 -0000	1.2
  @@ -69,9 +69,9 @@
       /**
        * Write out type representation to xml.
        *
  -     * @param type the type object
  +     * @param service the service descriptor instance
        * @param stream the stream to write to
  -     * @throws IOException if unable to write xml
  +     * @throws Exception if unable to write xml
        */
       public void writeService( final Service service, final OutputStream stream )
           throws Exception
  @@ -113,9 +113,9 @@
           throws IOException
       {
           final String doctype =
  -            "\n<!DOCTYPE " + root +
  -            " PUBLIC \"-//AVALON/Service DTD Version 1.0//EN\" " +
  -            "\"http://avalon.apache.org/dtds/meta/service_1_0.dtd\" >";
  +            "\n<!DOCTYPE " + root
  +            + " PUBLIC \"-//AVALON/Service DTD Version 1.0//EN\" "
  +            + "\"http://avalon.apache.org/dtds/meta/service_1_0.dtd\" >";
           writer.write( doctype );
       }
   
  
  
  
  1.2       +8 -10     avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/XMLTypeWriter.java
  
  Index: XMLTypeWriter.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/XMLTypeWriter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XMLTypeWriter.java	29 Mar 2003 03:13:01 -0000	1.1
  +++ XMLTypeWriter.java	29 Mar 2003 10:13:35 -0000	1.2
  @@ -62,8 +62,6 @@
   import org.apache.avalon.meta.info.DependencyDescriptor;
   import org.apache.avalon.meta.info.Descriptor;
   
  -//import org.apache.avalon.meta.info.SchemaDescriptor;
  -
   /**
    * Write {@link Type} objects to a stream as xml documents.
    *
  @@ -83,7 +81,7 @@
        *
        * @param type the type object
        * @param outputStream the stream to write to
  -     * @throws IOException if unable to write xml
  +     * @throws Exception if unable to write xml
        */
       public void writeType( final Type type,
                                       final OutputStream outputStream )
  @@ -125,9 +123,9 @@
           throws IOException
       {
           final String doctype =
  -            "\n<!DOCTYPE " + root +
  -            " PUBLIC \"-//AVALON/Type DTD Version 1.0//EN\" " +
  -            "\"http://avalon.apache.org/dtds/meta/type_1_1.dtd\" >";
  +            "\n<!DOCTYPE " + root
  +            + " PUBLIC \"-//AVALON/Type DTD Version 1.0//EN\" "
  +            + "\"http://avalon.apache.org/dtds/meta/type_1_1.dtd\" >";
           writer.write( doctype );
       }
   
  @@ -226,9 +224,9 @@
           final EntryDescriptor[] entrys = context.getEntries();
           final int count = context.getAttributeNames().length;
   
  -        if( CONTEXT_CLASS.equals( type ) &&
  -            0 == count &&
  -            0 == entrys.length )
  +        if( CONTEXT_CLASS.equals( type ) 
  +            && 0 == count
  +            && 0 == entrys.length )
           {
               return;
           }
  
  
  
  1.2       +25 -12    avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/AbstractTag.java
  
  Index: AbstractTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/AbstractTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractTag.java	29 Mar 2003 03:13:01 -0000	1.1
  +++ AbstractTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -66,11 +66,19 @@
   
       private JavaClass m_class;
   
  +   /**
  +    * Class constructor.
  +    * @param clazz the javadoc class descriptor
  +    */
       public AbstractTag( final JavaClass clazz )
       {
           m_class = clazz;
       }
   
  +   /**
  +    * Return the javadoc class descriptor.
  +    * @return the javadoc class descriptor
  +    */
       protected JavaClass getJavaClass()
       {
           return m_class;
  @@ -80,6 +88,9 @@
       * Return the user defined namespace for avalon tags. The value returned is established
       * by the javadoc tag 'avalon.namespace [namespace-value]' where 
       * [namespace-value] is a string representing the namespace identifier.
  +    * @return the namespace tag used to represent the avalon.meta tag space
  +    * @exception IllegalArgumentException if the namespace tag is declared by does not

  +    *   contain a value
       */
       public String getNS() throws IllegalArgumentException
       {
  @@ -110,6 +121,9 @@
       * by the javadoc tag 'avalon.namespace [namespace-value]' where 
       * [namespace-value] is a string representing the namespace identifier
       * with the namespace delimiter appended.
  +    * @return the namespace tag with delimeter
  +    * @exception IllegalArgumentException if the namespace tag is declared by does not

  +    *   contain a value
       */
       public String getNSD() throws IllegalArgumentException
       {
  @@ -122,6 +136,7 @@
        *
        * @param tag the tag
        * @param name the name of parameter
  +     * @param defaultValue the default value
        * @return the value of named parameter
        */
       protected String getNamedParameter( final DocletTag tag,
  @@ -159,8 +174,8 @@
           if( null == value )
           {
               final String message =
  -                "Malformed tag '" + tag.getName() + "'. " +
  -                "Missing required parameter '" + name + "'";
  +                "Malformed tag '" + tag.getName() + "'. "
  +                + "Missing required parameter '" + name + "'";
               throw new IllegalArgumentException( message );
           }
           return value;
  @@ -176,7 +191,7 @@
       {
           if( type.indexOf(":") > -1 )
           {
  -            return Version.getVersion( type.substring( type.indexOf(":") +1 ) );
  +            return Version.getVersion( type.substring( type.indexOf(":") + 1 ) );
           }
           return null;
       }
  @@ -186,9 +201,8 @@
        * Resolving essentially means finding the fully qualified name of
        * a class from just it's short name.
        *
  -     * @param javaClass the java class relative to which the type must be resolved
  -     * @param type the unresolved type
  -     * @return the resolved type
  +     * @param type the unresolved type classname
  +     * @return the resolved type classname
        */
       protected String resolveType( final String type )
       {
  @@ -204,7 +218,6 @@
        * Retrieve a method with specified name and one parameter of specified
        * type. The method must also return void.
        *
  -     * @param javaClass the java class to retrieve method for
        * @param methodName the name of the method
        * @param parameterType the class name of parameter
        * @return the method if such a method exists
  @@ -216,10 +229,10 @@
           for( int i = 0; i < methods.length; i++ )
           {
               final JavaMethod method = methods[ i ];
  -            if( methodName.equals( method.getName() ) &&
  -                method.getReturns().equals( new Type( "void", 0 ) ) &&
  -                method.getParameters().length == 1 &&
  -                method.getParameters()[ 0 ].getType().getValue().equals( parameterType
) )
  +            if( methodName.equals( method.getName() ) 
  +                && method.getReturns().equals( new Type( "void", 0 ) ) 
  +                && method.getParameters().length == 1 
  +                && method.getParameters()[ 0 ].getType().getValue().equals( parameterType
) )
               {
                   return method;
               }
  
  
  
  1.2       +17 -4     avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/AttributeTag.java
  
  Index: AttributeTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/AttributeTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AttributeTag.java	29 Mar 2003 03:13:01 -0000	1.1
  +++ AttributeTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -61,10 +61,25 @@
    */
   public class AttributeTag extends AbstractTag
   {
  +   /**
  +    * The javadoc key for the attribute tag.
  +    */
       public static final String KEY = "attribute";
  +
  +   /**
  +    * The parameter name for the attribute key.
  +    */
       public static final String KEY_PARAM = "key";
  +
  +   /**
  +    * The parameter name for the attribute value.
  +    */
       public static final String VALUE_PARAM = "value";
   
  +   /**
  +    * Creation of a new attribute tag.
  +    * @param clazz the javadoc class descriptor
  +    */
       public AttributeTag( final JavaClass clazz )
       {
           super( clazz );
  @@ -72,9 +87,7 @@
   
      /**
       * Return the value of all Avalon 'attribute' tags as a Properties value.
  -    * @return the attributes as a property instance
  -    * @exception IllegalArgumentException if an attribute tag is declared but 
  -    *   does not contain a key or value parameter
  +    * @return the attribute set as a property instance
       */
       public Properties getProperties()
       {
  
  
  
  1.2       +30 -4     avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/ContextTag.java
  
  Index: ContextTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/ContextTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ContextTag.java	29 Mar 2003 03:13:02 -0000	1.1
  +++ ContextTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -55,7 +55,6 @@
   import com.thoughtworks.qdox.model.JavaMethod;
   import com.thoughtworks.qdox.model.DocletTag;
   
  -import org.apache.avalon.framework.Version;
   import org.apache.avalon.meta.info.ContextDescriptor;
   import org.apache.avalon.meta.info.EntryDescriptor;
   import org.apache.avalon.meta.info.ReferenceDescriptor;
  @@ -68,18 +67,46 @@
    */
   public class ContextTag extends AbstractTag
   {
  +   /**
  +    * The default context class.
  +    */
       protected static final String CONTEXT_CLASS = 
           "org.apache.avalon.framework.context.Context";
   
  +   /**
  +    * The javadoc key for the context tag.
  +    */
       public static final String KEY = "context";
   
  +   /**
  +    * The javadoc context tag type parameter.
  +    */
       public static final String TYPE_PARAM = "type";
  +
  +   /**
  +    * The javadoc context tag key parameter.
  +    */
       public static final String KEY_PARAM = "key";
  +
  +   /**
  +    * The javadoc context tag alias parameter.
  +    */
       public static final String ALIAS_PARAM = "alias";
  +
  +   /**
  +    * The javadoc context tag optional parameter.
  +    */
       public static final String OPTIONAL_PARAM = "optional";
   
  +   /**
  +    * The javadoc context entry tag name.
  +    */
       public static final String ENTRY = "entry";
   
  +   /**
  +    * Context tag constructor.
  +    * @param clazz the javadoc class descriptor
  +    */
       public ContextTag( final JavaClass clazz )
       {
           super( clazz );
  @@ -87,8 +114,7 @@
   
      /**
       * Return an array of StageDescriptor instances based on declared 'stage' tags.
  -    * @return the stage descriptors
  -    * @exception IllegalArgumentException if the tag is declared but does not contain a
value
  +    * @return the context descriptors
       */
       public ContextDescriptor getContext()
       {
  
  
  
  1.2       +24 -2     avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/DependencyTag.java
  
  Index: DependencyTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/DependencyTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DependencyTag.java	29 Mar 2003 03:13:02 -0000	1.1
  +++ DependencyTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -67,22 +67,45 @@
    */
   public class DependencyTag extends AbstractTag
   {
  +   /**
  +    * The dependency tag name.
  +    */
       public static final String KEY = "dependency";
   
  +   /**
  +    * The dependency tag type parameter name.
  +    */
       public static final String TYPE_PARAM = "type";
   
  +   /**
  +    * The dependency tag key parameter name.
  +    */
       public static final String KEY_PARAM = "key";
   
  +   /**
  +    * The dependency tag optional parameter name.
  +    */
       public static final String OPTIONAL_PARAM = "optional";
   
  +   /**
  +    * The default component manager class.
  +    */
       protected static final String COMPONENT_MANAGER_CLASS =
           "org.apache.avalon.framework.component.ComponentManager";
   
  +   /**
  +    * The default service manager class.
  +    */
       protected static final String SERVICE_MANAGER_CLASS =
           "org.apache.avalon.framework.service.ServiceManager";
   
       private JavaMethod m_method;
   
  +
  +   /**
  +    * Class constructor.
  +    * @param clazz the javadoc class descriptor
  +    */
       public DependencyTag( final JavaClass clazz )
       {
           super( clazz );
  @@ -93,7 +116,6 @@
       * Return the array of dependency descriptors based on the set of 
       * 'dependency' tags associated with the components compose or service method.
       * @return the set of dependencies
  -    * @exception IllegalArgumentException if a tag is declared but does not contain a value
       */
       public DependencyDescriptor[] getDependencies()
       {
  
  
  
  1.2       +12 -4     avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/ExtensionTag.java
  
  Index: ExtensionTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/ExtensionTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ExtensionTag.java	29 Mar 2003 03:13:02 -0000	1.1
  +++ ExtensionTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -54,9 +54,7 @@
   import com.thoughtworks.qdox.model.JavaClass;
   import com.thoughtworks.qdox.model.DocletTag;
   
  -import org.apache.avalon.framework.Version;
   import org.apache.avalon.meta.info.ExtensionDescriptor;
  -import org.apache.avalon.meta.info.ReferenceDescriptor;
   
   /**
    * A doclet tag handler for the 'extension' tag.
  @@ -66,10 +64,21 @@
    */
   public class ExtensionTag extends AbstractTag
   {
  +
  +   /**
  +    * The javadoc key for the extension tag.
  +    */
       public static final String KEY = "extension";
   
  +   /**
  +    * The extension type parameter name.
  +    */
       public static final String TYPE_PARAM = "type";
   
  +   /**
  +    * The extension tag constructor.
  +    * @param clazz the javadoc class descriptor.
  +    */
       public ExtensionTag( final JavaClass clazz )
       {
           super( clazz );
  @@ -78,7 +87,6 @@
      /**
       * Return an array of StageDescriptor instances based on declared 'stage' tags.
       * @return the stage descriptors
  -    * @exception IllegalArgumentException if the tag is declared but does not contain a
value
       */
       public ExtensionDescriptor[] getExtensions()
       {
  
  
  
  1.2       +9 -1      avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/LifestyleTag.java
  
  Index: LifestyleTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/LifestyleTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LifestyleTag.java	29 Mar 2003 03:13:03 -0000	1.1
  +++ LifestyleTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -60,8 +60,16 @@
    */
   public class LifestyleTag extends AbstractTag
   {
  +
  +   /**
  +    * The javadoc key for the lifestyle tag.
  +    */
       public static final String KEY = "lifestyle";
   
  +   /**
  +    * Creation of a new lifestyle tag.
  +    * @param clazz the javadoc class descriptor
  +    */
       public LifestyleTag( final JavaClass clazz )
       {
           super( clazz );
  
  
  
  1.2       +16 -4     avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/LoggerTag.java
  
  Index: LoggerTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/LoggerTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LoggerTag.java	29 Mar 2003 03:13:03 -0000	1.1
  +++ LoggerTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -55,7 +55,6 @@
   import com.thoughtworks.qdox.model.DocletTag;
   import com.thoughtworks.qdox.model.JavaMethod;
   
  -import org.apache.avalon.framework.Version;
   import org.apache.avalon.meta.info.LoggerDescriptor;
   
   /**
  @@ -66,12 +65,26 @@
    */
   public class LoggerTag extends AbstractTag
   {
  +   /**
  +    * The javadoc key for the logger tag.
  +    */
       protected static final String KEY = "logger";
  +
  +   /**
  +    * The javadoc parameter name for the logging channel name
  +    */
       public static final String NAME_PARAM = "name";
   
  +   /**
  +    * The default logger class.
  +    */
       protected static final String LOGGER_CLASS =
           "org.apache.avalon.framework.logger.Logger";
   
  +   /**
  +    * The logger tag constructor.
  +    * @param clazz the javadoc class descriptor.
  +    */
       public LoggerTag( final JavaClass clazz )
       {
           super( clazz );
  @@ -80,8 +93,7 @@
      /**
       * Return an array of logger descriptors relative to the 'logger' tags declared under
the 
       * LogEnabled interface.
  -    * @return the set of lofgger descriptos
  -    * @exception IllegalArgumentException if the tag is declared but does not contain a
value
  +    * @return the set of logger descriptos
       */
       public LoggerDescriptor[] getLoggers()
       {
  
  
  
  1.2       +9 -1      avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/NameTag.java
  
  Index: NameTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/NameTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- NameTag.java	29 Mar 2003 03:13:03 -0000	1.1
  +++ NameTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -60,8 +60,15 @@
    */
   public class NameTag extends AbstractTag
   {
  +   /**
  +    * Javadoc tag key for the name tag.
  +    */
       public static final String KEY = "name";
   
  +   /**
  +    * Name tag constructor.
  +    * @param clazz the javadoc class descriptor
  +    */
       public NameTag( final JavaClass clazz )
       {
           super( clazz );
  @@ -69,6 +76,7 @@
   
      /**
       * Return the value of the Avalon 'name' tag.
  +    * @return the name of the component type
       * @exception IllegalArgumentException if the name tag does not contain a value
       */
       public String getName()
  
  
  
  1.2       +14 -5     avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/ServicesTag.java
  
  Index: ServicesTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/ServicesTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ServicesTag.java	29 Mar 2003 03:13:04 -0000	1.1
  +++ ServicesTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -59,26 +59,35 @@
   import org.apache.avalon.meta.info.ReferenceDescriptor;
   
   /**
  - * A doclet tag representing the lifestyle assigned to the Type.
  + * A doclet tag representing services exported by a type.
    *
    * @author <a href="mailto:dev@avalon.apache.org">Avalon Development Team</a>
    * @version $Revision$ $Date$
    */
   public class ServicesTag extends AbstractTag
   {
  +   /**
  +    * The service export tag key.
  +    */
       public static final String KEY = "service";
   
  +   /**
  +    * The service export type parameter name.
  +    */
       public static final String TYPE_PARAM = "type";
   
  +   /**
  +    * The service tag constructor.
  +    * @param clazz the javadoc class descriptor
  +    */
       public ServicesTag( final JavaClass clazz )
       {
           super( clazz );
       }
   
      /**
  -    * Return the value of the Avalon 'version' tag.
  -    * @return the version value
  -    * @exception IllegalArgumentException if the tag is declared but does not contain a
value
  +    * Return the the set of exported services.
  +    * @return an array of service descriptors
       */
       public ServiceDescriptor[] getServices()
       {
  
  
  
  1.2       +11 -4     avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/StageTag.java
  
  Index: StageTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/StageTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- StageTag.java	29 Mar 2003 03:13:04 -0000	1.1
  +++ StageTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -53,10 +53,7 @@
   
   import com.thoughtworks.qdox.model.JavaClass;
   import com.thoughtworks.qdox.model.DocletTag;
  -
  -import org.apache.avalon.framework.Version;
   import org.apache.avalon.meta.info.StageDescriptor;
  -import org.apache.avalon.meta.info.ReferenceDescriptor;
   
   /**
    * A doclet tag handler for the 'stage' tag.
  @@ -66,10 +63,20 @@
    */
   public class StageTag extends AbstractTag
   {
  +   /**
  +    * The stage tag key.
  +    */
       public static final String KEY = "stage";
   
  +   /**
  +    * The stage tag type parameter name.
  +    */
       public static final String TYPE_PARAM = "type";
   
  +   /**
  +    * Stage tag constructor.
  +    * @param clazz the javadoc class descriptor
  +    */
       public StageTag( final JavaClass clazz )
       {
           super( clazz );
  
  
  
  1.2       +12 -1     avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/Tags.java
  
  Index: Tags.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/Tags.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- Tags.java	29 Mar 2003 03:13:04 -0000	1.1
  +++ Tags.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -57,7 +57,18 @@
    */
   public interface Tags
   {
  +   /**
  +    * The defalt namespace for tags related to the meta package.
  +    */ 
       public static final String NAMESPACE = "avalon.meta";
  +
  +   /**
  +    * The delimiter between namespace and tag key.
  +    */
       public static final String DELIMITER = ".";
  +
  +   /**
  +    * The namespace tag combined with the delimiter.
  +    */
       public static final String NAMESPACE_TAG = NAMESPACE + DELIMITER + "namespace";
   }
  
  
  
  1.2       +10 -1     avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/VersionTag.java
  
  Index: VersionTag.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/info/builder/tags/VersionTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- VersionTag.java	29 Mar 2003 03:13:04 -0000	1.1
  +++ VersionTag.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -61,8 +61,15 @@
    */
   public class VersionTag extends AbstractTag
   {
  +   /**
  +    * The version tag key.
  +    */
       public static final String KEY = "version";
   
  +   /**
  +    * Version tag constructor.
  +    * @param clazz the javadoc class descriptor
  +    */
       public VersionTag( final JavaClass clazz )
       {
           super( clazz );
  @@ -80,8 +87,10 @@
   
      /**
       * Return the value of the Avalon 'version' tag.
  +    * @param create policy concerning value creation if no version is defined
       * @return the version value
       * @exception IllegalArgumentException if the tag is declared but does not contain a
value
  +    *   and the creation policy is false
       */
       public Version getVersion( boolean create )
       {
  
  
  
  1.2       +9 -1      avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/tools/ant/FormatEnum.java
  
  Index: FormatEnum.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/tools/ant/FormatEnum.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- FormatEnum.java	29 Mar 2003 03:13:05 -0000	1.1
  +++ FormatEnum.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -61,6 +61,10 @@
   public class FormatEnum
       extends EnumeratedAttribute
   {
  +   /**
  +    * Return the external form code.
  +    * @return an int value corresponding to a serial or XML type enumeration
  +    */
       public int getTypeCode()
       {
           final String value = super.getValue();
  @@ -74,6 +78,10 @@
           }
       }
   
  +   /**
  +    * Return a string reparesentation of of the enumberation.
  +    * @return the enumeration as a string
  +    */
       public String[] getValues()
       {
           return new String[]{"xml", "serial"};
  
  
  
  1.2       +20 -17    avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/tools/ant/MetaTask.java
  
  Index: MetaTask.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/meta-tools/src/java/org/apache/avalon/meta/tools/ant/MetaTask.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- MetaTask.java	29 Mar 2003 03:13:10 -0000	1.1
  +++ MetaTask.java	29 Mar 2003 10:13:36 -0000	1.2
  @@ -50,7 +50,6 @@
   package org.apache.avalon.meta.tools.ant;
   
   import com.thoughtworks.qdox.ant.AbstractQdoxTask;
  -import com.thoughtworks.qdox.model.DocletTag;
   import com.thoughtworks.qdox.model.JavaClass;
   import java.io.File;
   import java.io.IOException;
  @@ -67,7 +66,6 @@
   import org.apache.avalon.meta.info.builder.DefaultTypeBuilder;
   import org.apache.avalon.meta.info.builder.DefaultServiceBuilder;
   import org.apache.avalon.meta.info.builder.tags.VersionTag;
  -import org.apache.avalon.meta.tools.ant.FormatEnum;
   import org.apache.tools.ant.BuildException;
   
   /**
  @@ -79,31 +77,35 @@
   public class MetaTask
       extends AbstractQdoxTask
   {
  -    /*
  -    * A set of type codes for format.
  +   /**
  +    * XML output type code.
       */
       public static final int XML_TYPE = 0;
  +
  +   /**
  +    * Serial output type code.
  +    */
       public static final int SER_TYPE = 1;
   
       /**
        * A utility object that writes out info as xml files.
        */
  -    private static final TypeWriter c_xmlWriter = new XMLTypeWriter();
  +    private static final TypeWriter XML_WRITER = new XMLTypeWriter();
   
       /**
        * A utility object that writes out info as serialized object files.
        */
  -    private static final TypeWriter c_serWriter = new SerializedTypeWriter();
  +    private static final TypeWriter SERIAL_WRITER = new SerializedTypeWriter();
   
       /**
        * A utility object that writes out a service as xml files.
        */
  -    private static final ServiceWriter c_xmlServiceWriter = new XMLServiceWriter();
  +    private static final ServiceWriter XML_SERVICE_WRITER = new XMLServiceWriter();
   
       /**
        * A utility object that writes out a service as serialized object files.
        */
  -    private static final ServiceWriter c_serServiceWriter = new SerializedServiceWriter();
  +    private static final ServiceWriter SERIAL_SERVICE_WRITER = new SerializedServiceWriter();
   
       /**
        * The destination directory for metadata files.
  @@ -155,6 +157,7 @@
   
       /**
        * Execute generator task.
  +     * @exception BuildException if a build error occurs
        */
       public void execute()
           throws BuildException
  @@ -262,8 +265,8 @@
   
                   if( !m_force )
                   {
  -                    if( dest.exists() &&
  -                        dest.lastModified() >= source.lastModified() )
  +                    if( dest.exists() 
  +                      && dest.lastModified() >= source.lastModified() )
                       {
                           continue;
                       }
  @@ -297,8 +300,8 @@
   
                   if( !m_force )
                   {
  -                    if( dest.exists() &&
  -                        dest.lastModified() >= source.lastModified() )
  +                    if( dest.exists() 
  +                      && dest.lastModified() >= source.lastModified() )
                       {
                           continue;
                       }
  @@ -384,11 +387,11 @@
       {
           if( SER_TYPE == m_format  )
           {
  -            return c_serWriter;
  +            return SERIAL_WRITER;
           }
           else
           {
  -            return c_xmlWriter;
  +            return XML_WRITER;
           }
       }
   
  @@ -406,11 +409,11 @@
       {
           if( SER_TYPE == m_format  )
           {
  -            return c_serServiceWriter;
  +            return SERIAL_SERVICE_WRITER;
           }
           else
           {
  -            return c_xmlServiceWriter;
  +            return XML_SERVICE_WRITER;
           }
       }
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: cvs-unsubscribe@avalon.apache.org
For additional commands, e-mail: cvs-help@avalon.apache.org


Mime
View raw message