public class HttpAccess extends Object
| Constructor and Description |
|---|
HttpAccess() |
| Modifier and Type | Method and Description |
|---|---|
String |
doDelete(String strUrl,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements,
Map<String,String> headersRequest,
Map<String,String> headersResponse)
Send a DELETE HTTP request to an url and return the response content
|
String |
doGet(String strUrl)
Send a GET HTTP request to an Url and return the response content.
|
String |
doGet(String strUrl,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements)
Send a GET HTTP request to an Url and return the response content.
|
String |
doGet(String strUrl,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements,
Map<String,String> headers)
Send a GET HTTP request to an Url and return the response content.
|
String |
doGet(String strUrl,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements,
Map<String,String> headersRequest,
Map<String,String> headersResponse)
Send a GET HTTP request to an Url and return the response content.
|
String |
doPost(String strUrl,
Map<String,String> params)
Send a POST HTTP request to an url and return the response content
|
String |
doPost(String strUrl,
Map<String,String> params,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements)
Send a POST HTTP request to an url and return the response content
|
String |
doPost(String strUrl,
Map<String,String> params,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements,
Map<String,String> headersRequest)
Send a POST HTTP request to an url and return the response content
|
String |
doPost(String strUrl,
Map<String,String> params,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements,
Map<String,String> headersRequest,
Map<String,String> headersResponse)
Send a POST HTTP request to an url and return the response content
|
String |
doPostMultiPart(String strUrl,
Map<String,List<String>> params,
Map<String,org.apache.commons.fileupload.FileItem> fileItems)
Send a POST HTTP request to an url and return the response content
|
String |
doPostMultiPart(String strUrl,
Map<String,List<String>> params,
Map<String,org.apache.commons.fileupload.FileItem> fileItems,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements)
Send a POST HTTP request to an url and return the response content
|
String |
doPostMultiPart(String strUrl,
Map<String,List<String>> params,
Map<String,org.apache.commons.fileupload.FileItem> fileItems,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements,
Map<String,String> headersRequest)
Send a POST HTTP request to an url and return the response content
|
String |
doPostMultiPart(String strUrl,
Map<String,List<String>> params,
Map<String,org.apache.commons.fileupload.FileItem> fileItems,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements,
Map<String,String> headersRequest,
Map<String,String> headersResponse)
Send a POST HTTP request to an url and return the response content
|
String |
doPostMultiValues(String strUrl,
Map<String,List<String>> params)
Send a POST HTTP request to an url and return the response content
|
String |
doPostMultiValues(String strUrl,
Map<String,List<String>> params,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements)
Send a POST HTTP request to an url and return the response content
|
String |
doPostMultiValues(String strUrl,
Map<String,List<String>> params,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements,
Map<String,String> headersRequest)
Send a POST HTTP request to an url and return the response content
|
String |
doPostMultiValues(String strUrl,
Map<String,List<String>> params,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements,
Map<String,String> headersRequest,
Map<String,String> headersResponse)
Send a POST HTTP request to an url and return the response content
|
String |
doPut(String strUrl,
fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator,
List<String> listElements,
Map<String,String> params,
Map<String,String> headersRequest,
Map<String,String> headersResponse)
Send a PUT HTTP request to an url and return the response content
|
org.apache.commons.fileupload.FileItem |
downloadFile(String strUrl)
Send a GET HTTP request to an Url and return the response content.
|
void |
downloadFile(String strUrl,
String strFilePath)
Send a GET HTTP request to an Url and return the response content.
|
String |
getFileName(String strUrl)
Send a GET HTTP request to an Url and return the response content.
|
public String doGet(String strUrl) throws HttpAccessException
strUrl - The Url to accessHttpAccessException - if there is a problem to access to the given Urlpublic String doGet(String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements) throws HttpAccessException
strUrl - The Url to accessauthenticator - The RequestAuthenticatorlistElements - to include in the signatureHttpAccessException - if there is a problem to access to the given Urlpublic String doGet(String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements, Map<String,String> headers) throws HttpAccessException
strUrl - The Url to accessauthenticator - The RequestAuthenticatorlistElements - to include in the signatureheadersRequest - Map of headers request parametersHttpAccessException - if there is a problem to access to the given Urlpublic String doGet(String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements, Map<String,String> headersRequest, Map<String,String> headersResponse) throws HttpAccessException
strUrl - The Url to accessauthenticator - The RequestAuthenticatorlistElements - to include in the signatureheadersRequest - Map of headers request parametersheadersResponse - Map to contain response headersHttpAccessException - if there is a problem to access to the given Urlpublic String doPost(String strUrl, Map<String,String> params) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postHttpAccessException - if there is a problem to access to the given Urlpublic String doPost(String strUrl, Map<String,String> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postauthenticator - The RequestAuthenticatorlistElements - to include in the signatureHttpAccessException - if there is a problem to access to the given Urlpublic String doPost(String strUrl, Map<String,String> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements, Map<String,String> headersRequest) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postauthenticator - The RequestAuthenticatorlistElements - to include in the signatureheadersRequest - Map of headers request parametersHttpAccessException - if there is a problem to access to the given Urlpublic String doPost(String strUrl, Map<String,String> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements, Map<String,String> headersRequest, Map<String,String> headersResponse) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postauthenticator - The RequestAuthenticatorlistElements - to include in the signatureheadersRequest - Map of headers request parametersheadersResponse - Map to contain response headersHttpAccessException - if there is a problem to access to the given Urlpublic String doPostMultiValues(String strUrl, Map<String,List<String>> params) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postHttpAccessException - if there is a problem to access to the given Urlpublic String doPostMultiValues(String strUrl, Map<String,List<String>> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postauthenticator - The RequestAuthenticatorlistElements - to include in the signatureHttpAccessException - if there is a problem to access to the given Urlpublic String doPostMultiValues(String strUrl, Map<String,List<String>> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements, Map<String,String> headersRequest) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postauthenticator - The RequestAuthenticatorlistElements - to include in the signatureheadersRequest - Map of headers request parametersHttpAccessException - if there is a problem to access to the given Urlpublic String doPostMultiValues(String strUrl, Map<String,List<String>> params, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements, Map<String,String> headersRequest, Map<String,String> headersResponse) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postauthenticator - The RequestAuthenticatorlistElements - to include in the signatureheadersRequest - Map of headers request parametersheadersResponse - Map to contain response headersHttpAccessException - if there is a problem to access to the given Urlpublic String doPostMultiPart(String strUrl, Map<String,List<String>> params, Map<String,org.apache.commons.fileupload.FileItem> fileItems) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postfileItems - The list of file itemsHttpAccessException - if there is a problem to access to the given Urlpublic String doPostMultiPart(String strUrl, Map<String,List<String>> params, Map<String,org.apache.commons.fileupload.FileItem> fileItems, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postfileItems - The list of file itemsauthenticator - The RequestAuthenticatorlistElements - to include in the signatureHttpAccessException - if there is a problem to access to the given Urlpublic String doPostMultiPart(String strUrl, Map<String,List<String>> params, Map<String,org.apache.commons.fileupload.FileItem> fileItems, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements, Map<String,String> headersRequest) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postfileItems - The list of file itemsauthenticator - The RequestAuthenticatorlistElements - to include in the signatureheadersRequest - Map of headers request parametersHttpAccessException - if there is a problem to access to the given Urlpublic String doPostMultiPart(String strUrl, Map<String,List<String>> params, Map<String,org.apache.commons.fileupload.FileItem> fileItems, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements, Map<String,String> headersRequest, Map<String,String> headersResponse) throws HttpAccessException
strUrl - the url to accessparams - the list of parameters to postfileItems - The list of file itemsauthenticator - The RequestAuthenticatorlistElements - to include in the signatureheadersRequest - Map of headers request parametersheadersResponse - Map to contain response headersHttpAccessException - if there is a problem to access to the given Urlpublic String doPut(String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements, Map<String,String> params, Map<String,String> headersRequest, Map<String,String> headersResponse) throws HttpAccessException
strUrl - the url to accessauthenticator - The RequestAuthenticatorlistElements - to include in the signatureheadersRequest - Map of headers request parametersheadersResponse - Map to contain response headersHttpAccessException - if there is a problem to access to the given Urlpublic String doDelete(String strUrl, fr.paris.lutece.util.signrequest.RequestAuthenticator authenticator, List<String> listElements, Map<String,String> headersRequest, Map<String,String> headersResponse) throws HttpAccessException
strUrl - the url to accessauthenticator - The RequestAuthenticatorlistElements - to include in the signatureheadersRequest - Map of headers request parametersheadersResponse - Map to contain response headersHttpAccessException - if there is a problem to access to the given Urlpublic void downloadFile(String strUrl, String strFilePath) throws HttpAccessException
strUrl - The Url to accessstrFilePath - the file pathHttpAccessException - if there is a problem to access to the given Urlpublic String getFileName(String strUrl) throws HttpAccessException
strUrl - The Url to accessHttpAccessException - if there is a problem to access to the given Urlpublic org.apache.commons.fileupload.FileItem downloadFile(String strUrl) throws HttpAccessException
strUrl - The Url to accessFileItemHttpAccessException - if there is a problem to access to the given UrlCopyright © 2015 City of Paris. All rights reserved.