Examples of VerifyException


Examples of org.apache.excalibur.containerkit.verifier.VerifyException

            final String message =
                REZ.getString( "bad-listener-class",
                               listener.getName(),
                               listener.getClassname(),
                               e.getMessage() );
            throw new VerifyException( message, e );
        }

        if( !BlockListener.class.isAssignableFrom( clazz ) )
        {
            final String message = REZ.getString( "listener-noimpl-listener",
                                                  listener.getName(),
                                                  listener.getClassname() );
            throw new VerifyException( message );
        }
    }
View Full Code Here

Examples of org.apache.excalibur.containerkit.verifier.VerifyException

        throws VerifyException
    {
        if( !isValidName( name ) )
        {
            final String message = REZ.getString( "invalid-sar-name", name );
            throw new VerifyException( message );
        }
    }
View Full Code Here

Examples of org.apache.excalibur.containerkit.verifier.VerifyException

        {
            final String name = blocks[ i ].getName();
            if( !isValidName( name ) )
            {
                final String message = REZ.getString( "invalid-block-name", name );
                throw new VerifyException( message );
            }
        }
    }
View Full Code Here

Examples of org.apache.excalibur.containerkit.verifier.VerifyException

        {
            final String name = listeners[ i ].getName();
            if( !isValidName( name ) )
            {
                final String message = REZ.getString( "invalid-listener-name", name );
                throw new VerifyException( message );
            }
        }
    }
View Full Code Here

Examples of org.apache.excalibur.containerkit.verifier.VerifyException

        {
            final String other = blocks[ i ].getName();
            if( blockIndex != i && name.equals( other ) )
            {
                final String message = REZ.getString( "duplicate-name", name );
                throw new VerifyException( message );
            }
        }

        //Verify no listeners have the same name
        for( int i = 0; i < listeners.length; i++ )
        {
            final String other = listeners[ i ].getName();
            if( listenerIndex != i && name.equals( other ) )
            {
                final String message = REZ.getString( "duplicate-name", name );
                throw new VerifyException( message );
            }
        }
    }
View Full Code Here

Examples of org.apache.excalibur.containerkit.verifier.VerifyException

            {
                final String message = REZ.getString( "unknown-dependency",
                                                      roles[ i ].getName(),
                                                      roleName,
                                                      block.getName() );
                throw new VerifyException( message );
            }
        }

        //Make sure all dependencies in BlockInfo file are satisfied
        final DependencyDescriptor[] dependencies = block.getBlockInfo().getDependencies();
        for( int i = 0; i < dependencies.length; i++ )
        {
            final DependencyMetaData role = block.getDependency( dependencies[ i ].getRole() );

            //If there is no Role then the user has failed
            //to specify a needed dependency.
            if( null == role )
            {
                final String message = REZ.getString( "unspecified-dependency",
                                                      dependencies[ i ].getRole(),
                                                      block.getName() );
                throw new VerifyException( message );
            }
        }
    }
View Full Code Here

Examples of org.apache.excalibur.containerkit.verifier.VerifyException

            }
            catch( final Throwable t )
            {
                final String message =
                    REZ.getString( "bad-service-class", name, classname, t.getMessage() );
                throw new VerifyException( message, t );
            }

            if( !classes[ i ].isInterface() )
            {
                final String message =
                    REZ.getString( "service-not-interface", name, classname );
                throw new VerifyException( message );
            }

            checkNotFrameworkInterface( name, classname, classes[ i ] );
        }
View Full Code Here

Examples of org.apache.excalibur.containerkit.verifier.VerifyException

            if( stack.contains( dependency ) )
            {
                final String trace = getDependencyTrace( dependency, stack );
                final String message =
                    REZ.getString( "dependency-circular", block.getName(), trace );
                throw new VerifyException( message );
            }

            stack.push( dependency );
            verifyNoCircularDependencies( dependency, blocks, stack );
            stack.pop();
View Full Code Here

Examples of org.apache.excalibur.containerkit.verifier.VerifyException

            final BlockMetaData other = getBlock( blockName, others );
            if( null == other )
            {
                final String message =
                    REZ.getString( "dependency-noblock", blockName, block.getName() );
                throw new VerifyException( message );
            }

            //make sure that the block offers service
            //that user expects it to be providing
            final ServiceDescriptor[] services = other.getBlockInfo().getServices();
            if( !hasMatchingService( service, services ) )
            {
                final String message =
                    REZ.getString( "dependency-noservice", blockName, service, block.getName() );
                throw new VerifyException( message );
            }
        }
    }
View Full Code Here

Examples of org.apache.excalibur.containerkit.verifier.VerifyException

        {
            final String message = REZ.getString( "bad-block-class",
                                                  name,
                                                  classname,
                                                  e.getMessage() );
            throw new VerifyException( message );
        }

        final Class[] interfaces =
            getServiceClasses( name,
                               block.getBlockInfo().getServices(),
                               classLoader );

        verifyAvalonComponent( name, clazz, interfaces );

        for( int i = 0; i < interfaces.length; i++ )
        {
            if( !interfaces[ i ].isAssignableFrom( clazz ) )
            {
                final String message = REZ.getString( "block-noimpl-service",
                                                      name,
                                                      classname,
                                                      interfaces[ i ].getName() );
                throw new VerifyException( message );
            }
        }

        if( Block.class.isAssignableFrom( clazz ) )
        {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.