Package cn.toint.jdy4j.core.client
Interface JdyClient
- All Superinterfaces:
AutoCloseable
- All Known Implementing Classes:
JdyClientImpl
简道云客户端
- Author:
- Toint
-
Method Summary
Modifier and TypeMethodDescriptionbooleancontainsJdyConfigStorage(String corpName) 是否存在简道云配置voiddeleteJdyConfigStorage(String corpName) 删除配置default <R> R执行方法default <R> RexecThenAutoClose(Function<JdyClient, R> function) 执行方法后自动关闭资源default <R> RexecThenNotAutoClose(Function<JdyClient, R> function) 执行方法后不自动关闭资源static JdyClientget()获取简道云客户端static JdyClient获取简道云客户端, 并且切换企业上下文环境简道云应用简道云数据简道云文件putJdyConfigStorage(JdyConfigStorage jdyConfigStorage) 覆盖简道云配置default JdyConfigStorageregisterJdyConfigStorage(JdyConfigStorage jdyConfigStorage) 注册简道云配置booleanswitchover(String corpName) 切换简道云配置switchoverTo(String corpName) 切换简道云配置Methods inherited from interface java.lang.AutoCloseable
close
-
Method Details
-
get
获取简道云客户端- Returns:
- 简道云客户端
- Throws:
RuntimeException- 无法获取到简道云客户端
-
get
获取简道云客户端, 并且切换企业上下文环境- Parameters:
corpName- 企业名称- Returns:
- 简道云客户端
- Throws:
RuntimeException- 无法获取到简道云客户端
-
exec
执行方法- Parameters:
function- 执行方法autoClose- 是否自动关闭资源- Returns:
- result
-
execThenAutoClose
执行方法后自动关闭资源- Parameters:
function- 执行方法- Returns:
- result
-
execThenNotAutoClose
执行方法后不自动关闭资源- Parameters:
function- 执行方法- Returns:
- result
-
registerJdyConfigStorage
注册简道云配置- Parameters:
jdyConfigStorage- 简道云配置- Returns:
- 简道云配置
-
putJdyConfigStorage
覆盖简道云配置- Parameters:
jdyConfigStorage- 简道云配置- Returns:
- 简道云配置
-
containsJdyConfigStorage
是否存在简道云配置- Parameters:
corpName- 企业名称- Returns:
- 是否已存在
-
deleteJdyConfigStorage
删除配置- Parameters:
corpName- 企业名称
-
switchover
切换简道云配置- Parameters:
corpName- 企业名称- Returns:
- 切换状态
-
switchoverTo
切换简道云配置- Parameters:
corpName- 企业名称- Returns:
- 简道云客户端
- Throws:
RuntimeException- 切换失败
-
getJdyAppService
JdyAppService getJdyAppService()简道云应用 -
getJdyDataService
JdyDataService getJdyDataService()简道云数据 -
getJdyFileService
JdyFileService getJdyFileService()简道云文件
-