utils/src/network_util
library
Functions
-
checkVersion(String action, String baseUrl)
→ dynamic
-
-
delete({String? baseUrl, String path = '', dynamic data, Map<String, dynamic>? queryParameters, Duration? connectTimeout, BaseCancelToken? cancelToken, ProgressCallback? onSendProgress, ProgressCallback? onReceiveProgress, bool validResult = true, bool autoLoading = false})
→ Future<Result>
-
发送DELETE请求并解析远程服务器返回的result对应的实体类型
-
get({String? baseUrl, String path = '', Map<String, dynamic>? queryParameters, Duration? connectTimeout, BaseCancelToken? cancelToken, bool validResult = true, bool autoLoading = false})
→ Future<Result>
-
发送GET请求并解析远程服务器返回的result对应的实体类型
-
initSelectedBaseURLType()
→ Future<String?>
-
-
post({String? baseUrl, String path = '', dynamic data, Map<String, dynamic>? queryParameters, Duration? connectTimeout, BaseCancelToken? cancelToken, ProgressCallback? onSendProgress, ProgressCallback? onReceiveProgress, bool validResult = true, bool autoLoading = false})
→ Future<Result>
-
发送POST请求并解析远程服务器返回的result对应的实体类型
-
put({String? baseUrl, String path = '', dynamic data, Map<String, dynamic>? queryParameters, Duration? connectTimeout, BaseCancelToken? cancelToken, ProgressCallback? onSendProgress, ProgressCallback? onReceiveProgress, bool validResult = true, bool autoLoading = false})
→ Future<Result>
-
发送PUT请求并解析远程服务器返回的result对应的实体类型
-
request({String? baseUrl, String path = '', dynamic data, Map<String, dynamic>? queryParameters, BaseCancelToken? cancelToken, Options? options, Duration? connectTimeout, ProgressCallback? onSendProgress, ProgressCallback? onReceiveProgress, bool validResult = true, bool autoLoading = false})
→ Future<Result>
-
发送请求并解析远程服务器返回的result对应的实体类型
-
saveBaseURLType(BaseURLType urlType)
→ Future<bool>
-
保存选择的环境
-
showSelectBaseURLTypeAlert({BuildContext? context})
→ Future<bool?>
-
弹出切换环境菜单
-
uploadOSSFile({required String filepath, required String policy, required String accessKeyId, required String signature, required String key, required String host, String successActionStatus = "204", Duration connectTimeout = const Duration(seconds: 60), BaseCancelToken? cancelToken, ProgressCallback? onSendProgress})
→ Future<Result>
-
上传文件