类 RestClientV2
- java.lang.Object
-
- tech.testnx.cah.common.ws.AbstractRestClient
-
- tech.testnx.cah.common.ws.RestClientV2
-
- 所有已实现的接口:
AutoCloseable,HandleWsV2
public class RestClientV2 extends AbstractRestClient implements HandleWsV2
- 作者:
- Yun
-
-
字段概要
-
从类继承的字段 tech.testnx.cah.common.ws.AbstractRestClient
logger
-
-
构造器概要
构造器 构造器 说明 RestClientV2()RestClientV2(Map<String,String> headers, Map<String,String> cookies)
-
方法概要
-
从类继承的方法 tech.testnx.cah.common.ws.AbstractRestClient
checkResponseStatus, createClient, initializeInvoker
-
-
-
-
方法详细资料
-
newInstance
public static RestClientV2 newInstance()
-
newInstance
public static RestClientV2 newInstance(Map<String,String> headers, Map<String,String> cookies)
-
setHeaders
public RestClientV2 setHeaders(Map<String,String> headers)
-
setCookies
public RestClientV2 setCookies(Map<String,String> cookies)
-
getClient
protected javax.ws.rs.client.Client getClient()
- 指定者:
getClient在类中AbstractRestClient
-
registerListener
public RestClientV2 registerListener(RestClientListener listener)
- 指定者:
registerListener在接口中HandleWsV2
-
unregisterListener
public RestClientV2 unregisterListener(RestClientListener listener)
- 指定者:
unregisterListener在接口中HandleWsV2
-
doGet
public RestfulResponse doGet(String wsUrl, Map<String,String> headers, Map<String,String> cookies, Map<String,String> parameters)
- 指定者:
doGet在接口中HandleWsV2
-
doPost
public <T> RestfulResponse doPost(String wsUrl, Map<String,String> headers, Map<String,String> cookies, Map<String,String> parameters, T body)
- 指定者:
doPost在接口中HandleWsV2
-
doPut
public <T> RestfulResponse doPut(String wsUrl, Map<String,String> headers, Map<String,String> cookies, Map<String,String> parameters, T body)
- 指定者:
doPut在接口中HandleWsV2
-
doPatch
public <T> RestfulResponse doPatch(String wsUrl, Map<String,String> headers, Map<String,String> cookies, Map<String,String> parameters, T body)
- 指定者:
doPatch在接口中HandleWsV2
-
doDelete
public RestfulResponse doDelete(String wsUrl, Map<String,String> headers, Map<String,String> cookies, Map<String,String> parameters)
- 指定者:
doDelete在接口中HandleWsV2
-
close
public void close()
- 指定者:
close在接口中AutoCloseable
-
doGet
public RestfulResponse doGet(String wsUrl, Map<String,String> parameters)
- 指定者:
doGet在接口中HandleWsV2
-
doPost
public <T> RestfulResponse doPost(String wsUrl, Map<String,String> parameters, T body)
- 指定者:
doPost在接口中HandleWsV2
-
doPut
public <T> RestfulResponse doPut(String wsUrl, Map<String,String> parameters, T body)
- 指定者:
doPut在接口中HandleWsV2
-
doPatch
public <T> RestfulResponse doPatch(String wsUrl, Map<String,String> parameters, T body)
- 指定者:
doPatch在接口中HandleWsV2
-
doDelete
public RestfulResponse doDelete(String wsUrl, Map<String,String> parameters)
- 指定者:
doDelete在接口中HandleWsV2
-
-