Examples of handleMessage()


Examples of net.yura.lobby.server.LobbyServer.handleMessage()

    private void handleMessage(ClientHandler ch, Message message) {
       
        LobbyServer server = ((Server)ch.getServer()).lobbyServer;
        LobbySession session = ((Session)ch.getClientData()).lobbySession;
       
        server.handleMessage(session,message);
    }

}
View Full Code Here

Examples of org.apache.cxf.binding.soap.interceptor.RPCInInterceptor.handleMessage()

        soapMessage.setContent(XMLStreamReader.class, XMLInputFactory.newInstance().createXMLStreamReader(
                getTestStream(getClass(), "/rpc-resp.xml")));
        soapMessage.put(Message.REQUESTOR_ROLE, Boolean.TRUE);

        interceptor.handleMessage(soapMessage);

        List<?> parameters = (List<?>) soapMessage.getContent(List.class);
        assertEquals(1, parameters.size());

        Object obj = parameters.get(0);
View Full Code Here

Examples of org.apache.cxf.binding.soap.interceptor.RPCOutInterceptor.handleMessage()

        soapMessage.setContent(XMLStreamWriter.class, XMLOutputFactory.newInstance().createXMLStreamWriter(
                baos));

        soapMessage.put(Message.REQUESTOR_ROLE, Boolean.TRUE);

        interceptor.handleMessage(soapMessage);
        assertNull(soapMessage.getContent(Exception.class));
        soapMessage.getContent(XMLStreamWriter.class).flush();
        baos.flush();
       
        ByteArrayInputStream bais = new ByteArrayInputStream(baos.toByteArray());
View Full Code Here

Examples of org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage()

    public void testBadHttpVerb() throws Exception {
        prepareSoapMessage("test-soap-header.xml");
        soapMessage.put(Message.HTTP_REQUEST_METHOD, "OPTIONS");
        ReadHeadersInterceptor r = new ReadHeadersInterceptor(BusFactory.getDefaultBus());
        try {
            r.handleMessage(soapMessage);
            fail("Did not throw exception");
        } catch (Fault f) {
            assertEquals(405, f.getStatusCode());
        }
    }
View Full Code Here

Examples of org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage()

        ByteArrayDataSource bads = new ByteArrayDataSource(in, "test/xml");
        soapMessage.setContent(InputStream.class, bads.getInputStream());

        ReadHeadersInterceptor r = new ReadHeadersInterceptor(BusFactory.getDefaultBus());
        try {
            r.handleMessage(soapMessage);
            fail("Did not throw exception");
        } catch (SoapFault f) {
            assertEquals(Soap11.getInstance().getVersionMismatch(), f.getFaultCode());
        }
    }
View Full Code Here

Examples of org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage()

        InputStream is = RMSoapInInterceptorTest.class.getResourceAsStream(resource);
        assertNotNull(is);
        XMLStreamReader reader = XMLInputFactory.newInstance().createXMLStreamReader(is);
        soapMessage.setContent(XMLStreamReader.class, reader);
        ReadHeadersInterceptor rji = new ReadHeadersInterceptor(BusFactory.getDefaultBus());
        rji.handleMessage(soapMessage);
        StartBodyInterceptor sbi = new StartBodyInterceptor();
        sbi.handleMessage(soapMessage);
        return soapMessage;
    }
}
View Full Code Here

Examples of org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage()

        InputStream is = RMSoapInterceptorTest.class.getResourceAsStream(resource);
        assertNotNull(is);
        XMLStreamReader reader = XMLInputFactory.newInstance().createXMLStreamReader(is);
        soapMessage.setContent(XMLStreamReader.class, reader);
        ReadHeadersInterceptor rji = new ReadHeadersInterceptor(BusFactory.getDefaultBus());
        rji.handleMessage(soapMessage);
        StartBodyInterceptor sbi = new StartBodyInterceptor();
        sbi.handleMessage(soapMessage);
        return soapMessage;
    }
}
View Full Code Here

Examples of org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage()

        InputStream is = RMSoapInterceptorTest.class.getResourceAsStream(resource);
        assertNotNull(is);
        XMLStreamReader reader = XMLInputFactory.newInstance().createXMLStreamReader(is);
        soapMessage.setContent(XMLStreamReader.class, reader);
        ReadHeadersInterceptor rji = new ReadHeadersInterceptor(BusFactory.getDefaultBus());
        rji.handleMessage(soapMessage);
        StartBodyInterceptor sbi = new StartBodyInterceptor();
        sbi.handleMessage(soapMessage);
        return soapMessage;
    }
}
View Full Code Here

Examples of org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage()

        InputStream is = RMSoapInterceptorTest.class.getResourceAsStream(resource);
        assertNotNull(is);
        XMLStreamReader reader = XMLInputFactory.newInstance().createXMLStreamReader(is);
        soapMessage.setContent(XMLStreamReader.class, reader);
        ReadHeadersInterceptor rji = new ReadHeadersInterceptor(BusFactory.getDefaultBus());
        rji.handleMessage(soapMessage);
        return soapMessage;
    }
}
View Full Code Here

Examples of org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage()

        ByteArrayDataSource bads = new ByteArrayDataSource(in, "test/xml");
        soapMessage.setContent(InputStream.class, bads.getInputStream());

        ReadHeadersInterceptor r = new ReadHeadersInterceptor(BusFactory.getDefaultBus());
        try {
            r.handleMessage(soapMessage);
            fail("Did not throw exception");
        } catch (SoapFault f) {
            assertEquals(Soap11.getInstance().getVersionMismatch(), f.getFaultCode());
        }
    }
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.