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() |
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 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 |
getAppServerUrl() |
String |
getPassword() |
ResponseJSON |
getResponseData(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpGetUrl) |
ResponseJSON |
getResponseData(org.apache.http.impl.client.CloseableHttpClient httpClient,
String httpGetUrl,
Map<String,Object> queryParam) |
ResponseJSON |
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 |
releaseHttpClient(org.apache.http.impl.client.CloseableHttpClient httpClient) |
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 boolean checkAccessToken(org.apache.http.impl.client.CloseableHttpClient httpclient)
throws org.apache.http.client.ClientProtocolException,
ObjectException,
IOException
org.apache.http.client.ClientProtocolExceptionObjectExceptionIOExceptionpublic void askAccessToken(org.apache.http.impl.client.CloseableHttpClient httpclient)
throws org.apache.http.client.ClientProtocolException,
IOException,
ObjectException
org.apache.http.client.ClientProtocolExceptionIOExceptionObjectExceptionpublic org.apache.http.impl.client.CloseableHttpClient allocHttpClient()
throws Exception
Exceptionpublic com.centit.support.network.HttpExecutorContext createHttpExecutorContext(org.apache.http.impl.client.CloseableHttpClient httpClient)
public com.centit.support.network.HttpExecutorContext createHttpExecutorContext()
throws Exception
Exceptionpublic 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 ResponseJSON getResponseData(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpGetUrl, String queryParam) throws IOException
IOExceptionpublic ResponseJSON getResponseData(org.apache.http.impl.client.CloseableHttpClient httpClient, String httpGetUrl, Map<String,Object> queryParam) throws IOException
IOExceptionpublic ResponseJSON 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, String 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)
Copyright © 2018 江苏南大先腾信息产业股份有限公司. All rights reserved.