1234567891011121314151617181920212223242526272829303132 |
- import 'dart:core';
- import 'package:fis_jsonrpc/client_base.dart';
- import 'package:fis_common/json_convert.dart';
- import 'deployPlatform.m.dart';
- class DeployPlatformService extends JsonRpcClientBase {
- DeployPlatformService(
- String host, {
- String serviceName = "IDeployPlatformService",
- Map<String, String>? headers,
- int? timeout,
- }) : super(
- host,
- serviceName,
- headers: headers,
- timeout: timeout,
- ) {
- /// 注册响应实体反序列化处理器
- FJsonConvert.setDecoder((map) => DeployPlatServerInfoDTO.fromJson(map));
- }
- Future<List<DeployPlatServerInfoDTO>> getServerListAsync() async {
- var rpcRst = await call("GetServerListAsync", );
- var result = (rpcRst as List).map((e)=>DeployPlatServerInfoDTO.fromJson(e as Map<String, dynamic>)).toList();
- return result;
- }
- }
|