Package javax.xml.ws

Examples of javax.xml.ws.ProtocolException


        TestSOAPHandler soapHandler1 = new TestSOAPHandler<SOAPMessageContext>(false) {
            public boolean handleMessage(SOAPMessageContext ctx) {
                super.handleMessage(ctx);
                Boolean outbound = (Boolean)ctx.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
                if (!outbound) {
                    throw new ProtocolException(clientHandlerMessage);
                }  
                return true;
            }
        };
        TestSOAPHandler soapHandler2 = new TestSOAPHandler(false);
View Full Code Here


        super(Phase.PREPARE_SEND);
    }

    public void handleMessage(Message message) throws Fault {
        String str = new String("Collocated Invocation should have been detected.");
        throw new ProtocolException(str);       
    }
View Full Code Here

        TestHandler<LogicalMessageContext> handler2 = new TestHandler<LogicalMessageContext>(false) {
            public boolean handleMessage(LogicalMessageContext ctx) {
                super.handleMessage(ctx);
                Boolean outbound = (Boolean)ctx.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
                if (outbound) {
                    throw new ProtocolException(clientHandlerMessage);
                }  
                return true;
            }
        };
        TestSOAPHandler soapHandler1 = new TestSOAPHandler(false);
View Full Code Here

        TestHandler<LogicalMessageContext> handler2 = new TestHandler<LogicalMessageContext>(false) {
            public boolean handleMessage(LogicalMessageContext ctx) {
                super.handleMessage(ctx);
                Boolean outbound = (Boolean)ctx.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
                if (!outbound) {
                    throw new ProtocolException(clientHandlerMessage);
                }  
                return true;
            }
        };
        TestSOAPHandler soapHandler1 = new TestSOAPHandler(false);
View Full Code Here

        TestSOAPHandler soapHandler1 = new TestSOAPHandler<SOAPMessageContext>(false) {
            public boolean handleMessage(SOAPMessageContext ctx) {
                super.handleMessage(ctx);
                Boolean outbound = (Boolean)ctx.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
                if (outbound) {
                    throw new ProtocolException(clientHandlerMessage);
                }  
                return true;
            }
        };
        TestSOAPHandler soapHandler2 = new TestSOAPHandler(false);
View Full Code Here

        TestSOAPHandler soapHandler1 = new TestSOAPHandler<SOAPMessageContext>(false) {
            public boolean handleMessage(SOAPMessageContext ctx) {
                super.handleMessage(ctx);
                Boolean outbound = (Boolean)ctx.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
                if (!outbound) {
                    throw new ProtocolException(clientHandlerMessage);
                }  
                return true;
            }
        };
        TestSOAPHandler soapHandler2 = new TestSOAPHandler(false);
View Full Code Here

    public void testHandleMessageThrowsProtocolExceptionOutbound() {
        message = new SoapMessage(message);
        lmc = new LogicalMessageContextImpl(message);
        pmc = new WrappedMessageContext(message);     

        ProtocolException pe = new ProtocolException("banzai");
        protocolHandlers[2].setException(pe);
       
        invoker.setRequestor(true);
        assertTrue(invoker.isOutbound());
       
View Full Code Here

                   < protocolHandlers[1].getInvokeOrderOfHandleFault());
    }
   
    @Test
    public void testHandleFaultReturnsFalseOutbound() {
        ProtocolException pe = new ProtocolException("banzai");
        protocolHandlers[2].setException(pe);
        protocolHandlers[0].setHandleFaultRet(false);
       
        invoker.setRequestor(true);
        assertTrue(invoker.isOutbound());
View Full Code Here

    //section 9.1.2.2) if there are no further handlers.
    @Test
    public void testHandleMessageThrowsProtocolExceptionWithResponseExpected() {
        assertFalse(invoker.faultRaised());

        ProtocolException pe = new ProtocolException("banzai");
        logicalHandlers[2].setException(pe);
       
        invoker.setRequestor(true);

        //boolean continueProcessing = true;
View Full Code Here

    //in the chain, the exception is dispatched
    @Test
    public void testHandleMessageThrowsProtocolExceptionWithNoResponseExpected() {
        assertFalse(invoker.faultRaised());

        ProtocolException pe = new ProtocolException("banzai");
        logicalHandlers[2].setException(pe);
        invoker.setResponseExpected(false);
        invoker.setRequestor(true);

        //boolean continueProcessing = true;
View Full Code Here

TOP

Related Classes of javax.xml.ws.ProtocolException

Copyright © 2018 www.massapicom. 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.