public class HTTPUtil
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static java.lang.String |
httpBodyToXml(java.io.InputStream httpBody,
java.lang.String contentType)
Serializes an HTTP request body into XML.
|
static java.lang.String |
httpBodyToXml(java.lang.String httpBody,
java.lang.String contentType)
Serializes an HTTP request body into XML.
|
static java.util.Map<java.lang.String,java.lang.String> |
parseHeaders(java.lang.String str)
Converts a block of HTTP header fields into a Map containing each header key and value.
|
public static java.util.Map<java.lang.String,java.lang.String> parseHeaders(java.lang.String str)
throws java.lang.Exception
str - The block of HTTP header fields to convert.java.lang.Exceptionpublic static java.lang.String httpBodyToXml(java.io.InputStream httpBody,
java.lang.String contentType)
throws javax.mail.MessagingException,
java.io.IOException,
com.mirth.connect.donkey.util.DonkeyElement.DonkeyElementException,
javax.xml.parsers.ParserConfigurationException
httpBody - The request body/payload input stream to parse.contentType - The MIME content type of the request.javax.mail.MessagingExceptionjava.io.IOExceptioncom.mirth.connect.donkey.util.DonkeyElement.DonkeyElementExceptionjavax.xml.parsers.ParserConfigurationExceptionpublic static java.lang.String httpBodyToXml(java.lang.String httpBody,
java.lang.String contentType)
throws javax.mail.MessagingException,
java.io.IOException,
com.mirth.connect.donkey.util.DonkeyElement.DonkeyElementException,
javax.xml.parsers.ParserConfigurationException
httpBody - The request body/payload string to parse.contentType - The MIME content type of the request.javax.mail.MessagingExceptionjava.io.IOExceptioncom.mirth.connect.donkey.util.DonkeyElement.DonkeyElementExceptionjavax.xml.parsers.ParserConfigurationException