Examples of PingMeFault


Examples of org.objectweb.hello_world_doc_lit.PingMeFault

    public void pingMe() throws PingMeFault {
        FaultDetail fd = new FaultDetail();
        fd.setMajor((short)2);
        fd.setMinor((short)1);
        throw new PingMeFault("Test Exception", fd);
    }
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.PingMeFault

        FaultDetail faultDetail = new FaultDetail();
        faultDetail.setMajor((short)2);
        faultDetail.setMinor((short)1);
        LOG.info("Executing operation pingMe, throwing PingMeFault exception");
        System.out.println("Executing operation pingMe, throwing PingMeFault exception\n");
        throw new PingMeFault("PingMeFault raised by server", faultDetail);
    }
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.PingMeFault

        FaultDetail faultDetail = new FaultDetail();
        faultDetail.setMajor((short)2);
        faultDetail.setMinor((short)1);
        LOG.info("Executing operation pingMe, throwing PingMeFault exception");
        System.out.println("Executing operation pingMe, throwing PingMeFault exception\n");
        throw new PingMeFault("PingMeFault raised by server", faultDetail);
    }
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.PingMeFault

        FaultDetail faultDetail = new FaultDetail();
        faultDetail.setMajor((short)2);
        faultDetail.setMinor((short)1);
        LOG.info("Executing operation pingMe, throwing PingMeFault exception");
        System.out.println("Executing operation pingMe, throwing PingMeFault exception\n");
        throw new PingMeFault("PingMeFault raised by server", faultDetail);
    }
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.PingMeFault

        faultDetail.setMajor((short)2);
        faultDetail.setMinor((short)1);
        LOG.info("Executing operation pingMe, throwing PingMeFault exception");
        System.out.println("Executing operation pingMe, throwing PingMeFault exception\n");
        requestCounters[3]++;
        throw new PingMeFault("PingMeFault raised by server", faultDetail);
    }
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.PingMeFault

        FaultDetail faultDetail = new FaultDetail();
        faultDetail.setMajor((short)2);
        faultDetail.setMinor((short)1);
        LOG.info("Executing operation pingMe, throwing PingMeFault exception");
        System.out.println("Executing operation pingMe, throwing PingMeFault exception\n");
        throw new PingMeFault("PingMeFault raised by server", faultDetail);
    }
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.PingMeFault

        FaultDetail faultDetail = new FaultDetail();
        faultDetail.setMajor((short)2);
        faultDetail.setMinor((short)1);
        LOG.info("Executing operation pingMe, throwing PingMeFault exception");
        System.out.println("Executing operation pingMe, throwing PingMeFault exception\n");
        throw new PingMeFault("PingMeFault raised by server", faultDetail);
    }
View Full Code Here

Examples of org.objectweb.hello_world_xml_http.wrapped.PingMeFault

        FaultDetail faultDetail = new FaultDetail();
        faultDetail.setMajor((short)2);
        faultDetail.setMinor((short)1);
        LOG.info("Executing operation pingMe, throwing PingMeFault exception");
        System.out.println("Executing operation pingMe, throwing PingMeFault exception\n");
        throw new PingMeFault("PingMeFault raised by server", faultDetail);
    }
View Full Code Here

Examples of org.objectweb.hello_world_xml_http.wrapped.PingMeFault

        String exMessage = new String("Test Exception");
        FaultDetail ec = new FaultDetail();
        ec.setMajor((short)2);
        ec.setMinor((short)1);
        PingMeFault ex = new PingMeFault(exMessage, ec);
        objContext.setException(ex);

        binding.marshalFault(objContext,
                             xmlContext,
                             new JAXBDataBindingCallback(objContext.getMethod(),
                                                         DataBindingCallback.Mode.PARTS,
                                                         null));
        XMLMessage msg = xmlContext.getMessage();

        assertNotNull(msg);
        Node xmlNode = msg.getRoot();

        assertNotNull(xmlNode);
        assertEquals(1, xmlNode.getChildNodes().getLength());
        assertTrue(msg.hasFault());
        XMLFault fault = msg.getFault();
        assertNotNull(fault);
        assertEquals(getExceptionString(ex, exMessage),
                     fault.getFaultString());

        assertTrue(fault.hasChildNodes());
        Node detail = fault.getFaultDetail();
        assertNotNull(detail);
       
        NodeList list = detail.getChildNodes();
        assertEquals(1, list.getLength());
       
        WebFault wfAnnotation = ex.getClass().getAnnotation(WebFault.class);
        assertEquals(wfAnnotation.targetNamespace(), list.item(0).getNamespaceURI());
        assertEquals(wfAnnotation.name(), list.item(0).getLocalName());
    }
View Full Code Here

Examples of org.objectweb.hello_world_xml_http.wrapped.PingMeFault

                                                           null));
        assertNotNull(objContext.getException());
        Object faultEx = objContext.getException();
       
        assertTrue(PingMeFault.class.isAssignableFrom(faultEx.getClass()));
        PingMeFault nscf = (PingMeFault)faultEx;
        assertNotNull(nscf.getFaultInfo());
        FaultDetail faultInfo = nscf.getFaultInfo();

        assertEquals(faultInfo.getMajor(), (short)2);
        assertEquals(faultInfo.getMinor(), (short)1);
        assertEquals("org.objectweb.hello_world_xml_http.wrapped.PingMeFault: PingMeFault raised by server",
                     nscf.getMessage());
    }
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.