public class WxCpDefaultConfigImpl extends java.lang.Object implements WxCpConfigStorage, java.io.Serializable
限定符和类型 | 字段和说明 |
---|---|
protected java.lang.String |
accessToken
The Access token.
|
protected java.util.concurrent.locks.Lock |
accessTokenLock
The Access token lock.
|
protected java.lang.Integer |
agentId
The Agent id.
|
protected java.util.concurrent.locks.Lock |
agentJsapiTicketLock
The Agent jsapi ticket lock.
|
protected java.util.concurrent.locks.Lock |
jsapiTicketLock
The Jsapi ticket lock.
|
构造器和说明 |
---|
WxCpDefaultConfigImpl() |
限定符和类型 | 方法和说明 |
---|---|
boolean |
autoRefreshToken()
是否自动刷新token
|
void |
expireAccessToken()
强制将access token过期掉.
|
void |
expireAgentJsapiTicket()
强制将jsapi ticket过期掉.
|
void |
expireJsapiTicket()
强制将jsapi ticket过期掉.
|
java.lang.String |
getAccessToken()
Gets access token.
|
java.util.concurrent.locks.Lock |
getAccessTokenLock()
Gets access token lock.
|
java.lang.String |
getAesKey()
Gets aes key.
|
java.lang.Integer |
getAgentId()
Gets agent id.
|
java.lang.String |
getAgentJsapiTicket()
Gets agent jsapi ticket.
|
java.util.concurrent.locks.Lock |
getAgentJsapiTicketLock()
Gets agent jsapi ticket lock.
|
me.chanjar.weixin.common.util.http.apache.ApacheHttpClientBuilder |
getApacheHttpClientBuilder()
http client builder.
|
java.lang.String |
getApiUrl(java.lang.String path)
读取企业微信 API Url.
|
java.lang.String |
getCorpId()
Gets corp id.
|
java.lang.String |
getCorpSecret()
Gets corp secret.
|
long |
getExpiresTime()
Gets expires time.
|
java.lang.String |
getHttpProxyHost()
Gets http proxy host.
|
java.lang.String |
getHttpProxyPassword()
Gets http proxy password.
|
int |
getHttpProxyPort()
Gets http proxy port.
|
java.lang.String |
getHttpProxyUsername()
Gets http proxy username.
|
java.lang.String |
getJsapiTicket()
Gets jsapi ticket.
|
long |
getJsapiTicketExpiresTime()
Gets jsapi ticket expires time.
|
java.util.concurrent.locks.Lock |
getJsapiTicketLock()
Gets jsapi ticket lock.
|
java.lang.String |
getMsgAuditLibPath()
获取企微会话存档系统库 绝对路径
|
java.lang.String |
getOauth2redirectUri()
Gets oauth 2 redirect uri.
|
java.io.File |
getTmpDirFile()
Gets tmp dir file.
|
java.lang.String |
getToken()
Gets token.
|
java.lang.String |
getWebhookKey()
获取群机器人webhook的key
|
boolean |
isAccessTokenExpired()
Is access token expired boolean.
|
boolean |
isAgentJsapiTicketExpired()
Is agent jsapi ticket expired boolean.
|
boolean |
isJsapiTicketExpired()
Is jsapi ticket expired boolean.
|
void |
setAccessToken(java.lang.String accessToken)
Sets access token.
|
void |
setAesKey(java.lang.String aesKey)
Sets aes key.
|
void |
setAgentId(java.lang.Integer agentId)
Sets agent id.
|
void |
setApacheHttpClientBuilder(me.chanjar.weixin.common.util.http.apache.ApacheHttpClientBuilder apacheHttpClientBuilder)
Sets apache http client builder.
|
void |
setBaseApiUrl(java.lang.String baseUrl)
设置企业微信服务器 baseUrl.
|
void |
setCorpId(java.lang.String corpId)
Sets corp id.
|
void |
setCorpSecret(java.lang.String corpSecret)
Sets corp secret.
|
void |
setExpiresTime(long expiresTime)
Sets expires time.
|
void |
setHttpProxyHost(java.lang.String httpProxyHost)
Sets http proxy host.
|
void |
setHttpProxyPassword(java.lang.String httpProxyPassword)
Sets http proxy password.
|
void |
setHttpProxyPort(int httpProxyPort)
Sets http proxy port.
|
void |
setHttpProxyUsername(java.lang.String httpProxyUsername)
Sets http proxy username.
|
void |
setJsapiTicket(java.lang.String jsapiTicket)
Sets jsapi ticket.
|
void |
setJsapiTicketExpiresTime(long jsapiTicketExpiresTime)
Sets jsapi ticket expires time.
|
void |
setMsgAuditLibPath(java.lang.String msgAuditLibPath)
设置企微会话存档路径.
|
void |
setOauth2redirectUri(java.lang.String oauth2redirectUri)
Sets oauth 2 redirect uri.
|
void |
setTmpDirFile(java.io.File tmpDirFile)
Sets tmp dir file.
|
void |
setToken(java.lang.String token)
Sets token.
|
WxCpDefaultConfigImpl |
setWebhookKey(java.lang.String webhookKey)
Sets webhook key.
|
java.lang.String |
toString() |
void |
updateAccessToken(java.lang.String accessToken,
int expiresInSeconds)
Update access token.
|
void |
updateAccessToken(me.chanjar.weixin.common.bean.WxAccessToken accessToken)
Update access token.
|
void |
updateAgentJsapiTicket(java.lang.String jsapiTicket,
int expiresInSeconds)
应该是线程安全的.
|
void |
updateJsapiTicket(java.lang.String jsapiTicket,
int expiresInSeconds)
应该是线程安全的.
|
protected volatile java.lang.String accessToken
protected transient java.util.concurrent.locks.Lock accessTokenLock
protected volatile java.lang.Integer agentId
protected transient java.util.concurrent.locks.Lock jsapiTicketLock
protected transient java.util.concurrent.locks.Lock agentJsapiTicketLock
public void setBaseApiUrl(java.lang.String baseUrl)
WxCpConfigStorage
setBaseApiUrl
在接口中 WxCpConfigStorage
baseUrl
- 企业微信服务器 Urlpublic java.lang.String getApiUrl(java.lang.String path)
WxCpConfigStorage
getApiUrl
在接口中 WxCpConfigStorage
path
- the pathpublic java.lang.String getAccessToken()
WxCpConfigStorage
getAccessToken
在接口中 WxCpConfigStorage
public void setAccessToken(java.lang.String accessToken)
accessToken
- the access tokenpublic java.util.concurrent.locks.Lock getAccessTokenLock()
WxCpConfigStorage
getAccessTokenLock
在接口中 WxCpConfigStorage
public boolean isAccessTokenExpired()
WxCpConfigStorage
isAccessTokenExpired
在接口中 WxCpConfigStorage
public void expireAccessToken()
WxCpConfigStorage
expireAccessToken
在接口中 WxCpConfigStorage
public void updateAccessToken(me.chanjar.weixin.common.bean.WxAccessToken accessToken)
WxCpConfigStorage
updateAccessToken
在接口中 WxCpConfigStorage
accessToken
- the access tokenpublic void updateAccessToken(java.lang.String accessToken, int expiresInSeconds)
WxCpConfigStorage
updateAccessToken
在接口中 WxCpConfigStorage
accessToken
- the access tokenexpiresInSeconds
- the expires inpublic java.lang.String getJsapiTicket()
WxCpConfigStorage
getJsapiTicket
在接口中 WxCpConfigStorage
public void setJsapiTicket(java.lang.String jsapiTicket)
jsapiTicket
- the jsapi ticketpublic java.util.concurrent.locks.Lock getJsapiTicketLock()
WxCpConfigStorage
getJsapiTicketLock
在接口中 WxCpConfigStorage
public long getJsapiTicketExpiresTime()
public void setJsapiTicketExpiresTime(long jsapiTicketExpiresTime)
jsapiTicketExpiresTime
- the jsapi ticket expires timepublic boolean isJsapiTicketExpired()
WxCpConfigStorage
isJsapiTicketExpired
在接口中 WxCpConfigStorage
public void updateJsapiTicket(java.lang.String jsapiTicket, int expiresInSeconds)
WxCpConfigStorage
updateJsapiTicket
在接口中 WxCpConfigStorage
jsapiTicket
- the jsapi ticketexpiresInSeconds
- the expires in secondspublic java.lang.String getAgentJsapiTicket()
WxCpConfigStorage
getAgentJsapiTicket
在接口中 WxCpConfigStorage
public java.util.concurrent.locks.Lock getAgentJsapiTicketLock()
WxCpConfigStorage
getAgentJsapiTicketLock
在接口中 WxCpConfigStorage
public boolean isAgentJsapiTicketExpired()
WxCpConfigStorage
isAgentJsapiTicketExpired
在接口中 WxCpConfigStorage
public void expireAgentJsapiTicket()
WxCpConfigStorage
expireAgentJsapiTicket
在接口中 WxCpConfigStorage
public void updateAgentJsapiTicket(java.lang.String jsapiTicket, int expiresInSeconds)
WxCpConfigStorage
updateAgentJsapiTicket
在接口中 WxCpConfigStorage
jsapiTicket
- the jsapi ticketexpiresInSeconds
- the expires in secondspublic void expireJsapiTicket()
WxCpConfigStorage
expireJsapiTicket
在接口中 WxCpConfigStorage
public java.lang.String getCorpId()
WxCpConfigStorage
getCorpId
在接口中 WxCpConfigStorage
public void setCorpId(java.lang.String corpId)
corpId
- the corp idpublic java.lang.String getCorpSecret()
WxCpConfigStorage
getCorpSecret
在接口中 WxCpConfigStorage
public void setCorpSecret(java.lang.String corpSecret)
corpSecret
- the corp secretpublic java.lang.String getToken()
WxCpConfigStorage
getToken
在接口中 WxCpConfigStorage
public void setToken(java.lang.String token)
token
- the tokenpublic long getExpiresTime()
WxCpConfigStorage
getExpiresTime
在接口中 WxCpConfigStorage
public void setExpiresTime(long expiresTime)
expiresTime
- the expires timepublic java.lang.String getAesKey()
WxCpConfigStorage
getAesKey
在接口中 WxCpConfigStorage
public java.lang.String getMsgAuditLibPath()
WxCpConfigStorage
getMsgAuditLibPath
在接口中 WxCpConfigStorage
public void setAesKey(java.lang.String aesKey)
aesKey
- the aes keypublic java.lang.Integer getAgentId()
WxCpConfigStorage
getAgentId
在接口中 WxCpConfigStorage
public void setAgentId(java.lang.Integer agentId)
agentId
- the agent idpublic void setMsgAuditLibPath(java.lang.String msgAuditLibPath)
msgAuditLibPath
- 会话存档具体路径public java.lang.String getOauth2redirectUri()
WxCpConfigStorage
getOauth2redirectUri
在接口中 WxCpConfigStorage
public void setOauth2redirectUri(java.lang.String oauth2redirectUri)
oauth2redirectUri
- the oauth 2 redirect uripublic java.lang.String getHttpProxyHost()
WxCpConfigStorage
getHttpProxyHost
在接口中 WxCpConfigStorage
public void setHttpProxyHost(java.lang.String httpProxyHost)
httpProxyHost
- the http proxy hostpublic int getHttpProxyPort()
WxCpConfigStorage
getHttpProxyPort
在接口中 WxCpConfigStorage
public void setHttpProxyPort(int httpProxyPort)
httpProxyPort
- the http proxy portpublic java.lang.String getHttpProxyUsername()
WxCpConfigStorage
getHttpProxyUsername
在接口中 WxCpConfigStorage
public void setHttpProxyUsername(java.lang.String httpProxyUsername)
httpProxyUsername
- the http proxy usernamepublic java.lang.String getHttpProxyPassword()
WxCpConfigStorage
getHttpProxyPassword
在接口中 WxCpConfigStorage
public void setHttpProxyPassword(java.lang.String httpProxyPassword)
httpProxyPassword
- the http proxy passwordpublic java.lang.String toString()
toString
在类中 java.lang.Object
public java.io.File getTmpDirFile()
WxCpConfigStorage
getTmpDirFile
在接口中 WxCpConfigStorage
public void setTmpDirFile(java.io.File tmpDirFile)
tmpDirFile
- the tmp dir filepublic me.chanjar.weixin.common.util.http.apache.ApacheHttpClientBuilder getApacheHttpClientBuilder()
WxCpConfigStorage
getApacheHttpClientBuilder
在接口中 WxCpConfigStorage
public void setApacheHttpClientBuilder(me.chanjar.weixin.common.util.http.apache.ApacheHttpClientBuilder apacheHttpClientBuilder)
apacheHttpClientBuilder
- the apache http client builderpublic boolean autoRefreshToken()
WxCpConfigStorage
autoRefreshToken
在接口中 WxCpConfigStorage
public java.lang.String getWebhookKey()
WxCpConfigStorage
getWebhookKey
在接口中 WxCpConfigStorage
public WxCpDefaultConfigImpl setWebhookKey(java.lang.String webhookKey)
webhookKey
- the webhook key