public class XmlHttpProxy extends Object
Modifier and Type | Class and Description |
---|---|
class |
XmlHttpProxy.Cookie |
static interface |
XmlHttpProxy.CookieCallback |
Modifier and Type | Field and Description |
---|---|
static String |
DELETE |
static String |
GET |
static String |
POST |
static String |
PUT |
Constructor and Description |
---|
XmlHttpProxy() |
XmlHttpProxy(String proxyHost,
int proxyPort) |
XmlHttpProxy(String proxyHost,
int proxyPort,
String userName,
String password) |
Modifier and Type | Method and Description |
---|---|
void |
doPost(String urlString,
OutputStream out,
InputStream xslInputStream,
Map paramsMap,
Map headers,
String postData,
String postContentType,
String userName,
String password)
This method will go out and make the call and it will apply an XSLT Transformation with the
set of parameters provided.
|
void |
doProcess(String urlString,
OutputStream out,
InputStream xslInputStream,
Map paramsMap,
Map headers,
String method,
String postData,
String postContentType,
String userName,
String password)
This method will go out and make the call and it will apply an XSLT Transformation with the
set of parameters provided.
|
static Logger |
getLogger()
CLI to the XmlHttpProxy
|
static ProxyConfig |
loadServices(InputStream is) |
void |
processRequest(String urlString,
OutputStream out,
InputStream xslInputStream,
Map paramsMap,
Map headers,
String method,
String userName,
String password)
This method will go out and make the call and it will apply an XSLT Transformation with the
set of parameters provided.
|
void |
transform(InputStream xmlIS,
InputStream xslIS,
Map params,
OutputStream result,
String encoding)
Do the XSLT transformation
|
public static String GET
public static String POST
public static String DELETE
public static String PUT
public XmlHttpProxy()
public XmlHttpProxy(String proxyHost, int proxyPort)
public void processRequest(String urlString, OutputStream out, InputStream xslInputStream, Map paramsMap, Map headers, String method, String userName, String password) throws IOException, MalformedURLException
urlString
- - The URL which you are looking upout
- - The OutputStream to which the resulting document is writtenxslInputStream
- - An input Stream to an XSL style sheet that is provided to the XSLT processor. If set to null there will be no transformationparamsMap
- - A Map of parameters that are feed to the XSLT Processor. These params may be used when generating content. This may be set to null if no parameters are necessary.method
- - The HTTP method used.IOException
MalformedURLException
public void doPost(String urlString, OutputStream out, InputStream xslInputStream, Map paramsMap, Map headers, String postData, String postContentType, String userName, String password) throws IOException, MalformedURLException
urlString
- - The URL which you are looking upout
- - The OutputStream to which the resulting document is writtenIOException
MalformedURLException
public void doProcess(String urlString, OutputStream out, InputStream xslInputStream, Map paramsMap, Map headers, String method, String postData, String postContentType, String userName, String password) throws IOException, MalformedURLException
urlString
- - The URL which you are looking upout
- - The OutputStream to which the resulting document is writtenxslInputStream
- - An input Stream to an XSL style sheet that is provided to the XSLT processor. If set to null there will be no transformationparamsMap
- - A Map of parameters that are feed to the XSLT Processor. These params may be used when generating content. This may be set to null if no parameters are necessary.method
- - the HTTP method used.postData
- - A String of the bodyContent to be posted. A doPost will be used if this is parameter is not null.postContentType
- - The request contentType used when posting data. Will not be set if this parameter is null.userName
- - userName used for basic authorizationpassword
- - password used for basic authorizationIOException
MalformedURLException
public void transform(InputStream xmlIS, InputStream xslIS, Map params, OutputStream result, String encoding)
public static Logger getLogger()
public static ProxyConfig loadServices(InputStream is)
Copyright © 2013-2015 JBoss, a division of Red Hat. All Rights Reserved.