avalon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dona...@apache.org
Subject cvs commit: jakarta-avalon-excalibur/containerkit/src/java/org/apache/excalibur/containerkit/verifier AssemblyVerifier.java
Date Fri, 14 Jun 2002 06:56:54 GMT
donaldp     2002/06/13 23:56:54

  Modified:    containerkit/src/java/org/apache/excalibur/containerkit/verifier
                        AssemblyVerifier.java
  Log:
  Block --> Component
  
  Revision  Changes    Path
  1.13      +32 -33    jakarta-avalon-excalibur/containerkit/src/java/org/apache/excalibur/containerkit/verifier/AssemblyVerifier.java
  
  Index: AssemblyVerifier.java
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/containerkit/src/java/org/apache/excalibur/containerkit/verifier/AssemblyVerifier.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- AssemblyVerifier.java	9 Jun 2002 01:20:18 -0000	1.12
  +++ AssemblyVerifier.java	14 Jun 2002 06:56:54 -0000	1.13
  @@ -128,17 +128,17 @@
       }
   
       /**
  -     * Verfiy that all Blocks have the needed dependencies specified correctly.
  +     * Verfiy that all Components have the needed dependencies specified correctly.
        *
  -     * @param blocks the ComponentMetaData objects for the blocks
  +     * @param components the ComponentMetaData objects for the components
        * @throws VerifyException if an error occurs
        */
  -    public void verifyValidDependencies( final ComponentMetaData[] blocks )
  +    public void verifyValidDependencies( final ComponentMetaData[] components )
           throws VerifyException
       {
  -        for( int i = 0; i < blocks.length; i++ )
  +        for( int i = 0; i < components.length; i++ )
           {
  -            verifyDependenciesMap( blocks[ i ] );
  +            verifyDependenciesMap( components[ i ] );
           }
       }
   
  @@ -295,7 +295,7 @@
               final ServiceDesignator service =
                   info.getDependency( roleName ).getService();
   
  -            //Get the other block that is providing service
  +            //Get the other component that is providing service
               final ComponentMetaData provider = getComponentMetaData( providerName, others
);
               if( null == provider )
               {
  @@ -307,7 +307,7 @@
                   throw new VerifyException( message );
               }
   
  -            //make sure that the block offers service
  +            //make sure that the component offers service
               //that user expects it to be providing
               final ServiceDescriptor[] services = provider.getComponentInfo().getServices();
               if( !hasMatchingService( service, services ) )
  @@ -323,11 +323,11 @@
       }
   
       /**
  -     * Get Block with specified name from specified Block array.
  +     * Get component with specified name from specified Component array.
        *
  -     * @param name the name of block to get
  -     * @param components the array of Blocks to search
  -     * @return the Block if found, else null
  +     * @param name the name of component to get
  +     * @param components the array of components to search
  +     * @return the Component if found, else null
        */
       protected ComponentMetaData getComponentMetaData( final String name,
                                                         final ComponentMetaData[] components
)
  @@ -361,17 +361,17 @@
       }
   
       /**
  -     * Verfiy that specified Block designate classes that implement the
  +     * Verfiy that specified components designate classes that implement the
        * advertised interfaces.
        *
  -     * @param block the ComponentMetaData object for the blocks
  +     * @param component the ComponentMetaData object for the components
        * @throws VerifyException if an error occurs
        */
  -    protected void verifyType( final ComponentMetaData block, final ClassLoader classLoader
)
  +    protected void verifyType( final ComponentMetaData component, final ClassLoader classLoader
)
           throws VerifyException
       {
  -        final String name = block.getName();
  -        final String classname = block.getClassname();
  +        final String name = component.getName();
  +        final String classname = component.getClassname();
           Class clazz = null;
           try
           {
  @@ -389,7 +389,7 @@
   
           final Class[] interfaces =
               getServiceClasses( name,
  -                               block.getComponentInfo().getServices(),
  +                               component.getComponentInfo().getServices(),
                                  classLoader );
   
           m_verifier.verifyComponent( name, clazz, interfaces );
  @@ -440,9 +440,8 @@
       }
   
       /**
  -     * Verify that the names of the specified blocks and listeners are unique.
  -     * It is not valid for the same name to be used in multiple Blocks and or
  -     * BlockListeners.
  +     * Verify that the names of the specified components and listeners are unique.
  +     * It is not valid for the same name to be used in multiple components.
        *
        * @param components the Components
        * @throws VerifyException if an error occurs
  @@ -487,18 +486,18 @@
        * and verify that there is a 1 to 1 map with dependencies specified
        * in ComponentInfo.
        *
  -     * @param block the ComponentMetaData describing the block
  +     * @param component the ComponentMetaData describing the component
        * @throws VerifyException if an error occurs
        */
  -    protected void verifyDependenciesMap( final ComponentMetaData block )
  +    protected void verifyDependenciesMap( final ComponentMetaData component )
           throws VerifyException
       {
           //Make sure all role entries specified in config file are valid
  -        final DependencyMetaData[] roles = block.getDependencies();
  +        final DependencyMetaData[] roles = component.getDependencies();
           for( int i = 0; i < roles.length; i++ )
           {
               final String roleName = roles[ i ].getRole();
  -            final DependencyDescriptor descriptor = block.getComponentInfo().getDependency(
roleName );
  +            final DependencyDescriptor descriptor = component.getComponentInfo().getDependency(
roleName );
   
               //If there is no dependency descriptor in ComponentInfo then
               //user has specified an uneeded dependency.
  @@ -508,16 +507,16 @@
                       REZ.getString( "assembly.unknown-dependency.error",
                                      roles[ i ].getName(),
                                      roleName,
  -                                   block.getName() );
  +                                   component.getName() );
                   throw new VerifyException( message );
               }
           }
   
           //Make sure all dependencies in ComponentInfo file are satisfied
  -        final DependencyDescriptor[] dependencies = block.getComponentInfo().getDependencies();
  +        final DependencyDescriptor[] dependencies = component.getComponentInfo().getDependencies();
           for( int i = 0; i < dependencies.length; i++ )
           {
  -            final DependencyMetaData role = block.getDependency( dependencies[ i ].getRole()
);
  +            final DependencyMetaData role = component.getDependency( dependencies[ i ].getRole()
);
   
               //If there is no Role then the user has failed
               //to specify a needed dependency.
  @@ -526,19 +525,19 @@
                   final String message =
                       REZ.getString( "assembly.unspecified-dependency.error",
                                      dependencies[ i ].getRole(),
  -                                   block.getName() );
  +                                   component.getName() );
                   throw new VerifyException( message );
               }
           }
       }
   
       /**
  -     * Retrieve an array of Classes for all the services (+ the Block interface)
  -     * that a Block offers. This method also makes sure all services offered are
  +     * Retrieve an array of Classes for all the services that a Component
  +     * offers. This method also makes sure all services offered are
        * interfaces.
        *
  -     * @param name the name of block
  -     * @param services the services the Block offers
  +     * @param name the name of component
  +     * @param services the services the component offers
        * @param classLoader the classLoader
        * @return an array of Classes for all the services
        * @throws VerifyException if an error occurs
  
  
  

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


Mime
View raw message