Package org.apache.hivemind

Examples of org.apache.hivemind.ErrorHandler.error()


        mc.setThrowable(new ApplicationRuntimeException("Simulated failure."));

        module.getErrorHandler();
        mc.setReturnValue(eh);

        eh.error(
                log,
                "Unable to autowire property stringHolder of service foo.bar: Simulated failure.",
                null,
                new ApplicationRuntimeException(""));
        ehc.setMatcher(new AggregateArgumentsMatcher(new ArgumentMatcher[]
View Full Code Here


        {
            // Have to decide if we need to display the location of the rule
            // or the element.

            ErrorHandler errorHandler = processor.getContributingModule().getErrorHandler();
            errorHandler.error(LOG, RulesMessages.unableToSetElementProperty(
                    propertyName,
                    target,
                    processor,
                    element,
                    ex), element.getLocation(), ex);
View Full Code Here

        mc.setThrowable(new ApplicationRuntimeException("Simulated failure."));

        module.getErrorHandler();
        mc.setReturnValue(eh);

        eh.error(
                log,
                "Unable to autowire property stringHolder of service foo.bar: Simulated failure.",
                null,
                new ApplicationRuntimeException(""));
        ehc.setMatcher(new AggregateArgumentsMatcher(new ArgumentMatcher[]
View Full Code Here

        schemaControl.setReturnValue("Baz", 2);

        schema.visibleToModule("zip.zoop");
        schemaControl.setReturnValue(false);

        eh.error(log, ImplMessages.schemaNotVisible("foo.bar.Baz", "zip.zoop"), l, null);

        replayControls();

        ModuleDescriptor fooBar = new ModuleDescriptor(null, eh);
        fooBar.setModuleId("foo.bar");
View Full Code Here

        Log log = LogFactory.getLog(TestRegistryInfrastructureConstructor.class);

        Location l = fabricateLocation(13);

        eh.error(log, ImplMessages.unableToResolveSchema("foo.bar.Baz"), l, null);

        replayControls();

        ModuleDescriptor zipZoop = new ModuleDescriptor(null, eh);
        zipZoop.setModuleId("zip.zoop");
View Full Code Here

        Log log = LogFactory.getLog(TestRegistryInfrastructureConstructor.class);

        Location location = fabricateLocation(1);

        eh.error(
                log,
                "Unexpected token <AND> in expression 'and class foo'.",
                location,
                new RuntimeException());
        ehControl.setMatcher(new AggregateArgumentsMatcher(new ArgumentMatcher[]
View Full Code Here

        {
            // Have to decide if we need to display the location of the rule
            // or the element.

            ErrorHandler errorHandler = processor.getContributingModule().getErrorHandler();
            errorHandler.error(
                LOG,
                RulesMessages.unableToSetElementProperty(
                    propertyName,
                    target,
                    processor,
View Full Code Here

        MockControl errorHandlerControl = newControl(ErrorHandler.class);
        ErrorHandler errorHandler = (ErrorHandler) errorHandlerControl.getMock();

        log.info("Executing task Failure.");

        errorHandler.error(
            log,
            "Exception while executing task Failure: Failure!",
            null,
            new ApplicationRuntimeException(""));
        errorHandlerControl.setMatcher(new ExceptionAwareArgumentsMatcher());
View Full Code Here

        mc.setThrowable(new ApplicationRuntimeException("Simulated failure."));

        module.getErrorHandler();
        mc.setReturnValue(eh);

        eh.error(
            log,
            "Unable to autowire property stringHolder of service foo.bar: Simulated failure.",
            null,
            new ApplicationRuntimeException(""));
        ehc.setMatcher(new ExceptionAwareArgumentsMatcher());
View Full Code Here

        RegistryInfrastructure r = createRegistryForContribution(tc);

        ErrorHandler eh = (ErrorHandler) newMock(ErrorHandler.class);

        eh
                .error(
                        TranslatorManager.LOG,
                        "Translator contribution 'invalid' must specify either the service-id or class attribute.",
                        null,
                        null);
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.