public abstract class BaseWxCpCgServiceImpl<H,P> extends Object implements WxCpCgService, RequestHttp<H,P>
| 限定符和类型 | 字段和说明 | 
|---|---|
| protected WxCpCorpGroupConfigStorage | configStorageThe Config storage. | 
| 构造器和说明 | 
|---|
| BaseWxCpCgServiceImpl() | 
| 限定符和类型 | 方法和说明 | 
|---|---|
| <T,E> T | execute(RequestExecutor<T,E> executor,
       String uri,
       E data,
       boolean withoutCorpAccessToken,
       WxCpCorpGroupCorpGetTokenReq req)Execute t. | 
| <T,E> T | execute(RequestExecutor<T,E> executor,
       String uri,
       E data,
       WxCpCorpGroupCorpGetTokenReq req)向微信端发送请求,在这里执行的策略是当发生access_token过期时才去刷新,然后重新执行请求,而不是全局定时请求. | 
| protected <T,E> T | executeInternal(RequestExecutor<T,E> executor,
               String uri,
               E data,
               boolean withoutCorpAccessToken,
               WxCpCorpGroupCorpGetTokenReq req)Execute internal t. | 
| protected <T,E> T | executeInternal(RequestExecutor<T,E> executor,
               String uri,
               E data,
               WxCpCorpGroupCorpGetTokenReq req)Execute internal t. | 
| void | expireCorpAccessToken(String corpId,
                     Integer agentId)Expire access token. | 
| String | get(String url,
   String queryParam,
   boolean withoutCorpAccessToken,
   WxCpCorpGroupCorpGetTokenReq req)当本Service没有实现某个API的时候,可以用这个,针对所有微信API中的GET请求. | 
| String | get(String url,
   String queryParam,
   WxCpCorpGroupCorpGetTokenReq req)当本Service没有实现某个API的时候,可以用这个,针对所有微信API中的GET请求. | 
| String | getCorpAccessToken(String corpId,
                  Integer agentId,
                  Integer businessType) | 
| String | getCorpAccessToken(String corpId,
                  Integer agentId,
                  Integer businessType,
                  boolean forceRefresh) | 
| WxAccessToken | getCorpAccessTokenEntity(String corpId,
                        Integer agentId,
                        Integer businessType)授权企业的access token相关 | 
| WxAccessToken | getCorpAccessTokenEntity(String corpId,
                        Integer agentId,
                        Integer businessType,
                        boolean forceRefresh)Gets access token entity. | 
| WxCpMaTransferSession | getCorpTransferSession(String userId,
                      String sessionKey,
                      WxCpCorpGroupCorpGetTokenReq req)获取下级/下游企业小程序session
 https://developer.work.weixin.qq.com/document/path/93355 | 
| WxCpLinkedCorpService | getLinkedCorpService()互联企业的服务类对象 | 
| RequestHttp<?,?> | getRequestHttp()http请求对象. | 
| WxCpCorpGroupConfigStorage | getWxCpCorpGroupConfigStorage() | 
| boolean | isCorpAccessTokenExpired(String corpId,
                        Integer agentId)Is access token expired boolean. | 
| String | post(String url,
    String postData,
    boolean withoutCorpAccessToken,
    WxCpCorpGroupCorpGetTokenReq req)Post string. | 
| String | post(String url,
    String postData,
    WxCpCorpGroupCorpGetTokenReq req)当本Service没有实现某个API的时候,可以用这个,针对所有微信API中的POST请求. | 
| void | setMaxRetryTimes(int maxRetryTimes)
 设置当微信系统响应系统繁忙时,最大重试次数. | 
| void | setRetrySleepMillis(int retrySleepMillis)
 设置当微信系统响应系统繁忙时,要等待多少 retrySleepMillis(ms) * 2^(重试次数 - 1) 再发起重试. | 
| void | setWxCpCorpGroupConfigStorage(WxCpCorpGroupConfigStorage wxCpCorpGroupConfigStorage) | 
| void | setWxCpService(WxCpService wxCpService) | 
| void | updateCorpAccessToken(String corpId,
                     Integer agentId,
                     String corpAccessToken,
                     int expiresInSeconds)Update corp access token. | 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitinitHttpgetRequestHttpClient, getRequestHttpProxy, getRequestTypeprotected WxCpCorpGroupConfigStorage configStorage
