avalon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From blorit...@apache.org
Subject cvs commit: avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/handler AbstractComponentHandler.java ComponentHandler.java LEAwareComponentHandler.java PrepareHandlerCommand.java
Date Fri, 14 Feb 2003 20:51:09 GMT
bloritsch    2003/02/14 12:51:08

  Modified:    fortress/src/java/org/apache/avalon/fortress/impl/handler
                        AbstractComponentHandler.java ComponentHandler.java
                        LEAwareComponentHandler.java
                        PrepareHandlerCommand.java
  Log:
  update with a hook for better problem reporting
  
  Revision  Changes    Path
  1.5       +12 -1     avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/handler/AbstractComponentHandler.java
  
  Index: AbstractComponentHandler.java
  ===================================================================
  RCS file: /home/cvs/avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/handler/AbstractComponentHandler.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- AbstractComponentHandler.java	12 Feb 2003 16:33:51 -0000	1.4
  +++ AbstractComponentHandler.java	14 Feb 2003 20:51:08 -0000	1.5
  @@ -143,6 +143,17 @@
       }
   
       /**
  +     * Return the component's class that this handler is trying to create.
  +     * Used for deubug information.
  +     *
  +     * @return the <code>Class</code> object for the component
  +     */
  +    public Class getComponentClass()
  +    {
  +        return m_factory.getCreatedClass();
  +    }
  +
  +    /**
        * Actually prepare the handler and make it ready to
        * handle component access.
        *
  
  
  
  1.3       +9 -1      avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/handler/ComponentHandler.java
  
  Index: ComponentHandler.java
  ===================================================================
  RCS file: /home/cvs/avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/handler/ComponentHandler.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ComponentHandler.java	7 Feb 2003 16:08:12 -0000	1.2
  +++ ComponentHandler.java	14 Feb 2003 20:51:08 -0000	1.3
  @@ -61,6 +61,14 @@
   public interface ComponentHandler
   {
       /**
  +     * Return the component's class that this handler is trying to create.
  +     * Used for deubug information.
  +     *
  +     * @return the <code>Class</code> object for the component
  +     */
  +    Class getComponentClass();
  +
  +    /**
        * Actually prepare the handler and make it ready to
        * handle component access.
        *
  
  
  
  1.3       +12 -1     avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/handler/LEAwareComponentHandler.java
  
  Index: LEAwareComponentHandler.java
  ===================================================================
  RCS file: /home/cvs/avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/handler/LEAwareComponentHandler.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- LEAwareComponentHandler.java	10 Feb 2003 15:47:00 -0000	1.2
  +++ LEAwareComponentHandler.java	14 Feb 2003 20:51:08 -0000	1.3
  @@ -96,6 +96,17 @@
           m_context = context;
       }
   
  +    /**
  +     * Return the component's class that this handler is trying to create.
  +     * Used for deubug information.
  +     *
  +     * @return the <code>Class</code> object for the component
  +     */
  +    public Class getComponentClass()
  +    {
  +        return m_componentHandler.getComponentClass();
  +    }
  +
      /**
       * Prepare the handler.
       * @exception Exception if a handler preparation error occurs
  
  
  
  1.4       +2 -2      avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/handler/PrepareHandlerCommand.java
  
  Index: PrepareHandlerCommand.java
  ===================================================================
  RCS file: /home/cvs/avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/handler/PrepareHandlerCommand.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- PrepareHandlerCommand.java	10 Feb 2003 15:47:00 -0000	1.3
  +++ PrepareHandlerCommand.java	14 Feb 2003 20:51:08 -0000	1.4
  @@ -91,7 +91,7 @@
           {
               if( m_logger.isErrorEnabled() )
               {
  -                m_logger.error( "Could not prepare ComponentHandler", e );
  +                m_logger.error( "Could not prepare ComponentHandler for: " + m_handler.getComponentClass().getName(),
e );
               }
   
               throw e;
  
  
  

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


Mime
View raw message