client/dart/feed/tag.pbgrpc.dart

129 lines
3.9 KiB
Dart

// This is a generated file - do not edit.
//
// Generated from tag.proto.
// @dart = 3.3
// ignore_for_file: annotate_overrides, camel_case_types, comment_references
// ignore_for_file: constant_identifier_names
// ignore_for_file: curly_braces_in_flow_control_structures
// ignore_for_file: deprecated_member_use_from_same_package, library_prefixes
// ignore_for_file: non_constant_identifier_names
import 'dart:async' as $async;
import 'dart:core' as $core;
import 'package:grpc/service_api.dart' as $grpc;
import 'package:protobuf/protobuf.dart' as $pb;
import 'blocks.pb.dart' as $0;
import 'tag.pb.dart' as $1;
export 'tag.pb.dart';
@$pb.GrpcServiceName('feed.Tag')
class TagClient extends $grpc.Client {
/// The hostname for this service.
static const $core.String defaultHost = '';
/// OAuth scopes needed for the client.
static const $core.List<$core.String> oauthScopes = [
'',
];
TagClient(super.channel, {super.options, super.interceptors});
/// 标签列表
$grpc.ResponseFuture<$1.TagListReply> list(
$0.FetchRequest request, {
$grpc.CallOptions? options,
}) {
return $createUnaryCall(_$list, request, options: options);
}
/// 新建标签
$grpc.ResponseFuture<$0.StatusReply> create(
$1.AddTagRequest request, {
$grpc.CallOptions? options,
}) {
return $createUnaryCall(_$create, request, options: options);
}
/// 话题相关的文章
$grpc.ResponseFuture<$0.PostListReply> postList(
$0.FetchRequest request, {
$grpc.CallOptions? options,
}) {
return $createUnaryCall(_$postList, request, options: options);
}
// method descriptors
static final _$list = $grpc.ClientMethod<$0.FetchRequest, $1.TagListReply>(
'/feed.Tag/List',
($0.FetchRequest value) => value.writeToBuffer(),
$1.TagListReply.fromBuffer);
static final _$create = $grpc.ClientMethod<$1.AddTagRequest, $0.StatusReply>(
'/feed.Tag/Create',
($1.AddTagRequest value) => value.writeToBuffer(),
$0.StatusReply.fromBuffer);
static final _$postList =
$grpc.ClientMethod<$0.FetchRequest, $0.PostListReply>(
'/feed.Tag/PostList',
($0.FetchRequest value) => value.writeToBuffer(),
$0.PostListReply.fromBuffer);
}
@$pb.GrpcServiceName('feed.Tag')
abstract class TagServiceBase extends $grpc.Service {
$core.String get $name => 'feed.Tag';
TagServiceBase() {
$addMethod($grpc.ServiceMethod<$0.FetchRequest, $1.TagListReply>(
'List',
list_Pre,
false,
false,
($core.List<$core.int> value) => $0.FetchRequest.fromBuffer(value),
($1.TagListReply value) => value.writeToBuffer()));
$addMethod($grpc.ServiceMethod<$1.AddTagRequest, $0.StatusReply>(
'Create',
create_Pre,
false,
false,
($core.List<$core.int> value) => $1.AddTagRequest.fromBuffer(value),
($0.StatusReply value) => value.writeToBuffer()));
$addMethod($grpc.ServiceMethod<$0.FetchRequest, $0.PostListReply>(
'PostList',
postList_Pre,
false,
false,
($core.List<$core.int> value) => $0.FetchRequest.fromBuffer(value),
($0.PostListReply value) => value.writeToBuffer()));
}
$async.Future<$1.TagListReply> list_Pre(
$grpc.ServiceCall $call, $async.Future<$0.FetchRequest> $request) async {
return list($call, await $request);
}
$async.Future<$1.TagListReply> list(
$grpc.ServiceCall call, $0.FetchRequest request);
$async.Future<$0.StatusReply> create_Pre(
$grpc.ServiceCall $call, $async.Future<$1.AddTagRequest> $request) async {
return create($call, await $request);
}
$async.Future<$0.StatusReply> create(
$grpc.ServiceCall call, $1.AddTagRequest request);
$async.Future<$0.PostListReply> postList_Pre(
$grpc.ServiceCall $call, $async.Future<$0.FetchRequest> $request) async {
return postList($call, await $request);
}
$async.Future<$0.PostListReply> postList(
$grpc.ServiceCall call, $0.FetchRequest request);
}