refactor: reply2reply [wip]

refactor: reply
This commit is contained in:
bggRGjQaUbCoE
2024-10-11 09:43:17 +08:00
parent 7b6e302e89
commit 39a63cf5ce
11 changed files with 11442 additions and 79 deletions

View File

@@ -1,3 +1,4 @@
import 'package:PiliPalaX/grpc/app/main/community/reply/v1/reply.pbgrpc.dart';
import 'package:PiliPalaX/grpc/app/playeronline/v1/playeronline.pbgrpc.dart';
import 'package:PiliPalaX/grpc/app/show/popular/v1/popular.pbgrpc.dart';
import 'package:grpc/grpc.dart';
@@ -6,6 +7,7 @@ class GrpcClient {
ClientChannel? _channel;
PlayerOnlineClient? _playerOnlineClient;
PopularClient? _popularClient;
ReplyClient? _replyClient;
GrpcClient._internal() {
_channel = ClientChannel(
@@ -30,6 +32,11 @@ class GrpcClient {
return _popularClient!;
}
ReplyClient get replyClient {
_replyClient ??= ReplyClient(_channel!);
return _replyClient!;
}
Future<void> shutdown() async {
await _channel?.shutdown();
}