Package org.objectweb.celtix.ws.addressing

Examples of org.objectweb.celtix.ws.addressing.EndpointReferenceType


     * @return EndpointReferenceType - the endpoint reference
     */
    public static EndpointReferenceType getEndpointReference(URL wsdlUrl,
                                                             QName serviceName,
                                                             String portName) {
        EndpointReferenceType reference = new EndpointReferenceType();
        reference.setMetadata(new MetadataType());
        setServiceAndPortName(reference, serviceName, portName);
        //TODO To Ensure it is a valid URI syntax.
        setWSDLLocation(reference, wsdlUrl.toString());

        return reference;
View Full Code Here


     * @param address - address URI
     * @return EndpointReferenceType - the endpoint reference
     */
    public static EndpointReferenceType getEndpointReference(String address) {

        EndpointReferenceType reference = new EndpointReferenceType();
        setAddress(reference, address);
        return reference;
    }
View Full Code Here

            if (null == wsp) {
                return null;
            }
        }

        EndpointReferenceType reference = new EndpointReferenceType();
        reference.setMetadata(new MetadataType());
        String serviceName = (null != ws) ? ws.serviceName() : wsp.serviceName();
        String targetNamespace = (null != ws) ? ws.targetNamespace() : wsp.targetNamespace();
        String portName = (null != ws) ? ws.portName() : wsp.portName();
        String url = (null != ws) ? ws.wsdlLocation() : wsp.wsdlLocation();
        String className = (null != ws) ? ws.endpointInterface() : null;
View Full Code Here

        BindingFactory factory =
            bus.getBindingManager().getBindingFactory(
                "http://celtix.objectweb.org/bindings/xmlformat");
        assertNotNull(factory);
       
        EndpointReferenceType address = testUtils.getEndpointReference();
       
        ClientBinding clientBinding = factory.createClientBinding(address);
        assertNotNull(clientBinding);
        assertTrue(XMLClientBinding.class.isInstance(clientBinding));
       
View Full Code Here

    }
   
    private TestJMSClientTransport createClientTransport(URL wsdlUrl,
                                                  QName serviceName, String portName,
                                                  String address) throws WSDLException, IOException {       
        EndpointReferenceType ref = EndpointReferenceUtils
            .getEndpointReference(wsdlUrl, serviceName, portName);
        return new TestJMSClientTransport(bus, ref, null);
    }
View Full Code Here

   
    private ServerTransport createServerTransport(URL wsdlUrl, QName serviceName,
                                                  String portName, String address) throws WSDLException,
        IOException {

        EndpointReferenceType ref = EndpointReferenceUtils.getEndpointReference(wsdlUrl, serviceName,
                                                                                portName);       
        EndpointReferenceUtils.setAddress(ref, address);
        return new JMSServerTransport(bus, ref);
    }
View Full Code Here

   
    private void createConfiguration(URL wsdlUrl, QName serviceName,
                          String portName) throws WSDLException,
                          IOException, BusException {  
        assert bus != null;
        EndpointReferenceType ref = EndpointReferenceUtils.getEndpointReference(wsdlUrl, serviceName,
                                                                                portName);
        Configuration busCfg = bus.getConfiguration();
        assert null != busCfg;

        String id = EndpointReferenceUtils.getServiceName(ref).toString();
View Full Code Here

                                boolean decoupled,
                                boolean zeroLengthAction) throws Exception {
        context.get(REQUESTOR_ROLE_PROPERTY);
        EasyMock.expectLastCall().andReturn(Boolean.FALSE);
        AddressingPropertiesImpl maps = new AddressingPropertiesImpl();
        EndpointReferenceType replyTo = new EndpointReferenceType();
        replyTo.setAddress(
            ContextUtils.getAttributedURI(decoupled
                                          ? "http://localhost:9999/decoupled"
                                          : Names.WSA_ANONYMOUS_ADDRESS));
        maps.setReplyTo(replyTo);
        AttributedURIType id =
View Full Code Here

            url = new URL(key);
        } catch (MalformedURLException e) {
            throw new ContextInitException(e);
        }

        EndpointReferenceType reference = EndpointReferenceUtils.getEndpointReference(url,
                wsBinding.getWSDLService().getQName(),
                wsBinding.getWSDLPort().getName());
       
        AttributedURIType address = new AttributedURIType();

        String bindingId = null;
        Binding binding = wsBinding.getWSDLPort().getBinding();
        if (null != binding) {
            List list = binding.getExtensibilityElements();
            if (!list.isEmpty()) {
                bindingId = ((ExtensibilityElement)list.get(0)).getElementType().getNamespaceURI();
            }
        }
        List<?> list = wsBinding.getWSDLPort().getExtensibilityElements();
        for (Object ep : list) {
            ExtensibilityElement ext = (ExtensibilityElement)ep;
            if (ext instanceof SOAPAddress) {
                if (bindingId == null) {
                    bindingId = ((SOAPAddress)ext).getLocationURI();
                }
                address.setValue(((SOAPAddress)ext).getLocationURI());
            }
            if (ext instanceof AddressType) {
                if (bindingId == null) {
                    bindingId = ((AddressType)ext).getLocation();
                }
                address.setValue(((AddressType)ext).getLocation());
            }
        }
        if (reference.getAddress() == null) {
            //REVIST - bug in Celtix that the HTTP transport won't find the address correctly
            reference.setAddress(address);
        }
       
        try {
            serverBinding = bus.getBindingManager().getBindingFactory(bindingId).createServerBinding(
                    reference, this);
View Full Code Here

        try {
            String key = wsdlDef.getDocumentBaseURI();
            URL url = new URL(key);

            EndpointReferenceType reference = EndpointReferenceUtils.getEndpointReference(url,
                    wsBinding.getWSDLService().getQName(),
                    wsBinding.getWSDLPort().getName());

            String bindingId = null;
            Binding binding = wsBinding.getWSDLPort().getBinding();
View Full Code Here

TOP

Related Classes of org.objectweb.celtix.ws.addressing.EndpointReferenceType

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.