client/dart/wallet/payment.pbgrpc.dart

209 lines
6.8 KiB
Dart

// This is a generated file - do not edit.
//
// Generated from payment.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 'payment.pb.dart' as $1;
export 'payment.pb.dart';
@$pb.GrpcServiceName('wallet.Payment')
class PaymentClient 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 = [
'',
];
PaymentClient(super.channel, {super.options, super.interceptors});
$grpc.ResponseFuture<$1.PaymentReply> hello(
$0.Empty request, {
$grpc.CallOptions? options,
}) {
return $createUnaryCall(_$hello, request, options: options);
}
/// 获取平台支持的支付网关
$grpc.ResponseFuture<$1.WayReply> way(
$1.WayRequest request, {
$grpc.CallOptions? options,
}) {
return $createUnaryCall(_$way, request, options: options);
}
/// 获取支付的详情
$grpc.ResponseFuture<$1.PaymentItem> get(
$0.IdentRequest request, {
$grpc.CallOptions? options,
}) {
return $createUnaryCall(_$get, request, options: options);
}
/// 支付-电商订单
$grpc.ResponseFuture<$1.PaymentReply> byOrder(
$1.OrderRequest request, {
$grpc.CallOptions? options,
}) {
return $createUnaryCall(_$byOrder, request, options: options);
}
/// 支付-充值
$grpc.ResponseFuture<$1.PaymentReply> byCharge(
$1.ChargeRequest request, {
$grpc.CallOptions? options,
}) {
return $createUnaryCall(_$byCharge, request, options: options);
}
/// 回调更新支付的结果和状态
$grpc.ResponseFuture<$0.StatusReply> callback(
$1.CallbackRequest request, {
$grpc.CallOptions? options,
}) {
return $createUnaryCall(_$callback, request, options: options);
}
// method descriptors
static final _$hello = $grpc.ClientMethod<$0.Empty, $1.PaymentReply>(
'/wallet.Payment/Hello',
($0.Empty value) => value.writeToBuffer(),
$1.PaymentReply.fromBuffer);
static final _$way = $grpc.ClientMethod<$1.WayRequest, $1.WayReply>(
'/wallet.Payment/Way',
($1.WayRequest value) => value.writeToBuffer(),
$1.WayReply.fromBuffer);
static final _$get = $grpc.ClientMethod<$0.IdentRequest, $1.PaymentItem>(
'/wallet.Payment/Get',
($0.IdentRequest value) => value.writeToBuffer(),
$1.PaymentItem.fromBuffer);
static final _$byOrder = $grpc.ClientMethod<$1.OrderRequest, $1.PaymentReply>(
'/wallet.Payment/ByOrder',
($1.OrderRequest value) => value.writeToBuffer(),
$1.PaymentReply.fromBuffer);
static final _$byCharge =
$grpc.ClientMethod<$1.ChargeRequest, $1.PaymentReply>(
'/wallet.Payment/ByCharge',
($1.ChargeRequest value) => value.writeToBuffer(),
$1.PaymentReply.fromBuffer);
static final _$callback =
$grpc.ClientMethod<$1.CallbackRequest, $0.StatusReply>(
'/wallet.Payment/Callback',
($1.CallbackRequest value) => value.writeToBuffer(),
$0.StatusReply.fromBuffer);
}
@$pb.GrpcServiceName('wallet.Payment')
abstract class PaymentServiceBase extends $grpc.Service {
$core.String get $name => 'wallet.Payment';
PaymentServiceBase() {
$addMethod($grpc.ServiceMethod<$0.Empty, $1.PaymentReply>(
'Hello',
hello_Pre,
false,
false,
($core.List<$core.int> value) => $0.Empty.fromBuffer(value),
($1.PaymentReply value) => value.writeToBuffer()));
$addMethod($grpc.ServiceMethod<$1.WayRequest, $1.WayReply>(
'Way',
way_Pre,
false,
false,
($core.List<$core.int> value) => $1.WayRequest.fromBuffer(value),
($1.WayReply value) => value.writeToBuffer()));
$addMethod($grpc.ServiceMethod<$0.IdentRequest, $1.PaymentItem>(
'Get',
get_Pre,
false,
false,
($core.List<$core.int> value) => $0.IdentRequest.fromBuffer(value),
($1.PaymentItem value) => value.writeToBuffer()));
$addMethod($grpc.ServiceMethod<$1.OrderRequest, $1.PaymentReply>(
'ByOrder',
byOrder_Pre,
false,
false,
($core.List<$core.int> value) => $1.OrderRequest.fromBuffer(value),
($1.PaymentReply value) => value.writeToBuffer()));
$addMethod($grpc.ServiceMethod<$1.ChargeRequest, $1.PaymentReply>(
'ByCharge',
byCharge_Pre,
false,
false,
($core.List<$core.int> value) => $1.ChargeRequest.fromBuffer(value),
($1.PaymentReply value) => value.writeToBuffer()));
$addMethod($grpc.ServiceMethod<$1.CallbackRequest, $0.StatusReply>(
'Callback',
callback_Pre,
false,
false,
($core.List<$core.int> value) => $1.CallbackRequest.fromBuffer(value),
($0.StatusReply value) => value.writeToBuffer()));
}
$async.Future<$1.PaymentReply> hello_Pre(
$grpc.ServiceCall $call, $async.Future<$0.Empty> $request) async {
return hello($call, await $request);
}
$async.Future<$1.PaymentReply> hello(
$grpc.ServiceCall call, $0.Empty request);
$async.Future<$1.WayReply> way_Pre(
$grpc.ServiceCall $call, $async.Future<$1.WayRequest> $request) async {
return way($call, await $request);
}
$async.Future<$1.WayReply> way($grpc.ServiceCall call, $1.WayRequest request);
$async.Future<$1.PaymentItem> get_Pre(
$grpc.ServiceCall $call, $async.Future<$0.IdentRequest> $request) async {
return get($call, await $request);
}
$async.Future<$1.PaymentItem> get(
$grpc.ServiceCall call, $0.IdentRequest request);
$async.Future<$1.PaymentReply> byOrder_Pre(
$grpc.ServiceCall $call, $async.Future<$1.OrderRequest> $request) async {
return byOrder($call, await $request);
}
$async.Future<$1.PaymentReply> byOrder(
$grpc.ServiceCall call, $1.OrderRequest request);
$async.Future<$1.PaymentReply> byCharge_Pre(
$grpc.ServiceCall $call, $async.Future<$1.ChargeRequest> $request) async {
return byCharge($call, await $request);
}
$async.Future<$1.PaymentReply> byCharge(
$grpc.ServiceCall call, $1.ChargeRequest request);
$async.Future<$0.StatusReply> callback_Pre($grpc.ServiceCall $call,
$async.Future<$1.CallbackRequest> $request) async {
return callback($call, await $request);
}
$async.Future<$0.StatusReply> callback(
$grpc.ServiceCall call, $1.CallbackRequest request);
}