public class RestHelper extends Object
| 限定符和类型 | 字段和说明 |
|---|---|
private org.springframework.web.client.RestTemplate |
restTemplate |
| 构造器和说明 |
|---|
RestHelper(org.springframework.web.client.RestTemplate restTemplate) |
| 限定符和类型 | 方法和说明 |
|---|---|
static RestHelper |
build(org.springframework.web.client.RestTemplate restTemplate) |
static <RES> RES |
getForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
Class<RES> resClass) |
static <RES> RES |
getForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
org.springframework.http.HttpHeaders headers,
Class<RES> resClass) |
static <RES> RES |
getForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
org.springframework.http.HttpHeaders headers,
org.springframework.core.ParameterizedTypeReference<RES> responseType) |
static <RES> RES |
getForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
org.springframework.core.ParameterizedTypeReference<RES> responseType) |
<RES> RES |
getForEntity(String url,
Class<RES> resClass) |
<RES> RES |
getForEntity(String url,
org.springframework.http.HttpHeaders headers,
Class<RES> resClass) |
<RES> RES |
getForEntity(String url,
org.springframework.http.HttpHeaders headers,
org.springframework.core.ParameterizedTypeReference<RES> responseType) |
<RES> RES |
getForEntity(String url,
org.springframework.core.ParameterizedTypeReference<RES> responseType) |
static String |
getForString(org.springframework.web.client.RestTemplate restTemplate,
String url) |
String |
getForString(String url) |
static <REQ,RES> RES |
postForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
REQ req,
Class<RES> resClass) |
static <REQ,RES> RES |
postForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
REQ req,
org.springframework.http.HttpHeaders headers,
Class<RES> resClass) |
static <REQ,RES> RES |
postForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
REQ req,
org.springframework.http.HttpHeaders headers,
org.springframework.core.ParameterizedTypeReference<RES> responseType) |
static <REQ,RES> RES |
postForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
REQ req,
org.springframework.core.ParameterizedTypeReference<RES> responseType) |
<REQ,RES> RES |
postForEntity(String url,
REQ req,
Class<RES> resClass) |
<REQ,RES> RES |
postForEntity(String url,
REQ req,
org.springframework.http.HttpHeaders headers,
Class<RES> resClass) |
<REQ,RES> RES |
postForEntity(String url,
REQ req,
org.springframework.http.HttpHeaders headers,
org.springframework.core.ParameterizedTypeReference<RES> responseType) |
<REQ,RES> RES |
postForEntity(String url,
REQ req,
org.springframework.core.ParameterizedTypeReference<RES> responseType) |
static <REQ> String |
postForString(org.springframework.web.client.RestTemplate restTemplate,
String url,
REQ req) |
<REQ> String |
postForString(String url,
REQ req) |
public static RestHelper build(org.springframework.web.client.RestTemplate restTemplate)
public <REQ,RES> RES postForEntity(String url, REQ req, org.springframework.http.HttpHeaders headers, Class<RES> resClass)
public <RES> RES getForEntity(String url, org.springframework.http.HttpHeaders headers, Class<RES> resClass)
public <REQ,RES> RES postForEntity(String url, REQ req, org.springframework.http.HttpHeaders headers, org.springframework.core.ParameterizedTypeReference<RES> responseType)
public <REQ,RES> RES postForEntity(String url, REQ req, org.springframework.core.ParameterizedTypeReference<RES> responseType)
public <RES> RES getForEntity(String url, org.springframework.http.HttpHeaders headers, org.springframework.core.ParameterizedTypeReference<RES> responseType)
public <RES> RES getForEntity(String url, org.springframework.core.ParameterizedTypeReference<RES> responseType)
public static <REQ,RES> RES postForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
REQ req,
org.springframework.http.HttpHeaders headers,
Class<RES> resClass)
public static <REQ,RES> RES postForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
REQ req,
Class<RES> resClass)
public static <REQ> String postForString(org.springframework.web.client.RestTemplate restTemplate, String url, REQ req)
public static <RES> RES getForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
org.springframework.http.HttpHeaders headers,
Class<RES> resClass)
public static <RES> RES getForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
Class<RES> resClass)
public static String getForString(org.springframework.web.client.RestTemplate restTemplate, String url)
public static <REQ,RES> RES postForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
REQ req,
org.springframework.http.HttpHeaders headers,
org.springframework.core.ParameterizedTypeReference<RES> responseType)
public static <REQ,RES> RES postForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
REQ req,
org.springframework.core.ParameterizedTypeReference<RES> responseType)
public static <RES> RES getForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
org.springframework.http.HttpHeaders headers,
org.springframework.core.ParameterizedTypeReference<RES> responseType)
public static <RES> RES getForEntity(org.springframework.web.client.RestTemplate restTemplate,
String url,
org.springframework.core.ParameterizedTypeReference<RES> responseType)
Copyright © 2024. All rights reserved.