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/merlin-core/src/java/org/apache/avalon/merlin/block/impl DefaultBlock.java
Date Mon, 17 Mar 2003 04:05:56 GMT
mcconnell    2003/03/16 20:05:56

  Modified:    merlin/merlin-core/src/java/org/apache/avalon/merlin/block/impl
                        DefaultBlock.java
  Log:
  Addition of dependency and service descriptors supplied under block contextualization.
  
  Revision  Changes    Path
  1.2       +36 -9     avalon-sandbox/merlin/merlin-core/src/java/org/apache/avalon/merlin/block/impl/DefaultBlock.java
  
  Index: DefaultBlock.java
  ===================================================================
  RCS file: /home/cvs/avalon-sandbox/merlin/merlin-core/src/java/org/apache/avalon/merlin/block/impl/DefaultBlock.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DefaultBlock.java	13 Mar 2003 01:05:02 -0000	1.1
  +++ DefaultBlock.java	17 Mar 2003 04:05:56 -0000	1.2
  @@ -25,7 +25,6 @@
   import org.apache.avalon.assembly.locator.Contextualizable;
   import org.apache.avalon.assembly.lifestyle.LifestyleException;
   import org.apache.avalon.assembly.lifestyle.LifestyleService;
  -import org.apache.avalon.assembly.lifecycle.AssemblyService;
   import org.apache.avalon.assembly.util.ExceptionHelper;
   import org.apache.avalon.framework.logger.Logger;
   import org.apache.avalon.framework.logger.AbstractLogEnabled;
  @@ -201,13 +200,18 @@
       public void contextualize( Locator context ) throws ContextException
       {
           super.contextualize( context );
  -        m_applianceContext = (ApplianceContext) context.get( "urn:assembly:appliance.context"
);
  -
  -        m_engine = (EngineClassLoader) context.get( "urn:assembly:engine" );
  -        m_descriptor = (ContainerDescriptor) context.get( "urn:merlin:container.descriptor"
);
  -        m_library = (Library) context.get( "urn:merlin:container.library" );
  -        m_blocks = (List) context.get( "urn:merlin:container.containers" );
  -        m_repository = (ApplianceRepository) context.get( "urn:assembly:appliance.repository"
);
  +        m_applianceContext = 
  +          (ApplianceContext) context.get( "urn:assembly:appliance.context" );
  +        m_engine = 
  +          (EngineClassLoader) context.get( "urn:assembly:engine" );
  +        m_descriptor = 
  +          (ContainerDescriptor) context.get( "urn:merlin:container.descriptor" );
  +        m_library = 
  +          (Library) context.get( "urn:merlin:container.library" );
  +        m_blocks = 
  +          (List) context.get( "urn:merlin:container.containers" );
  +        m_repository = 
  +          (ApplianceRepository) context.get( "urn:assembly:appliance.repository" );
       }
   
       //=====================================================================
  @@ -260,7 +264,7 @@
       }
   
       //-------------------------------------------------------------------------------
  -    // Appliance
  +    // Block
       //-------------------------------------------------------------------------------
   
      /**
  @@ -300,6 +304,29 @@
               }
           }
           return (URL[]) list.toArray( new URL[0] );
  +    }
  +
  +    //-------------------------------------------------------------------------------
  +    // Appliance
  +    //-------------------------------------------------------------------------------
  +
  +    /**
  +     * Return the set of runtime dependencies for the type.  The block 
  +     * implementation overrides the default appliance behaviour by including 
  +     * dependencies declared at the level of the block.
  +     *
  +     * @return the set of runtime dependencies.
  +     */
  +    public DependencyDescriptor[] getDependencies()
  +    {
  +        DependencyDescriptor[] classic = super.getDependencies();
  +
  +        //
  +        // ## pending
  +        // ## add block level dependencies
  +        //
  +
  +        return classic;
       }
   
      /**
  
  
  

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


Mime
View raw message