leosimons    2002/06/23 15:09:12

  Modified:    tweety/src/java/org/apache/avalon/excalibur/tweety
                        Tweety.java
               tweety/src/java/org/apache/avalon/excalibur/tweety/demos
                        ChirpWorld.java
  Added:       tweety/src/java/org/apache/avalon/excalibur/tweety
                        package.html
               tweety/src/java/org/apache/avalon/excalibur/tweety/demos
                        package.html
  Log:
  improve javadocs
  
  Revision  Changes    Path
  1.3       +24 -23    
jakarta-avalon-excalibur/tweety/src/java/org/apache/avalon/excalibur/tweety/Tweety.java
  
  Index: Tweety.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-avalon-excalibur/tweety/src/java/org/apache/avalon/excalibur/tweety/Tweety.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- Tweety.java       23 Jun 2002 20:26:44 -0000      1.2
  +++ Tweety.java       23 Jun 2002 22:09:12 -0000      1.3
  @@ -46,29 +46,30 @@
        // methods for them, this is the only way to make them accessible when
        // subclassing.
   
  -     /** we'll use this logger everywhere. It sends messages to the console. 
*/
  +     /** This logger is used by tweety and its managed components 
everywhere; it sends
  +     messages to the console. */
        protected Logger m_logger;
   
  -     /** all components share the same, global, Context. This is not what 
should
  -     really happen, but it does make Tweety a bit easier. */
  +     /** all components share the same, global, Context; this is not what 
should
  +     really happen in an actual avalon container, but it does make Tweety a 
bit easier. */
        protected Context m_context;
   
  -     /** all components share the same, global, Configuration. This is not 
what should
  -     really happen, but it does make Tweety a bit easier. */
  +     /** all components share the same, global, Configuration; this is not 
what should
  +     really happen in an actual avalon container, but it does make Tweety a 
bit easier. */
        protected Configuration m_configuration;
   
  -     /** all components share the same, global, ComponentManager.
  -     This would not happen in a real-life setup, but it makes the
  +     /** all components share the same, global, ComponentManager;
  +     this would not happen in a real-life setup, but it makes the
        code simpler. */
        protected DefaultComponentManager m_componentManager;
   
  -     /** all components share the same, global, ServiceManager.
  -     This would not happen in a real-life setup, but it makes the
  +     /** all components share the same, global, ServiceManager;
  +     this would not happen in a real-life setup, but it makes the
        code simpler. */
        protected DefaultServiceManager m_serviceManager;
   
        /**
  -      * this field is filled during <code>parameterize()</code> with a 
parameters�
  +      * this field is filled during <code>parameterize()</code> with a 
parameters
         * object that describes everything <code>Tweety</code> needs to run.
         * Usually, it contains information loaded from a tweety.properties 
file. A
         * sample <code>tweety.properties</code> file might look like this:
  @@ -91,17 +92,17 @@
   
        /**
         * This map will be used to store a reference to all the components
  -      * that tweety will manage. We fill it up during initialize().
  +      * that tweety will manage; We fill it up during initialize().
         */
        protected Map m_components;
   
        //// CONSTRUCTOR ////
        /**
  -      * Tweety has a single, public, no arguments constructor. We supply 
arguments
  +      * Tweety has a single, public, no arguments constructor; We supply 
arguments
         * at a later point in the form of an instance of 
<code>Parameters</code>
         * during parameterize().
         *
  -      * The constructor initializes our properties with default values.
  +      * <p>The constructor initializes our properties with default 
values.</p>
         */
        public Tweety()
        {
  @@ -109,13 +110,13 @@
   
        //// METHOD TO HANDLE RUNNING FROM COMMAND LINE ////
        /**
  -      * This method is called to invoke tweety from the command line. It 
instantiates
  +      * This method is called to invoke tweety from the command line; It 
instantiates
         * a new <code>Tweety</code> instance, provides the parameters to 
configure
         * tweety by loading them from a file, and then runs tweety itself 
through its
         * lifecycle.
         *
  -      * <b>Note:</b> we should improve this method to create a sensible 
context and
  -      * configuration for hosted components.
  +      * <p><b>Note:</b> we should improve this method to create a sensible 
context and
  +      * configuration for hosted components.</p>
         *
         * @param args the command line arguments. We don't use them.
         */
  @@ -173,7 +174,7 @@
   
        //// AVALON FRAMEWORK LIFECYCLE METHODS ////
        /**
  -      * Provide tweety with a logger. This logger will also be used for all 
the
  +      * Provide tweety with a logger; This logger will also be used for all 
the
         * components that tweety manages.
         *
         * @param logger the logger
  @@ -185,7 +186,7 @@
        }
   
       /**
  -     * Provide tweety with a context. This context will also be used for all 
the
  +     * Provide tweety with a context; This context will also be used for all 
the
         * components that tweety manages.
        *
        * @param context the context
  @@ -197,7 +198,7 @@
        }
   
       /**
  -     * Provide tweety with a configuration. This configuration will also be 
used for all the
  +     * Provide tweety with a configuration; This configuration will also be 
used for all the
         * components that tweety manages.
        *
        * @param configuration the class configurations.
  @@ -209,7 +210,7 @@
       }
   
       /**
  -     * Provide tweety with the parameters it needs to run. Each pair of name 
and
  +     * Provide tweety with the parameters it needs to run; Each pair of name 
and
         * value defines a <b>Role</b> and a component that implements that 
role.
        *
        * @param parameters the parameters
  @@ -259,7 +260,7 @@
        }
   
        /**
  -      * Initialize tweety. We create an instance of all the components 
tweety contains.
  +      * Initialize tweety; We create an instance of all the components 
tweety contains.
         */
        public void initialize()
        {
  @@ -309,7 +310,7 @@
        }
   
        /**
  -      * Start up tweety. We setup all the components tweety contains, add 
them to
  +      * Start up tweety; We setup all the components tweety contains, add 
them to
         * the global componentmanager and servicemanager, and finally we call 
start()
         * on each of them.
         */
  @@ -413,7 +414,7 @@
        }
   
        /**
  -      * Stop tweety. For each component tweety contains, we run their 
lifecycle from
  +      * Stop tweety; For each component tweety contains, we run their 
lifecycle from
         * their stop() method right up to dispose().
         */
        public void stop()
  
  
  
  1.1                  
