public class AppSession extends Object
| 限定符和类型 | 字段和说明 |
|---|---|
static String |
SECURITY_CONTEXT_TOKENNAME |
| 构造器和说明 |
|---|
AppSession() |
AppSession(String appServerUrl) |
AppSession(String appServerUrl,
boolean needAuthenticated,
String userCode,
String password) |
AppSession(String appServerUrl,
String userCode,
String password) |
| 限定符和类型 | 方法和说明 |
|---|---|
org.apache.http.impl.client.CloseableHttpClient |
allocHttpClient() |
void |
askAccessToken(org.apache.http.impl.client.CloseableHttpClient httpclient) |
boolean |
checkAccessToken(org.apache.http.impl.client.CloseableHttpClient httpclient) |
String |
completeQueryUrl(String queryUrl) |
com.centit.support.network.HttpExecutorContext |
createHttpExecutorContext(org.apache.http.impl.client.CloseableHttpClient httpClient) |
String |
doDelete(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpDeleteUrl) |
String |
doDelete(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpDeleteUrl,
Map<String,Object> queryParam) |
String |
formPost(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpPostUrl,
Object formData) |
String |
formPost(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpPostUrl,
Object formData,
boolean asPut) |
String |
formPut(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpPutUrl,
Object formData) |
String |
getAppLoginUrl() |
String |
getAppServerUrl() |
String |
getPassword() |
HttpReceiveJSON |
getResponseData(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpGetUrl) |
HttpReceiveJSON |
getResponseData(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpGetUrl,
Map<String,Object> queryParam) |
HttpReceiveJSON |
getResponseData(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpGetUrl,
String queryParam) |
String |
getUserCode() |
boolean |
isNeedAuthenticated() |
String |
jsonPost(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpPostUrl,
Object formData) |
String |
jsonPost(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpPostUrl,
Object formData,
boolean asPut) |
String |
jsonPut(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpPutUrl,
Object formData) |
void |
registerInterceptor(Consumer<com.centit.support.network.HttpExecutorContext> httpInterceptor) |
void |
releaseHttpClient(org.apache.http.impl.client.CloseableHttpClient httpClient) |
void |
setAppLoginUrl(String appLoginUrl) |
void |
setAppServerUrl(String appServerUrl) |
void |
setNeedAuthenticated(boolean needAuthenticated) |
void |
setPassword(String password) |
void |
setUserCode(String userCode) |
String |
simpleGet(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpGetUrl) |
String |
simpleGet(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpGetUrl,
Map<String,Object> queryParam) |
public AppSession(String appServerUrl, boolean needAuthenticated, String userCode, String password)
public AppSession(String appServerUrl)
public AppSession()
public void registerInterceptor(Consumer<com.centit.support.network.HttpExecutorContext> httpInterceptor)
public boolean checkAccessToken(org.apache.http.impl.client.CloseableHttpClient httpclient)
throws com.centit.support.common.ObjectException,
IOException
com.centit.support.common.ObjectExceptionIOExceptionpublic void askAccessToken(org.apache.http.impl.client.CloseableHttpClient httpclient)
throws IOException,
com.centit.support.common.ObjectException
IOExceptioncom.centit.support.common.ObjectExceptionpublic org.apache.http.impl.client.CloseableHttpClient allocHttpClient()
throws Exception
Exceptionpublic com.centit.support.network.HttpExecutorContext createHttpExecutorContext(org.apache.http.impl.client.CloseableHttpClient httpClient)
public void releaseHttpClient(org.apache.http.impl.client.CloseableHttpClient httpClient)
public String simpleGet(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpGetUrl, Map<String,Object> queryParam) throws IOException
IOExceptionpublic String simpleGet(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpGetUrl) throws IOException
IOExceptionpublic HttpReceiveJSON getResponseData(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpGetUrl, String queryParam) throws IOException
IOExceptionpublic HttpReceiveJSON getResponseData(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpGetUrl, Map<String,Object> queryParam) throws IOException
IOExceptionpublic HttpReceiveJSON getResponseData(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpGetUrl) throws IOException
IOExceptionpublic String formPost(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpPostUrl, Object formData, boolean asPut) throws IOException
IOExceptionpublic String formPost(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpPostUrl, Object formData) throws IOException
IOExceptionpublic String formPut(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpPutUrl, Object formData) throws IOException
IOExceptionpublic String jsonPost(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpPostUrl, Object formData, boolean asPut) throws IOException
IOExceptionpublic String jsonPost(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpPostUrl, Object formData) throws IOException
IOExceptionpublic String jsonPut(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpPutUrl, Object formData) throws IOException
IOExceptionpublic String doDelete(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpDeleteUrl) throws IOException
IOExceptionpublic String doDelete(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpDeleteUrl, Map<String,Object> queryParam) throws IOException
IOExceptionpublic String getAppServerUrl()
public void setAppServerUrl(String appServerUrl)
public String getUserCode()
public void setUserCode(String userCode)
public String getPassword()
public void setPassword(String password)
public boolean isNeedAuthenticated()
public void setNeedAuthenticated(boolean needAuthenticated)
public String getAppLoginUrl()
public void setAppLoginUrl(String appLoginUrl)
Copyright © 2021 江苏南大先腾信息产业股份有限公司. All rights reserved.