com.sun.xml.internal.ws.message.EmptyMessageImpl Java Examples
The following examples show how to use
com.sun.xml.internal.ws.message.EmptyMessageImpl.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: Messages.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
/** * Creates a {@link Message} from an {@link Element} that represents * the whole SOAP message. * * @param soapEnvelope * The SOAP envelope element. */ public static Message create(Element soapEnvelope) { SOAPVersion ver = SOAPVersion.fromNsUri(soapEnvelope.getNamespaceURI()); // find the headers Element header = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Header"); HeaderList headers = null; if(header!=null) { for( Node n=header.getFirstChild(); n!=null; n=n.getNextSibling() ) { if(n.getNodeType()==Node.ELEMENT_NODE) { if(headers==null) headers = new HeaderList(ver); headers.add(Headers.create((Element)n)); } } } // find the payload Element body = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(body==null) throw new WebServiceException("Message doesn't have <S:Body> "+soapEnvelope); Element payload = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(payload==null) { return new EmptyMessageImpl(headers, new AttachmentSetImpl(), ver); } else { return new DOMMessage(ver,headers,payload); } }
Example #2
Source File: Messages.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
/** * Creates a {@link Message} from an {@link Element} that represents * the whole SOAP message. * * @param soapEnvelope * The SOAP envelope element. */ public static Message create(Element soapEnvelope) { SOAPVersion ver = SOAPVersion.fromNsUri(soapEnvelope.getNamespaceURI()); // find the headers Element header = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Header"); HeaderList headers = null; if(header!=null) { for( Node n=header.getFirstChild(); n!=null; n=n.getNextSibling() ) { if(n.getNodeType()==Node.ELEMENT_NODE) { if(headers==null) headers = new HeaderList(ver); headers.add(Headers.create((Element)n)); } } } // find the payload Element body = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(body==null) throw new WebServiceException("Message doesn't have <S:Body> "+soapEnvelope); Element payload = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(payload==null) { return new EmptyMessageImpl(headers, new AttachmentSetImpl(), ver); } else { return new DOMMessage(ver,headers,payload); } }
Example #3
Source File: Messages.java From openjdk-8 with GNU General Public License v2.0 | 5 votes |
/** * Creates a {@link Message} from an {@link Element} that represents * the whole SOAP message. * * @param soapEnvelope * The SOAP envelope element. */ public static Message create(Element soapEnvelope) { SOAPVersion ver = SOAPVersion.fromNsUri(soapEnvelope.getNamespaceURI()); // find the headers Element header = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Header"); HeaderList headers = null; if(header!=null) { for( Node n=header.getFirstChild(); n!=null; n=n.getNextSibling() ) { if(n.getNodeType()==Node.ELEMENT_NODE) { if(headers==null) headers = new HeaderList(ver); headers.add(Headers.create((Element)n)); } } } // find the payload Element body = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(body==null) throw new WebServiceException("Message doesn't have <S:Body> "+soapEnvelope); Element payload = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(payload==null) { return new EmptyMessageImpl(headers, new AttachmentSetImpl(), ver); } else { return new DOMMessage(ver,headers,payload); } }
Example #4
Source File: Messages.java From openjdk-jdk8u with GNU General Public License v2.0 | 5 votes |
/** * Creates a {@link Message} from an {@link Element} that represents * the whole SOAP message. * * @param soapEnvelope * The SOAP envelope element. */ public static Message create(Element soapEnvelope) { SOAPVersion ver = SOAPVersion.fromNsUri(soapEnvelope.getNamespaceURI()); // find the headers Element header = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Header"); HeaderList headers = null; if(header!=null) { for( Node n=header.getFirstChild(); n!=null; n=n.getNextSibling() ) { if(n.getNodeType()==Node.ELEMENT_NODE) { if(headers==null) headers = new HeaderList(ver); headers.add(Headers.create((Element)n)); } } } // find the payload Element body = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(body==null) throw new WebServiceException("Message doesn't have <S:Body> "+soapEnvelope); Element payload = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(payload==null) { return new EmptyMessageImpl(headers, new AttachmentSetImpl(), ver); } else { return new DOMMessage(ver,headers,payload); } }
Example #5
Source File: Messages.java From openjdk-8-source with GNU General Public License v2.0 | 5 votes |
/** * Creates a {@link Message} from an {@link Element} that represents * the whole SOAP message. * * @param soapEnvelope * The SOAP envelope element. */ public static Message create(Element soapEnvelope) { SOAPVersion ver = SOAPVersion.fromNsUri(soapEnvelope.getNamespaceURI()); // find the headers Element header = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Header"); HeaderList headers = null; if(header!=null) { for( Node n=header.getFirstChild(); n!=null; n=n.getNextSibling() ) { if(n.getNodeType()==Node.ELEMENT_NODE) { if(headers==null) headers = new HeaderList(ver); headers.add(Headers.create((Element)n)); } } } // find the payload Element body = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(body==null) throw new WebServiceException("Message doesn't have <S:Body> "+soapEnvelope); Element payload = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(payload==null) { return new EmptyMessageImpl(headers, new AttachmentSetImpl(), ver); } else { return new DOMMessage(ver,headers,payload); } }
Example #6
Source File: Messages.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 5 votes |
/** * Creates a {@link Message} from an {@link Element} that represents * the whole SOAP message. * * @param soapEnvelope * The SOAP envelope element. */ public static Message create(Element soapEnvelope) { SOAPVersion ver = SOAPVersion.fromNsUri(soapEnvelope.getNamespaceURI()); // find the headers Element header = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Header"); HeaderList headers = null; if(header!=null) { for( Node n=header.getFirstChild(); n!=null; n=n.getNextSibling() ) { if(n.getNodeType()==Node.ELEMENT_NODE) { if(headers==null) headers = new HeaderList(ver); headers.add(Headers.create((Element)n)); } } } // find the payload Element body = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(body==null) throw new WebServiceException("Message doesn't have <S:Body> "+soapEnvelope); Element payload = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(payload==null) { return new EmptyMessageImpl(headers, new AttachmentSetImpl(), ver); } else { return new DOMMessage(ver,headers,payload); } }
Example #7
Source File: Messages.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
/** * Creates a {@link Message} from an {@link Element} that represents * the whole SOAP message. * * @param soapEnvelope * The SOAP envelope element. */ public static Message create(Element soapEnvelope) { SOAPVersion ver = SOAPVersion.fromNsUri(soapEnvelope.getNamespaceURI()); // find the headers Element header = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Header"); HeaderList headers = null; if(header!=null) { for( Node n=header.getFirstChild(); n!=null; n=n.getNextSibling() ) { if(n.getNodeType()==Node.ELEMENT_NODE) { if(headers==null) headers = new HeaderList(ver); headers.add(Headers.create((Element)n)); } } } // find the payload Element body = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(body==null) throw new WebServiceException("Message doesn't have <S:Body> "+soapEnvelope); Element payload = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(payload==null) { return new EmptyMessageImpl(headers, new AttachmentSetImpl(), ver); } else { return new DOMMessage(ver,headers,payload); } }
Example #8
Source File: Messages.java From hottub with GNU General Public License v2.0 | 5 votes |
/** * Creates a {@link Message} from an {@link Element} that represents * the whole SOAP message. * * @param soapEnvelope * The SOAP envelope element. */ public static Message create(Element soapEnvelope) { SOAPVersion ver = SOAPVersion.fromNsUri(soapEnvelope.getNamespaceURI()); // find the headers Element header = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Header"); HeaderList headers = null; if(header!=null) { for( Node n=header.getFirstChild(); n!=null; n=n.getNextSibling() ) { if(n.getNodeType()==Node.ELEMENT_NODE) { if(headers==null) headers = new HeaderList(ver); headers.add(Headers.create((Element)n)); } } } // find the payload Element body = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(body==null) throw new WebServiceException("Message doesn't have <S:Body> "+soapEnvelope); Element payload = DOMUtil.getFirstChild(soapEnvelope, ver.nsUri, "Body"); if(payload==null) { return new EmptyMessageImpl(headers, new AttachmentSetImpl(), ver); } else { return new DOMMessage(ver,headers,payload); } }
Example #9
Source File: LogicalMessageImpl.java From openjdk-8 with GNU General Public License v2.0 | 4 votes |
public Message getMessage(MessageHeaders headers, AttachmentSet attachments, WSBinding binding) { return new EmptyMessageImpl(headers,attachments,binding.getSOAPVersion()); }
Example #10
Source File: Messages.java From openjdk-8 with GNU General Public License v2.0 | 4 votes |
/** * Creates a {@link Message} that doesn't have any payload. */ public static Message createEmpty(SOAPVersion soapVersion) { return new EmptyMessageImpl(soapVersion); }
Example #11
Source File: LogicalMessageImpl.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
public Message getMessage(MessageHeaders headers, AttachmentSet attachments, WSBinding binding) { return new EmptyMessageImpl(headers,attachments,binding.getSOAPVersion()); }
Example #12
Source File: Messages.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
/** * Creates a {@link Message} that doesn't have any payload. */ public static Message createEmpty(SOAPVersion soapVersion) { return new EmptyMessageImpl(soapVersion); }
Example #13
Source File: LogicalMessageImpl.java From hottub with GNU General Public License v2.0 | 4 votes |
public Message getMessage(MessageHeaders headers, AttachmentSet attachments, WSBinding binding) { return new EmptyMessageImpl(headers,attachments,binding.getSOAPVersion()); }
Example #14
Source File: Messages.java From hottub with GNU General Public License v2.0 | 4 votes |
/** * Creates a {@link Message} that doesn't have any payload. */ public static Message createEmpty(SOAPVersion soapVersion) { return new EmptyMessageImpl(soapVersion); }
Example #15
Source File: LogicalMessageImpl.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
public Message getMessage(MessageHeaders headers, AttachmentSet attachments, WSBinding binding) { return new EmptyMessageImpl(headers,attachments,binding.getSOAPVersion()); }
Example #16
Source File: Messages.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
/** * Creates a {@link Message} that doesn't have any payload. */ public static Message createEmpty(SOAPVersion soapVersion) { return new EmptyMessageImpl(soapVersion); }
Example #17
Source File: LogicalMessageImpl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
public Message getMessage(MessageHeaders headers, AttachmentSet attachments, WSBinding binding) { return new EmptyMessageImpl(headers,attachments,binding.getSOAPVersion()); }
Example #18
Source File: Messages.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
/** * Creates a {@link Message} that doesn't have any payload. */ public static Message createEmpty(SOAPVersion soapVersion) { return new EmptyMessageImpl(soapVersion); }
Example #19
Source File: LogicalMessageImpl.java From openjdk-jdk8u with GNU General Public License v2.0 | 4 votes |
public Message getMessage(MessageHeaders headers, AttachmentSet attachments, WSBinding binding) { return new EmptyMessageImpl(headers,attachments,binding.getSOAPVersion()); }
Example #20
Source File: Messages.java From openjdk-jdk8u with GNU General Public License v2.0 | 4 votes |
/** * Creates a {@link Message} that doesn't have any payload. */ public static Message createEmpty(SOAPVersion soapVersion) { return new EmptyMessageImpl(soapVersion); }
Example #21
Source File: LogicalMessageImpl.java From jdk8u60 with GNU General Public License v2.0 | 4 votes |
public Message getMessage(MessageHeaders headers, AttachmentSet attachments, WSBinding binding) { return new EmptyMessageImpl(headers,attachments,binding.getSOAPVersion()); }
Example #22
Source File: Messages.java From jdk8u60 with GNU General Public License v2.0 | 4 votes |
/** * Creates a {@link Message} that doesn't have any payload. */ public static Message createEmpty(SOAPVersion soapVersion) { return new EmptyMessageImpl(soapVersion); }
Example #23
Source File: LogicalMessageImpl.java From TencentKona-8 with GNU General Public License v2.0 | 4 votes |
public Message getMessage(MessageHeaders headers, AttachmentSet attachments, WSBinding binding) { return new EmptyMessageImpl(headers,attachments,binding.getSOAPVersion()); }
Example #24
Source File: Messages.java From TencentKona-8 with GNU General Public License v2.0 | 4 votes |
/** * Creates a {@link Message} that doesn't have any payload. */ public static Message createEmpty(SOAPVersion soapVersion) { return new EmptyMessageImpl(soapVersion); }