jakarta-avalon-excalibur/tweety/src/java/org/apache/avalon/excalibur/tweety/package.html
  
  Index: package.html
  ===================================================================
  <html><body>
  <p>
  Very simple container for avalon components, written for educational purposes.
  Tweety is not intended for use in production environments, though there is
  nothing preventing you from using it for that purpose.
  </p>
  
  <h3>Goals</h3>
  <li>be well documented</li>
  <li>provide full support for the avalon framework interfaces</li>
  <li>provide support for nothing else</li>
  <li>use default framework implementations where possible</li>
  <li>sacrifice flexibility for readable code wherever possible</li>
  <li>sacrifice reusability for readable code wherever possible</li>
  <li>use the most simple configuration possible</li>
  <li>support only minimal metainfo (for example, no dependency mapping)</li>
  <li>no security</li>
  <li>minimal thread management</li>
  <li>no classloader management</li>
  <li>separation of engine and (mainable) embeddor</li>
  
  <h3>Use Case</h3>
  <p>An example of an avalon container for simple components, to use in
  teaching avalon concepts.</p>
  
  </body></html>
  
  
  1.3       +1 -1      
jakarta-avalon-excalibur/tweety/src/java/org/apache/avalon/excalibur/tweety/demos/ChirpWorld.java
  
  Index: ChirpWorld.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-avalon-excalibur/tweety/src/java/org/apache/avalon/excalibur/tweety/demos/ChirpWorld.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ChirpWorld.java   23 Jun 2002 20:26:44 -0000      1.2
  +++ ChirpWorld.java   23 Jun 2002 22:09:12 -0000      1.3
  @@ -17,7 +17,7 @@
   import org.apache.avalon.framework.container.*;
   
   /**
  - * Just... chirps :-)
  + * Does nothing but chirp whenever an avalon lifecycle method is called on 
it.
    *
    [EMAIL PROTECTED]     <a href="mailto:[EMAIL PROTECTED]">Nicola Ken 
Barozzi</a>
    [EMAIL PROTECTED]     <a href="mailto:[EMAIL PROTECTED]">Leo Simons</a>
  
  
  
  1.1                  
jakarta-avalon-excalibur/tweety/src/java/org/apache/avalon/excalibur/tweety/demos/package.html
  
  Index: package.html
  ===================================================================
  <html><body>
  Trivial avalon components to demonstrate the use of tweety and illustrate
  its features (or lack thereof).
  </body></html>
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to