Examples of NSStack


Examples of org.apache.cxf.helpers.NSStack

        if (mustPropogateException(message)) {
            throw (Fault) message.getContent(Exception.class);
        }
       
        message.put(org.apache.cxf.message.Message.RESPONSE_CODE, new Integer(500));
        NSStack nsStack = new NSStack();
        nsStack.push();

        XMLStreamWriter writer = message.getContent(XMLStreamWriter.class);
        Fault f = (Fault) message.getContent(Exception.class);
        XMLFault xmlFault = XMLFault.createFault(f);
        try {
            nsStack.add(XMLConstants.NS_XML_FORMAT);
            String prefix = nsStack.getPrefix(XMLConstants.NS_XML_FORMAT);
            StaxUtils.writeStartElement(writer, prefix, XMLFault.XML_FAULT_ROOT,
                    XMLConstants.NS_XML_FORMAT);
            StaxUtils.writeStartElement(writer, prefix, XMLFault.XML_FAULT_STRING,
                    XMLConstants.NS_XML_FORMAT);
            Throwable t = xmlFault.getCause();
View Full Code Here

Examples of org.apache.cxf.helpers.NSStack

            throw (Fault) message.getContent(Exception.class);
        }
       
        Fault f = (Fault) message.getContent(Exception.class);
        message.put(org.apache.cxf.message.Message.RESPONSE_CODE, f.getStatusCode());
        NSStack nsStack = new NSStack();
        nsStack.push();

        XMLStreamWriter writer = message.getContent(XMLStreamWriter.class);
        try {
            nsStack.add("http://cxf.apache.org/bindings/xformat");
            String prefix = nsStack.getPrefix("http://cxf.apache.org/bindings/xformat");
            StaxUtils.writeStartElement(writer, prefix, "XMLFault",
                                        "http://cxf.apache.org/bindings/xformat");
            StaxUtils.writeStartElement(writer, prefix, "faultstring",
                                        "http://cxf.apache.org/bindings/xformat");
            Throwable t = f.getCause();
View Full Code Here

Examples of org.apache.cxf.helpers.NSStack

    }


    public void handleMessage(Message message) {
        try {
            NSStack nsStack = new NSStack();
            nsStack.push();

            BindingOperationInfo operation = (BindingOperationInfo) message.getExchange().get(
                            BindingOperationInfo.class.getName());

            assert operation.getName() != null;
View Full Code Here

Examples of org.apache.cxf.helpers.NSStack

        super(Phase.MARSHAL);
    }

    public void handleMessage(JBIMessage message) throws Fault {
        message.put(org.apache.cxf.message.Message.RESPONSE_CODE, new Integer(500));
        NSStack nsStack = new NSStack();
        nsStack.push();

       
       
        try {
            XMLStreamWriter writer = getWriter(message);
            Fault fault = getFault(message);
            JBIFault jbiFault = JBIFault.createFault(fault);
            nsStack.add(JBIConstants.NS_JBI_BINDING);
            String prefix = nsStack.getPrefix(JBIConstants.NS_JBI_BINDING);
            StaxUtils.writeStartElement(writer, prefix, JBIFault.JBI_FAULT_ROOT,
                                        JBIConstants.NS_JBI_BINDING);
            if (!jbiFault.hasDetails()) {
                writer.writeEmptyElement("fault");
            } else {
View Full Code Here

Examples of org.apache.cxf.helpers.NSStack

    }


    public void handleMessage(Message message) {
        try {
            NSStack nsStack = new NSStack();
            nsStack.push();

            BindingOperationInfo operation = (BindingOperationInfo) message.getExchange().get(
                            BindingOperationInfo.class.getName());

            assert operation.getName() != null;
View Full Code Here

Examples of org.apache.cxf.helpers.NSStack

        setPhase(Phase.MARSHAL);
    }

    public void handleMessage(Message message) throws Fault {
        message.put(org.apache.cxf.message.Message.RESPONSE_CODE, new Integer(500));
        NSStack nsStack = new NSStack();
        nsStack.push();

        XMLStreamWriter writer = message.getContent(XMLStreamWriter.class);
        Fault f = (Fault) message.getContent(Exception.class);
        XMLFault xmlFault = XMLFault.createFault(f);
        try {
            nsStack.add(XMLConstants.NS_XML_FORMAT);
            String prefix = nsStack.getPrefix(XMLConstants.NS_XML_FORMAT);
            StaxUtils.writeStartElement(writer, prefix, XMLFault.XML_FAULT_ROOT,
                    XMLConstants.NS_XML_FORMAT);
            StaxUtils.writeStartElement(writer, prefix, XMLFault.XML_FAULT_STRING,
                    XMLConstants.NS_XML_FORMAT);
            Throwable t = xmlFault.getCause();
View Full Code Here

Examples of org.apache.cxf.helpers.NSStack

    }


    public void handleMessage(Message message) {
        try {
            NSStack nsStack = new NSStack();
            nsStack.push();

            BindingOperationInfo operation = (BindingOperationInfo) message.getExchange().get(
                            BindingOperationInfo.class.getName());

            assert operation.getName() != null;
View Full Code Here

Examples of org.apache.cxf.helpers.NSStack

        super(Phase.MARSHAL);
    }

    public void handleMessage(JBIMessage message) throws Fault {
        message.put(org.apache.cxf.message.Message.RESPONSE_CODE, new Integer(500));
        NSStack nsStack = new NSStack();
        nsStack.push();

       
       
        try {
            XMLStreamWriter writer = getWriter(message);
            Fault fault = getFault(message);
            JBIFault jbiFault = JBIFault.createFault(fault);
            nsStack.add(JBIConstants.NS_JBI_BINDING);
            String prefix = nsStack.getPrefix(JBIConstants.NS_JBI_BINDING);
            StaxUtils.writeStartElement(writer, prefix, JBIFault.JBI_FAULT_ROOT,
                                        JBIConstants.NS_JBI_BINDING);
            if (!jbiFault.hasDetails()) {
                Element faultString = DOMUtils.createDocument().createElement("fault");
                faultString.setTextContent(jbiFault.getCause().getMessage());
View Full Code Here

Examples of org.apache.cxf.helpers.NSStack

        super(phase);
    }

    public void handleMessage(Message message) throws Fault {
        message.put(org.apache.cxf.message.Message.RESPONSE_CODE, new Integer(500));
        NSStack nsStack = new NSStack();
        nsStack.push();

        XMLStreamWriter writer = message.getContent(XMLStreamWriter.class);
        Fault f = (Fault) message.getContent(Exception.class);
        XMLFault xmlFault = XMLFault.createFault(f);
        try {
            nsStack.add(XMLConstants.NS_XML_FORMAT);
            String prefix = nsStack.getPrefix(XMLConstants.NS_XML_FORMAT);
            StaxUtils.writeStartElement(writer, prefix, XMLFault.XML_FAULT_ROOT,
                    XMLConstants.NS_XML_FORMAT);
            StaxUtils.writeStartElement(writer, prefix, XMLFault.XML_FAULT_STRING,
                    XMLConstants.NS_XML_FORMAT);
            Throwable t = xmlFault.getCause();
View Full Code Here

Examples of org.apache.cxf.helpers.NSStack

    }


    public void handleMessage(Message message) {
        try {
            NSStack nsStack = new NSStack();
            nsStack.push();

            BindingOperationInfo operation = (BindingOperationInfo) message.getExchange().get(
                            BindingOperationInfo.class.getName());

            assert operation.getName() != null;
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.