public void updateCorpAccessToken(String corpId, Integer agentId, String corpAccessToken, int expiresInSeconds)
WxCpCgServiceupdateCorpAccessToken 在接口中 WxCpCgServicecorpId - .agentId - .corpAccessToken - the corp access tokenexpiresInSeconds - the expires in secondspublic String getCorpAccessToken(String corpId, Integer agentId, Integer businessType) throws WxErrorException
getCorpAccessToken 在接口中 WxCpCgServiceWxErrorExceptionpublic String getCorpAccessToken(String corpId, Integer agentId, Integer businessType, boolean forceRefresh) throws WxErrorException
getCorpAccessToken 在接口中 WxCpCgServiceWxErrorExceptionpublic WxAccessToken getCorpAccessTokenEntity(String corpId, Integer agentId, Integer businessType) throws WxErrorException
WxCpCgServicegetCorpAccessTokenEntity 在接口中 WxCpCgServicecorpId - the corp idWxErrorExceptionpublic WxAccessToken getCorpAccessTokenEntity(String corpId, Integer agentId, Integer businessType, boolean forceRefresh) throws WxErrorException
WxCpCgServicegetCorpAccessTokenEntity 在接口中 WxCpCgServicecorpId - the  corp idWxErrorExceptionpublic boolean isCorpAccessTokenExpired(String corpId, Integer agentId)
WxCpCgServiceisCorpAccessTokenExpired 在接口中 WxCpCgServicecorpId - the  corp idpublic void expireCorpAccessToken(String corpId, Integer agentId)
WxCpCgServiceexpireCorpAccessToken 在接口中 WxCpCgServicecorpId - the  corp idpublic String get(String url, String queryParam, WxCpCorpGroupCorpGetTokenReq req) throws WxErrorException
WxCpCgServiceget 在接口中 WxCpCgServiceurl - 接口地址queryParam - 请求参数WxErrorException - the wx error exceptionpublic String get(String url, String queryParam, boolean withoutCorpAccessToken, WxCpCorpGroupCorpGetTokenReq req) throws WxErrorException
WxCpCgServiceget 在接口中 WxCpCgServiceurl - 接口地址queryParam - 请求参数withoutCorpAccessToken - 请求是否忽略CorpAccessToken 默认不忽略-falseWxErrorException - the wx error exceptionpublic String post(String url, String postData, WxCpCorpGroupCorpGetTokenReq req) throws WxErrorException
WxCpCgServicepost 在接口中 WxCpCgServiceurl - 接口地址postData - 请求body字符串WxErrorException - the wx error exceptionpublic String post(String url, String postData, boolean withoutCorpAccessToken, WxCpCorpGroupCorpGetTokenReq req) throws WxErrorException
url - the urlpostData - the post datawithoutCorpAccessToken - the without Corp access tokenWxErrorException - the wx error exceptionpublic <T,E> T execute(RequestExecutor<T,E> executor, String uri, E data, WxCpCorpGroupCorpGetTokenReq req) throws WxErrorException
execute 在接口中 WxCpCgServiceT - 请求值类型E - 返回值类型executor - 执行器uri - 请求地址data - 参数WxErrorException - the wx error exceptionpublic <T,E> T execute(RequestExecutor<T,E> executor, String uri, E data, boolean withoutCorpAccessToken, WxCpCorpGroupCorpGetTokenReq req) throws WxErrorException
T - the type parameterE - the type parameterexecutor - the executoruri - the uridata - the datawithoutCorpAccessToken - the without Corp access tokenWxErrorException - the wx error exceptionprotected <T,E> T executeInternal(RequestExecutor<T,E> executor, String uri, E data, WxCpCorpGroupCorpGetTokenReq req) throws WxErrorException
T - the type parameterE - the type parameterexecutor - the executoruri - the uridata - the dataWxErrorException - the wx error exceptionprotected <T,E> T executeInternal(RequestExecutor<T,E> executor, String uri, E data, boolean withoutCorpAccessToken, WxCpCorpGroupCorpGetTokenReq req) throws WxErrorException
T - the type parameterE - the type parameterexecutor - the executoruri - the uridata - the datawithoutCorpAccessToken - the without Corp access tokenWxErrorException - the wx error exceptionpublic void setWxCpCorpGroupConfigStorage(WxCpCorpGroupConfigStorage wxCpCorpGroupConfigStorage)
setWxCpCorpGroupConfigStorage 在接口中 WxCpCgServicepublic WxCpCorpGroupConfigStorage getWxCpCorpGroupConfigStorage()
getWxCpCorpGroupConfigStorage 在接口中 WxCpCgServicepublic void setRetrySleepMillis(int retrySleepMillis)
WxCpCgService设置当微信系统响应系统繁忙时,要等待多少 retrySleepMillis(ms) * 2^(重试次数 - 1) 再发起重试. 默认:1000ms
setRetrySleepMillis 在接口中 WxCpCgServiceretrySleepMillis - 重试休息时间public void setMaxRetryTimes(int maxRetryTimes)
WxCpCgService设置当微信系统响应系统繁忙时,最大重试次数. 默认:5次
setMaxRetryTimes 在接口中 WxCpCgServicemaxRetryTimes - 最大重试次数public RequestHttp<?,?> getRequestHttp()
WxCpCgServicegetRequestHttp 在接口中 WxCpCgServicepublic void setWxCpService(WxCpService wxCpService)
setWxCpService 在接口中 WxCpCgServicepublic WxCpLinkedCorpService getLinkedCorpService()
WxCpCgServicegetLinkedCorpService 在接口中 WxCpCgServicepublic WxCpMaTransferSession getCorpTransferSession(String userId, String sessionKey, WxCpCorpGroupCorpGetTokenReq req) throws WxErrorException
WxCpCgServicegetCorpTransferSession 在接口中 WxCpCgServiceWxErrorExceptionCopyright © 2024. All rights reserved.