Package javax.xml.ws

Examples of javax.xml.ws.EndpointReference


        org.apache.hello_world_soap_http.SOAPService s = new org.apache.hello_world_soap_http.SOAPService();

        Greeter greeter = s.getPort(Greeter.class);
        BindingProvider bindingProvider = (BindingProvider)greeter;

        EndpointReference er = bindingProvider.getEndpointReference();
        assertNotNull(er);

        //If the BindingProvider instance has a binding that is either SOAP 1.1/HTTP or SOAP
        //1.2/HTTP, then a W3CEndpointReference MUST be returned.
        assertTrue(er instanceof W3CEndpointReference);
View Full Code Here


            .create(new QName("http://apache.org/hello_world_soap_http", "SoapPort"));

        InputStream is = getClass().getResourceAsStream("resources/hello_world_soap_http_infoset.xml");
        Document doc = StaxUtils.read(is);
        DOMSource erXML = new DOMSource(doc);
        EndpointReference endpointReference = EndpointReference.readFrom(erXML);

        WebServiceFeature[] wfs = new WebServiceFeature[] {};

        Greeter greeter = s.getPort(endpointReference, Greeter.class, wfs);
View Full Code Here

        endpoint.publish("http://localhost:8080/test");
       
        InputStream is = getClass().getResourceAsStream("resources/hello_world_soap_http_infoset.xml");
        Document doc = StaxUtils.read(is);
        DOMSource erXML = new DOMSource(doc);
        EndpointReference endpointReference = EndpointReference.readFrom(erXML);

        WebServiceFeature[] wfs = new WebServiceFeature[] {};

        Greeter greeter = endpointReference.getPort(Greeter.class, wfs);

        String response = greeter.greetMe("John");
        assertEquals("Hello John", response);
    }   
View Full Code Here

        InputStream is = getClass().getResourceAsStream("resources/hello_world_soap_http_infoset.xml");
        Document doc = StaxUtils.read(is);
        Element referenceParameters = fetchElementByNameAttribute(doc.getDocumentElement(),
                                                                  "wsa:ReferenceParameters",
                                                                  "");
        EndpointReference endpointReference = endpoint.getEndpointReference(referenceParameters);
        assertNotNull(endpointReference);
        assertTrue(endpointReference instanceof W3CEndpointReference);

        //A returned W3CEndpointReferenceMUST also contain the specified referenceParameters.
        //W3CEndpointReference wer = (W3CEndpointReference)endpointReference;
View Full Code Here

        InputStream is = getClass().getResourceAsStream("resources/hello_world_soap_http_infoset.xml");
        Document doc = StaxUtils.read(is);
        Element referenceParameters = fetchElementByNameAttribute(doc.getDocumentElement(),
                                                                  "wsa:ReferenceParameters",
                                                                  "");
        EndpointReference endpointReference = endpoint.getEndpointReference(W3CEndpointReference.class,
                                                                            referenceParameters);
        assertNotNull(endpointReference);

        assertTrue(endpointReference instanceof W3CEndpointReference);
View Full Code Here

        ProviderImpl provider = new ProviderImpl();

        InputStream is = getClass().getResourceAsStream("resources/hello_world_soap_http_infoset.xml");
        Document doc = StaxUtils.read(is);
        DOMSource erXML = new DOMSource(doc);
        EndpointReference endpointReference = provider.readEndpointReference(erXML);
        assertNotNull(endpointReference);

        assertTrue(endpointReference instanceof W3CEndpointReference);       
    }
View Full Code Here

        ProviderImpl provider = new ProviderImpl();
       
        InputStream is = getClass().getResourceAsStream("resources/hello_world_soap_http_infoset.xml");
        Document doc = StaxUtils.read(is);
        DOMSource erXML = new DOMSource(doc);
        EndpointReference endpointReference = EndpointReference.readFrom(erXML);       

        WebServiceFeature[] wfs = new WebServiceFeature[] {};
       
        Greeter greeter = provider.getPort(endpointReference, Greeter.class, wfs);       
View Full Code Here

            if (soapMessageContext == null) {
                log.debug("The MessageContext is not available");
            }
        }
       
        EndpointReference jaxwsEPR = null;
        String addressingNamespace = EndpointReferenceUtils.getAddressingNamespace(clazz);
       
        if (soapMessageContext != null) {
            QName service = (QName) soapMessageContext.get(MessageContext.WSDL_SERVICE);
            QName endpoint = (QName) soapMessageContext.get(MessageContext.WSDL_PORT);
View Full Code Here

    /*
     *  (non-Javadoc)
     * @see javax.xml.ws.BindingProvider#getEndpointReference(java.lang.Class)
     */
    public <T extends EndpointReference> T getEndpointReference(Class<T> clazz) {
        EndpointReference jaxwsEPR = null;
        String addressingNamespace = EndpointReferenceUtils.getAddressingNamespace(clazz);
       
        try {
            org.apache.axis2.addressing.EndpointReference epr = binding.getAxis2EndpointReference();
           
View Full Code Here

       
        if (!BindingUtils.isSOAPBinding(binding.getBindingID())) {
            throw new UnsupportedOperationException("This method is unsupported for the binding: " + binding.getBindingID());
        }
       
        EndpointReference jaxwsEPR = null;
        String addressingNamespace = EndpointReferenceUtils.getAddressingNamespace(clazz);
        String address = endpointDesc.getEndpointAddress();
        QName serviceName = endpointDesc.getServiceQName();
        QName portName = endpointDesc.getPortQName();
View Full Code Here

TOP

Related Classes of javax.xml.ws.EndpointReference

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.