public class RemoteVersion extends BaseJsonModel
{ "tag_name": "v2.6.4", "agentUrl": "", "serverUrl": "", "changelog": "" }
Constructor and Description |
---|
RemoteVersion() |
Modifier and Type | Method and Description |
---|---|
static RemoteVersion |
cacheInfo()
当前缓存中的 远程版本信息
|
static cn.hutool.core.lang.Tuple |
download(String savePath,
Type type)
下载
|
static cn.hutool.core.lang.Tuple |
download(String savePath,
Type type,
boolean checkRepeat)
下载
|
static RemoteVersion |
loadRemoteInfo()
获取远程最新版本
|
String |
toString() |
static void |
upgrade(String savePath)
升级
|
static void |
upgrade(String savePath,
Consumer<cn.hutool.core.lang.Tuple> consumer)
升级
|
toJson
public String toString()
toString
in class BaseJsonModel
public static RemoteVersion loadRemoteInfo()
public static RemoteVersion cacheInfo()
public static cn.hutool.core.lang.Tuple download(String savePath, Type type, boolean checkRepeat) throws IOException
savePath
- 下载文件保存路径type
- 类型checkRepeat
- 是否验证重复IOException
- 异常public static cn.hutool.core.lang.Tuple download(String savePath, Type type) throws IOException
savePath
- 下载文件保存路径type
- 类型IOException
- 异常public static void upgrade(String savePath) throws IOException
savePath
- 下载文件保存路径IOException
- 异常public static void upgrade(String savePath, Consumer<cn.hutool.core.lang.Tuple> consumer) throws IOException
savePath
- 下载文件保存路径consumer
- 执行申请前回调IOException
- 异常Copyright © 2017–2022. All rights reserved.