donaldp     2002/08/31 03:57:50

  Modified:    containerkit/src/java/org/apache/excalibur/containerkit/factory
                        ComponentFactory.java DefaultComponentBundle.java
                        DefaultComponentFactory.java
  Added:       containerkit/src/java/org/apache/excalibur/containerkit/factory
                        ComponentBundle.java
  Log:
  Move ComponentBundle out of info and back to the factory
  
  Revision  Changes    Path
  1.9       +3 -5      
jakarta-avalon-excalibur/containerkit/src/java/org/apache/excalibur/containerkit/factory/ComponentFactory.java
  
  Index: ComponentFactory.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-avalon-excalibur/containerkit/src/java/org/apache/excalibur/containerkit/factory/ComponentFactory.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- ComponentFactory.java     31 Aug 2002 09:18:16 -0000      1.8
  +++ ComponentFactory.java     31 Aug 2002 10:57:50 -0000      1.9
  @@ -7,11 +7,9 @@
    */
   package org.apache.excalibur.containerkit.factory;
   
  -import org.apache.avalon.framework.info.ComponentBundle;
  -
   /**
    * This interface defines the mechanism via which a
  - * component or its associated {@link ComponentBundle} can
  + * component or its associated {@link 
org.apache.excalibur.containerkit.factory.ComponentBundle} can
    * be created.
    *
    * <p>Usually the component or ComponentBundle will just be loaded
  @@ -34,7 +32,7 @@
       String ROLE = ComponentFactory.class.getName();
   
       /**
  -     * Create a {@link ComponentBundle} for component
  +     * Create a {@link org.apache.excalibur.containerkit.factory.ComponentBundle} 
for component
        * specified by implementationKey.
        *
        * @param implementationKey the key indicating type of component (usually 
classname)
  
  
  
  1.2       +1 -2      
jakarta-avalon-excalibur/containerkit/src/java/org/apache/excalibur/containerkit/factory/DefaultComponentBundle.java
  
  Index: DefaultComponentBundle.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-avalon-excalibur/containerkit/src/java/org/apache/excalibur/containerkit/factory/DefaultComponentBundle.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DefaultComponentBundle.java       31 Aug 2002 09:18:16 -0000      1.1
  +++ DefaultComponentBundle.java       31 Aug 2002 10:57:50 -0000      1.2
  @@ -7,7 +7,6 @@
    */
   package org.apache.excalibur.containerkit.factory;
   
  -import org.apache.avalon.framework.info.ComponentBundle;
   import org.apache.avalon.framework.info.ComponentInfo;
   import java.io.InputStream;
   
  
  
  
  1.11      +1 -2      
jakarta-avalon-excalibur/containerkit/src/java/org/apache/excalibur/containerkit/factory/DefaultComponentFactory.java
  
  Index: DefaultComponentFactory.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-avalon-excalibur/containerkit/src/java/org/apache/excalibur/containerkit/factory/DefaultComponentFactory.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- DefaultComponentFactory.java      31 Aug 2002 09:18:16 -0000      1.10
  +++ DefaultComponentFactory.java      31 Aug 2002 10:57:50 -0000      1.11
  @@ -12,7 +12,6 @@
   import org.apache.avalon.framework.logger.AbstractLogEnabled;
   import org.apache.avalon.framework.logger.Logger;
   import org.apache.avalon.framework.info.ComponentInfo;
  -import org.apache.avalon.framework.info.ComponentBundle;
   import org.apache.avalon.framework.tools.infobuilder.ComponentInfoBuilder;
   
   /**
  
  
  
  1.1                  
jakarta-avalon-excalibur/containerkit/src/java/org/apache/excalibur/containerkit/factory/ComponentBundle.java
  
  Index: ComponentBundle.java
  ===================================================================
  /*
   * Copyright (C) The Apache Software Foundation. All rights reserved.
   *
   * This software is published under the terms of the Apache Software License
   * version 1.1, a copy of which has been included with this distribution in
   * the LICENSE.txt file.
   */
  package org.apache.excalibur.containerkit.factory;
  
  import java.io.InputStream;
  import org.apache.avalon.framework.info.ComponentInfo;
  
  /**
   * The ComponentBundle gives access to the sum total of all the
   * metadata and resources about a component. This includes all
   * the resources associated with a particular component and the
   * associated {@link org.apache.avalon.framework.info.ComponentInfo}.
   *
   * <p>Additional resources that may be associated with a component
   * include but are not limited to;</p>
   *
   * <ul>
   *   <li>Resource property files for i18n of {@link 
org.apache.avalon.framework.info.ComponentInfo}</li>
   *   <li>XML schema or DTD that is used when validating a components
   *       configuration, such as in Phoenix.</li>
   *   <li>Descriptor used to define management interface of
   *       component.</li>
   *   <li>Prototype used to define a component profile.</li>
   * </ul>
   *
   * @author <a href="mailto:peter at apache.org">Peter Donald</a>
   * @version $Revision: 1.1 $ $Date: 2002/08/31 10:57:50 $
   */
  public interface ComponentBundle
  {
      /**
       * Return the {@link org.apache.avalon.framework.info.ComponentInfo} that 
describes the
       * component.
       *
       * @return the {@link org.apache.avalon.framework.info.ComponentInfo} that 
describes the component.
       */
      ComponentInfo getComponentInfo();
  
      /**
       * Return an input stream for a resource associated with
       * component. The resource name can be relative or absolute.
       * Absolute names being with a '/' character.
       *
       * <p>When the component is implemented via a Java class (as
       * opposed to a remote SOAP/RMI/JMX/other service), the resources
       * are loaded from the same <code>ClassLoader</code> as
       * implementation. The resources are loaded relative to the
       * implementaion classes package and are often named after the
       * classname of the component.</p>
       *
       * <p>For example, a component <code>com.biz.Foo</code> may have
       * resources such as <code>com/biz/Foo-schema.xsd</code>,
       * <code>com/biz/Foo.mxinfo</code> or
       * <code>com/biz/Foo-profile.xml</code>.</p>
       *
       * @return the input stream for associated resource, or null
       *         if no such resource
       */
      InputStream getResourceAsStream( String resource );
  }
  
  

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

Reply via email to