Examples of DefaultErrorHandler


Examples of net.sourceforge.urlrewriter4j.core.errors.DefaultErrorHandler

      if (oClassNode != null) {
        //Class oClass = Class.forName(oClassNode.getNodeValue());
        //oHandler = (IRewriteErrorHandler) oClass.newInstance();
        oHandler = pConfig.getBeanFactory().newInstance(IRewriteErrorHandler.class, oClassNode.getNodeValue());
      } else {
        oHandler = new DefaultErrorHandler(oUrlNode.getNodeValue());
      }
    } catch (Exception e) {
      throw new ConfigurationException(String.format(Messages.INVALID_TYPE, new Object[] {oClassNode.getNodeValue(), IRewriteErrorHandler.class.getName()}));     
    }
    pConfig.getErrorHandlers().put(Integer.parseInt(oCodeNode.getNodeValue()), oHandler);
View Full Code Here

Examples of org.apache.camel.processor.DefaultErrorHandler

    public DefaultErrorHandlerBuilder() {
    }

    public Processor createErrorHandler(RouteContext routeContext, Processor processor) throws Exception {
        DefaultErrorHandler answer = new DefaultErrorHandler(routeContext.getCamelContext(), processor, getLogger(), getOnRedelivery(),
            getRedeliveryPolicy(), getExceptionPolicyStrategy(), getRetryWhilePolicy(routeContext.getCamelContext()), getExecutorService(routeContext.getCamelContext()));
        // configure error handler before we can use it
        configure(routeContext, answer);
        return answer;
    }
View Full Code Here

Examples of org.apache.camel.processor.DefaultErrorHandler

    public DefaultErrorHandlerBuilder() {
    }

    public Processor createErrorHandler(RouteContext routeContext, Processor processor) throws Exception {
        DefaultErrorHandler answer = new DefaultErrorHandler(routeContext.getCamelContext(), processor, getLogger(), getOnRedelivery(),
            getRedeliveryPolicy(), getExceptionPolicyStrategy(), getRetryWhilePolicy(routeContext.getCamelContext()), getExecutorService(routeContext.getCamelContext()));
        // configure error handler before we can use it
        configure(routeContext, answer);
        return answer;
    }
View Full Code Here

Examples of org.apache.camel.processor.DefaultErrorHandler

    public DefaultErrorHandlerBuilder() {
    }

    public Processor createErrorHandler(RouteContext routeContext, Processor processor) throws Exception {
        DefaultErrorHandler answer = new DefaultErrorHandler(routeContext.getCamelContext(), processor, getLogger(), getOnRedelivery(),
            getRedeliveryPolicy(), getExceptionPolicyStrategy(), getRetryWhilePolicy(routeContext.getCamelContext()), getExecutorService(routeContext.getCamelContext()));
        // configure error handler before we can use it
        configure(routeContext, answer);
        return answer;
    }
View Full Code Here

Examples of org.apache.camel.processor.DefaultErrorHandler

    public DefaultErrorHandlerBuilder() {
    }

    public Processor createErrorHandler(RouteContext routeContext, Processor processor) throws Exception {
        DefaultErrorHandler answer = new DefaultErrorHandler(routeContext.getCamelContext(), processor, getLogger(),
                getOnRedelivery(), getRedeliveryPolicy(), getHandledPolicy(), getExceptionPolicyStrategy());
        // configure error handler before we can use it
        configure(answer);
        return answer;
    }
View Full Code Here

Examples of org.apache.hivemind.impl.DefaultErrorHandler

    }

    public void testPrivateSchema() throws Exception
    {
        Resource location = getResource("PrivateSchema.xml");
        DefaultErrorHandler eh = new DefaultErrorHandler();

        XmlResourceProcessor p = new XmlResourceProcessor(_resolver, eh);

        ModuleDescriptor md = p.processResource(location);
View Full Code Here

Examples of org.apache.hivemind.impl.DefaultErrorHandler

    public void testLinePreciseErrorReporting() throws Exception
    {
        Resource resource = getResource("missingModuleId.groovy");

        ErrorHandler handler = new DefaultErrorHandler();
        DescriptorParser parser = new DescriptorParser(handler);

        parser.initialize(resource, getClassResolver());

        GroovyCodeSource source = new GroovyCodeSource(resource.getResourceURL());
View Full Code Here

Examples of org.apache.hivemind.impl.DefaultErrorHandler

    }
 
    public void testModuleClassNotFinal()
    {
        AnnotatedModuleProcessor processor = new AnnotatedModuleProcessor(new RegistryDefinitionImpl(),
                new DefaultClassResolver(), new DefaultErrorHandler());
        try
        {
            processor.processModule(FinalModule.class);
            fail("Final class must not be allowed as module class");
        }
View Full Code Here

Examples of org.apache.hivemind.impl.DefaultErrorHandler

    }
   
    public void testModuleClassNotAbstract()
    {
        AnnotatedModuleProcessor processor = new AnnotatedModuleProcessor(new RegistryDefinitionImpl(),
                new DefaultClassResolver(), new DefaultErrorHandler());
        try
        {
            processor.processModule(AbstractModule.class);
            fail("Abstract class must not be allowed as module class");
        }
View Full Code Here

Examples of org.apache.hivemind.impl.DefaultErrorHandler

    }
   
    public void testModuleClassPublic()
    {
        AnnotatedModuleProcessor processor = new AnnotatedModuleProcessor(new RegistryDefinitionImpl(),
                new DefaultClassResolver(), new DefaultErrorHandler());
        try
        {
            processor.processModule(NotPublicModule.class);
            fail("Protected class must not be allowed as module class");
        }
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.