public class WxMaServiceImpl extends WxMaServiceAbstractImpl<org.apache.http.impl.client.CloseableHttpClient,org.apache.http.HttpHost>
logGET_ACCESS_TOKEN_URL| 构造器和说明 |
|---|
WxMaServiceImpl() |
| 限定符和类型 | 方法和说明 |
|---|---|
String |
getAccessToken(boolean forceRefresh)
获取access_token,本方法线程安全
且在多线程同时刷新时只刷新一次,避免超出2000次/日的调用次数上限
另:本service的所有方法都会在access_token过期是调用此方法
程序员在非必要情况下尽量不要主动调用此方法
详情请见: http://mp.weixin.qq.com/wiki?
|
RequestHttp |
getRequestHttp() |
org.apache.http.impl.client.CloseableHttpClient |
getRequestHttpClient() |
org.apache.http.HttpHost |
getRequestHttpProxy() |
HttpType |
getRequestType() |
void |
initHttp()
初始化http请求对象
|
checkSignature, execute, executeInternal, get, getAccessToken, getMediaService, getMsgService, getQrcodeService, getUserService, getWxMaConfig, post, setMaxRetryTimes, setRetrySleepMillis, setWxMaConfigpublic org.apache.http.impl.client.CloseableHttpClient getRequestHttpClient()
public org.apache.http.HttpHost getRequestHttpProxy()
public HttpType getRequestType()
public void initHttp()
WxMaServicepublic RequestHttp getRequestHttp()
public String getAccessToken(boolean forceRefresh) throws WxErrorException
WxMaService获取access_token,本方法线程安全 且在多线程同时刷新时只刷新一次,避免超出2000次/日的调用次数上限 另:本service的所有方法都会在access_token过期是调用此方法 程序员在非必要情况下尽量不要主动调用此方法 详情请见: http://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140183&token=&lang=zh_CN
forceRefresh - 强制刷新WxErrorExceptionCopyright © 2017. All rights reserved.