Package fr.paris.lutece.util.httpaccess
Class HttpAccess
- java.lang.Object
-
- fr.paris.lutece.util.httpaccess.HttpAccess
-
public class HttpAccess extends java.lang.ObjectHttp net Object Accessor.
-
-
Constructor Summary
Constructors Constructor Description HttpAccess()Instantiates a new http access.HttpAccess(HttpAccessService accessService)Instantiates a new http access.HttpAccess(HttpAccessService accessService, ResponseStatusValidator validator)Instantiates a new http access.HttpAccess(ResponseStatusValidator validator)Instantiates a new http access.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringdoDelete(java.lang.String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Send a DELETE HTTP request to an url and return the response content.java.lang.StringdoDeleteJSON(java.lang.String strUrl, java.lang.String strJSON, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Send a DELETE HTTP request to an url and return the response content.java.lang.StringdoGet(java.lang.String strUrl)Send a GET HTTP request to an Url and return the response content.java.lang.StringdoGet(java.lang.String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements)Send a GET HTTP request to an Url and return the response content.java.lang.StringdoGet(java.lang.String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headers)Send a GET HTTP request to an Url and return the response content.java.lang.StringdoGet(java.lang.String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Send a GET HTTP request to an Url and return the response content.java.lang.StringdoPost(java.lang.String strUrl, java.util.Map<java.lang.String,java.lang.String> params)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPost(java.lang.String strUrl, java.util.Map<java.lang.String,java.lang.String> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPost(java.lang.String strUrl, java.util.Map<java.lang.String,java.lang.String> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPost(java.lang.String strUrl, java.util.Map<java.lang.String,java.lang.String> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPostJSON(java.lang.String strUrl, java.lang.String strJSON, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Do post json.java.lang.StringdoPostJSON(java.lang.String strUrl, java.lang.String strJSON, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Do post json.java.lang.StringdoPostMultiPart(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, java.util.Map<java.lang.String,org.apache.commons.fileupload.FileItem> fileItems)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPostMultiPart(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, java.util.Map<java.lang.String,org.apache.commons.fileupload.FileItem> fileItems, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPostMultiPart(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, java.util.Map<java.lang.String,org.apache.commons.fileupload.FileItem> fileItems, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPostMultiPart(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, java.util.Map<java.lang.String,org.apache.commons.fileupload.FileItem> fileItems, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPostMultiValues(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPostMultiValues(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPostMultiValues(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPostMultiValues(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Send a POST HTTP request to an url and return the response content.java.lang.StringdoPut(java.lang.String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> params, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Send a PUT HTTP request to an url and return the response content.java.lang.StringdoPutJSON(java.lang.String strUrl, java.lang.String strJSON, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Do put json.java.lang.StringdoPutJSON(java.lang.String strUrl, java.lang.String strJSON, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Do put json.java.lang.StringdoRequestEnclosingMethod(java.lang.String strUrl, java.lang.String strMethod, java.lang.String strContent, java.lang.String contentType, java.lang.String charset, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse)Do request enclosing method.org.apache.commons.fileupload.FileItemdownloadFile(java.lang.String strUrl)Send a GET HTTP request to an Url and return the response content.voiddownloadFile(java.lang.String strUrl, java.io.OutputStream outputStream)Send a GET HTTP request to an Url and return the response content in the ouput stream.voiddownloadFile(java.lang.String strUrl, java.lang.String strFilePath)Send a GET HTTP request to an Url and return the response content.java.lang.StringgetFileName(java.lang.String strUrl)Send a GET HTTP request to an Url and return the response content.
-
-
-
Constructor Detail
-
HttpAccess
public HttpAccess()
Instantiates a new http access.
-
HttpAccess
public HttpAccess(ResponseStatusValidator validator)
Instantiates a new http access.- Parameters:
validator- the validator
-
HttpAccess
public HttpAccess(HttpAccessService accessService, ResponseStatusValidator validator)
Instantiates a new http access.- Parameters:
accessService- the access servicevalidator- the validator
-
HttpAccess
public HttpAccess(HttpAccessService accessService)
Instantiates a new http access.- Parameters:
accessService- the access service
-
-
Method Detail
-
doGet
public java.lang.String doGet(java.lang.String strUrl) throws HttpAccessExceptionSend a GET HTTP request to an Url and return the response content.- Parameters:
strUrl- The Url to access- Returns:
- The response content of the Get request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doGet
public java.lang.String doGet(java.lang.String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements) throws HttpAccessExceptionSend a GET HTTP request to an Url and return the response content.- Parameters:
strUrl- The Url to accessauthenticator- TheRequestAuthenticatorlistElements- to include in the signature- Returns:
- The response content of the Get request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doGet
public java.lang.String doGet(java.lang.String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headers) throws HttpAccessExceptionSend a GET HTTP request to an Url and return the response content.- Parameters:
strUrl- The Url to accessauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureheaders- the headers- Returns:
- The response content of the Get request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doGet
public java.lang.String doGet(java.lang.String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionSend a GET HTTP request to an Url and return the response content.- Parameters:
strUrl- The Url to accessauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureheadersRequest- Map of headers request parametersheadersResponse- Map to contain response headers- Returns:
- The response content of the Get request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPost
public java.lang.String doPost(java.lang.String strUrl, java.util.Map<java.lang.String,java.lang.String> params) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to post- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPost
public java.lang.String doPost(java.lang.String strUrl, java.util.Map<java.lang.String,java.lang.String> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to postauthenticator- TheRequestAuthenticatorlistElements- to include in the signature- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPost
public java.lang.String doPost(java.lang.String strUrl, java.util.Map<java.lang.String,java.lang.String> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to postauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureheadersRequest- Map of headers request parameters- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPost
public java.lang.String doPost(java.lang.String strUrl, java.util.Map<java.lang.String,java.lang.String> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to postauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureheadersRequest- Map of headers request parametersheadersResponse- Map to contain response headers- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doRequestEnclosingMethod
public java.lang.String doRequestEnclosingMethod(java.lang.String strUrl, java.lang.String strMethod, java.lang.String strContent, java.lang.String contentType, java.lang.String charset, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionDo request enclosing method.- Parameters:
strUrl- the str urlstrMethod- the str methodstrContent- the str contentcontentType- the content typecharset- the charsetauthenticator- the authenticatorlistElements- the list elementsheadersRequest- the headers requestheadersResponse- the headers response- Returns:
- the string
- Throws:
HttpAccessException- the http access exception
-
doPostJSON
public java.lang.String doPostJSON(java.lang.String strUrl, java.lang.String strJSON, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionDo post json.- Parameters:
strUrl- the str urlstrJSON- the str jsonauthenticator- the authenticatorlistElements- the list elementsheadersRequest- the headers requestheadersResponse- the headers response- Returns:
- the string
- Throws:
HttpAccessException- the http access exception
-
doPostJSON
public java.lang.String doPostJSON(java.lang.String strUrl, java.lang.String strJSON, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionDo post json.- Parameters:
strUrl- the str urlstrJSON- the str jsonheadersRequest- the headers requestheadersResponse- the headers response- Returns:
- the string
- Throws:
HttpAccessException- the http access exception
-
doPutJSON
public java.lang.String doPutJSON(java.lang.String strUrl, java.lang.String strJSON, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionDo put json.- Parameters:
strUrl- the str urlstrJSON- the str jsonauthenticator- the authenticatorlistElements- the list elementsheadersRequest- the headers requestheadersResponse- the headers response- Returns:
- the string
- Throws:
HttpAccessException- the http access exception
-
doPutJSON
public java.lang.String doPutJSON(java.lang.String strUrl, java.lang.String strJSON, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionDo put json.- Parameters:
strUrl- the str urlstrJSON- the str jsonheadersRequest- the headers requestheadersResponse- the headers response- Returns:
- the string
- Throws:
HttpAccessException- the http access exception
-
doPostMultiValues
public java.lang.String doPostMultiValues(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to post- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPostMultiValues
public java.lang.String doPostMultiValues(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to postauthenticator- TheRequestAuthenticatorlistElements- to include in the signature- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPostMultiValues
public java.lang.String doPostMultiValues(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to postauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureheadersRequest- Map of headers request parameters- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPostMultiValues
public java.lang.String doPostMultiValues(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to postauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureheadersRequest- Map of headers request parametersheadersResponse- Map to contain response headers- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPostMultiPart
public java.lang.String doPostMultiPart(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, java.util.Map<java.lang.String,org.apache.commons.fileupload.FileItem> fileItems) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to postfileItems- The list of file items- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPostMultiPart
public java.lang.String doPostMultiPart(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, java.util.Map<java.lang.String,org.apache.commons.fileupload.FileItem> fileItems, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to postfileItems- The list of file itemsauthenticator- TheRequestAuthenticatorlistElements- to include in the signature- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPostMultiPart
public java.lang.String doPostMultiPart(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, java.util.Map<java.lang.String,org.apache.commons.fileupload.FileItem> fileItems, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to postfileItems- The list of file itemsauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureheadersRequest- Map of headers request parameters- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPostMultiPart
public java.lang.String doPostMultiPart(java.lang.String strUrl, java.util.Map<java.lang.String,java.util.List<java.lang.String>> params, java.util.Map<java.lang.String,org.apache.commons.fileupload.FileItem> fileItems, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionSend a POST HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessparams- the list of parameters to postfileItems- The list of file itemsauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureheadersRequest- Map of headers request parametersheadersResponse- Map to contain response headers- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doPut
public java.lang.String doPut(java.lang.String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> params, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionSend a PUT HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureparams- the paramsheadersRequest- Map of headers request parametersheadersResponse- Map to contain response headers- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doDelete
public java.lang.String doDelete(java.lang.String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionSend a DELETE HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureheadersRequest- Map of headers request parametersheadersResponse- Map to contain response headers- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
doDeleteJSON
public java.lang.String doDeleteJSON(java.lang.String strUrl, java.lang.String strJSON, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, java.util.List<java.lang.String> listElements, java.util.Map<java.lang.String,java.lang.String> headersRequest, java.util.Map<java.lang.String,java.lang.String> headersResponse) throws HttpAccessExceptionSend a DELETE HTTP request to an url and return the response content.- Parameters:
strUrl- the url to accessstrJson- the json to send in bodyauthenticator- TheRequestAuthenticatorlistElements- to include in the signatureheadersRequest- Map of headers request parametersheadersResponse- Map to contain response headers- Returns:
- The response content of the Post request to the given Url
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
downloadFile
public void downloadFile(java.lang.String strUrl, java.lang.String strFilePath) throws HttpAccessExceptionSend a GET HTTP request to an Url and return the response content.- Parameters:
strUrl- The Url to accessstrFilePath- the file path- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
downloadFile
public void downloadFile(java.lang.String strUrl, java.io.OutputStream outputStream) throws HttpAccessExceptionSend a GET HTTP request to an Url and return the response content in the ouput stream.- Parameters:
strUrl- The Url to accessoutputStream- write in the outpustrean the contents of the file- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
getFileName
public java.lang.String getFileName(java.lang.String strUrl) throws HttpAccessExceptionSend a GET HTTP request to an Url and return the response content.- Parameters:
strUrl- The Url to access- Returns:
- the file name
- Throws:
HttpAccessException- if there is a problem to access to the given Url
-
downloadFile
public org.apache.commons.fileupload.FileItem downloadFile(java.lang.String strUrl) throws HttpAccessExceptionSend a GET HTTP request to an Url and return the response content.- Parameters:
strUrl- The Url to access- Returns:
- a
FileItem - Throws:
HttpAccessException- if there is a problem to access to the given Url
-
-