Package org.apache.woden.wsdl20

Examples of org.apache.woden.wsdl20.BindingFault


                    .addEndpoint(endpoint.getName().toString(),
                                 processEndpoint(endpoint, serviceInterface));
        } else if (this.isCodegen && !this.isAllPorts) {
            Endpoint soap11Endpoint = null;
            for (int i = 0; i < endpoints.length; ++i) {
                Binding binding = endpoints[i].getBinding();
                if (WSDL2Constants.URI_WSDL2_SOAP.equals(binding.getType().toString())) {
                    SOAPBindingExtensions soapBindingExtensions;
                    try {
                        soapBindingExtensions = (SOAPBindingExtensionsImpl) binding
                                .getComponentExtensionContext(
                                        new URI(WSDL2Constants.URI_WSDL2_SOAP));
                    } catch (URISyntaxException e) {
                        throw new AxisFault("Soap Binding Extention not found");
                    }
View Full Code Here


    private AxisEndpoint processEndpoint(Endpoint endpoint, Interface serviceInterface) throws AxisFault {
        AxisEndpoint axisEndpoint = new AxisEndpoint();
        axisEndpoint.setName(endpoint.getName().toString());
        setEndpointURL(axisEndpoint, endpoint.getAddress().toString());
        Binding binding = endpoint.getBinding();
        AxisBinding axisBinding;
        if (processedBindings.containsKey(binding.getName())) {
            axisBinding = (AxisBinding) processedBindings.get(binding.getName());
        } else {
            axisBinding = processBinding(binding, serviceInterface);
        }
        axisEndpoint.setBinding(axisBinding);
       
        String bindingType = binding.getType().toString();
        if (bindingType.equals(WSDL2Constants.URI_WSDL2_SOAP)) {
            processSOAPBindingEndpointExtensions(endpoint, axisEndpoint);
        } else if (bindingType.equals(WSDL2Constants.URI_WSDL2_HTTP)) {
            processHTTPBindingEndpointExtensions(endpoint, axisEndpoint);
        }
View Full Code Here

     * @see org.apache.woden.wsdl20.WSDLComponent#getFragmentIdentifier()
     */
    public FragmentIdentifier getFragmentIdentifier() {
        //Find parent components.
        BindingOperation bindingOperationComp = (BindingOperation)getParent();
        Binding bindingComp = (Binding)bindingOperationComp.getParent();
        InterfaceOperation interfaceOperationComp = bindingOperationComp.getInterfaceOperation();
       
        //Get needed properties.
        NCName binding = new NCName(bindingComp.getName().getLocalPart());
        QName interfaceOperation = interfaceOperationComp.getName();
       
        //Return a new FragmentIdentifier.
        return new FragmentIdentifier(new BindingMessageReferencePart(binding, interfaceOperation, fMessageLabel));
    }
View Full Code Here

     * Test that a <code>wsoap:code</code> extension attribute with a value of type xs:QName is represented
     * in the Component model extensions by the expected QName.
     */
    public void testSoapFaultCode_QName()
    {
        BindingFault bindFault = fBinding.getBindingFaults()[0];
        SOAPBindingFaultExtensions soapBindFaultExts =
            (SOAPBindingFaultExtensions) bindFault.getComponentExtensionContext(SOAPConstants.NS_URI_SOAP);
        SOAPFaultCode soapFaultCode = soapBindFaultExts.getSoapFaultCode();
       
        assertNotNull("The SOAPBindingFaultExtensions did not return a SOAPFaultCode.", soapFaultCode);
        assertTrue("The SOAPFaultCode does not represent a QName.", soapFaultCode.isQName());
        assertEquals("The QName represented by the SOAPFaultCode is not the expected one.",
View Full Code Here

     * Test that a <code>wsoap:code</code> extension attribute with a value of type xs:token "#any" is
     * represented in the Component model extensions by SOAPFaultCode.ANY.
     */
    public void testSoapFaultCode_TokenAny()
    {
        BindingFault bindFault = fBinding.getBindingFaults()[1];
        SOAPBindingFaultExtensions soapBindFaultExts =
            (SOAPBindingFaultExtensions) bindFault.getComponentExtensionContext(SOAPConstants.NS_URI_SOAP);
        SOAPFaultCode soapFaultCode = soapBindFaultExts.getSoapFaultCode();
       
        assertNotNull("The SOAPBindingFaultExtensions did not return a SOAPFaultCode.", soapFaultCode);
        assertEquals("The SOAPFaultCode does not represent the xs:token #any.",
                SOAPFaultCode.ANY,
View Full Code Here

     * property for the corresponding binding fault defaults to token "#any".
     * This should be represented in the Component model extensions by SOAPFaultCode.ANY.
     */
    public void testSoapFaultCode_Default()
    {
        BindingFault bindFault = fBinding.getBindingFaults()[2];
        SOAPBindingFaultExtensions soapBindFaultExts =
            (SOAPBindingFaultExtensions) bindFault.getComponentExtensionContext(SOAPConstants.NS_URI_SOAP);
        SOAPFaultCode soapFaultCode = soapBindFaultExts.getSoapFaultCode();
       
        assertNotNull("The SOAPBindingFaultExtensions did not return a SOAPFaultCode.", soapFaultCode);
        assertEquals("The wsoap:code extension attribute was omitted, so SOAPFaultCode.ANY was expected by default.",
                SOAPFaultCode.ANY,
View Full Code Here

     * Test that a <code>wsoap:subcodes</code> extension attribute with a value of type list of xs:QName is represented
     * in the Component model extensions by an array of the expected QNames.
     */
    public void testSoapFaultSubcodes_QNames()
    {
        BindingFault bindFault = fBinding.getBindingFaults()[0];
        SOAPBindingFaultExtensions soapBindFaultExts =
            (SOAPBindingFaultExtensions) bindFault.getComponentExtensionContext(SOAPConstants.NS_URI_SOAP);
        SOAPFaultSubcodes soapFaultSubcodes = soapBindFaultExts.getSoapFaultSubcodes();
       
        assertNotNull("The SOAPBindingFaultExtensions did not return a SOAPFaultSubcodes.", soapFaultSubcodes);
        assertTrue("The SOAPFaultSubcodes does not represent a QName.", soapFaultSubcodes.isQNames());
        assertTrue("The QNames represented by the SOAPFaultSubcodes are not the expected ones.",
View Full Code Here

     * Test that a <code>wsoap:subcodes</code> extension attribute with a value of type xs:token "#any" is
     * represented in the Component model extensions by SOAPFaultSubcodes.ANY.
     */
    public void testSoapFaultSubcodes_TokenAny()
    {
        BindingFault bindFault = fBinding.getBindingFaults()[1];
        SOAPBindingFaultExtensions soapBindFaultExts =
            (SOAPBindingFaultExtensions) bindFault.getComponentExtensionContext(SOAPConstants.NS_URI_SOAP);
        SOAPFaultSubcodes soapFaultSubcodes = soapBindFaultExts.getSoapFaultSubcodes();
       
        assertNotNull("The SOAPBindingFaultExtensions did not return a SOAPFaultSubcodes.", soapFaultSubcodes);
        assertEquals("The SOAPFaultSubcodes does not represent the xs:token #any.",
                SOAPFaultSubcodes.ANY,
View Full Code Here

     * property for the corresponding binding fault defaults to token "#any".
     * This should be represented in the Component model extensions by SOAPFaultSubcodes.ANY.
     */
    public void testSoapFaultSubcodes_Default()
    {
        BindingFault bindFault = fBinding.getBindingFaults()[2];
        SOAPBindingFaultExtensions soapBindFaultExts =
            (SOAPBindingFaultExtensions) bindFault.getComponentExtensionContext(SOAPConstants.NS_URI_SOAP);
        SOAPFaultSubcodes soapFaultSubcodes = soapBindFaultExts.getSoapFaultSubcodes();
       
        assertNotNull("The SOAPBindingFaultExtensions did not return a SOAPFaultSubcodes.", soapFaultSubcodes);
        assertEquals("The SOAPFaultSubcodes does not represent the xs:token #any.",
                SOAPFaultSubcodes.ANY,
View Full Code Here

     * Test that the <code>getSoapModules</code> method returns the expected number of SOAPModule objects
     * parsed from &lt;wsoap:module&gt; elements within a binding &lt;fault&gt; element.
     */
    public void testGetSoapModules()
    {
        BindingFault bindFault = fBinding.getBindingFaults()[1];
        SOAPBindingFaultExtensions soapBindFaultExts =
            (SOAPBindingFaultExtensions) bindFault.getComponentExtensionContext(SOAPConstants.NS_URI_SOAP);
        SOAPModule[] actual = soapBindFaultExts.getSoapModules();
        assertEquals("Unexpected number of SOAPModule objects.", 3, actual.length);
    }
View Full Code Here

TOP

Related Classes of org.apache.woden.wsdl20.BindingFault

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.