biz

package
v0.0.0-...-fefde71 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2024 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PaymentService_CreatePayment_FullMethodName = "/payment.PaymentService/CreatePayment"
	PaymentService_GetPayment_FullMethodName    = "/payment.PaymentService/GetPayment"
	PaymentService_ListPayments_FullMethodName  = "/payment.PaymentService/ListPayments"
)

Variables

View Source
var File_domain_payment_biz_payment_proto protoreflect.FileDescriptor
View Source
var PaymentService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "payment.PaymentService",
	HandlerType: (*PaymentServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreatePayment",
			Handler:    _PaymentService_CreatePayment_Handler,
		},
		{
			MethodName: "GetPayment",
			Handler:    _PaymentService_GetPayment_Handler,
		},
		{
			MethodName: "ListPayments",
			Handler:    _PaymentService_ListPayments_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "domain/payment/biz/payment.proto",
}

PaymentService_ServiceDesc is the grpc.ServiceDesc for PaymentService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterPaymentServiceServer

func RegisterPaymentServiceServer(s grpc.ServiceRegistrar, srv PaymentServiceServer)

Types

type CreatePaymentRequest

type CreatePaymentRequest struct {
	OrderId int64                `protobuf:"varint,1,opt,name=order_id,json=orderId,proto3" json:"order_id,omitempty"`
	Amount  *model.PaymentAmount `protobuf:"bytes,2,opt,name=amount,proto3" json:"amount,omitempty"`
	// contains filtered or unexported fields
}

func (*CreatePaymentRequest) Descriptor deprecated

func (*CreatePaymentRequest) Descriptor() ([]byte, []int)

Deprecated: Use CreatePaymentRequest.ProtoReflect.Descriptor instead.

func (*CreatePaymentRequest) GetAmount

func (x *CreatePaymentRequest) GetAmount() *model.PaymentAmount

func (*CreatePaymentRequest) GetOrderId

func (x *CreatePaymentRequest) GetOrderId() int64

func (*CreatePaymentRequest) ProtoMessage

func (*CreatePaymentRequest) ProtoMessage()

func (*CreatePaymentRequest) ProtoReflect

func (x *CreatePaymentRequest) ProtoReflect() protoreflect.Message

func (*CreatePaymentRequest) Reset

func (x *CreatePaymentRequest) Reset()

func (*CreatePaymentRequest) String

func (x *CreatePaymentRequest) String() string

type GetPaymentRequest

type GetPaymentRequest struct {
	PaymentId string `protobuf:"bytes,1,opt,name=payment_id,json=paymentId,proto3" json:"payment_id,omitempty"`
	// contains filtered or unexported fields
}

func (*GetPaymentRequest) Descriptor deprecated

func (*GetPaymentRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetPaymentRequest.ProtoReflect.Descriptor instead.

func (*GetPaymentRequest) GetPaymentId

func (x *GetPaymentRequest) GetPaymentId() string

func (*GetPaymentRequest) ProtoMessage

func (*GetPaymentRequest) ProtoMessage()

func (*GetPaymentRequest) ProtoReflect

func (x *GetPaymentRequest) ProtoReflect() protoreflect.Message

func (*GetPaymentRequest) Reset

func (x *GetPaymentRequest) Reset()

func (*GetPaymentRequest) String

func (x *GetPaymentRequest) String() string

type ListPaymentsRequest

type ListPaymentsRequest struct {
	Page     int64 `protobuf:"varint,1,opt,name=page,proto3" json:"page,omitempty"`
	PageSize int64 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// contains filtered or unexported fields
}

func (*ListPaymentsRequest) Descriptor deprecated

func (*ListPaymentsRequest) Descriptor() ([]byte, []int)

Deprecated: Use ListPaymentsRequest.ProtoReflect.Descriptor instead.

func (*ListPaymentsRequest) GetPage

func (x *ListPaymentsRequest) GetPage() int64

func (*ListPaymentsRequest) GetPageSize

func (x *ListPaymentsRequest) GetPageSize() int64

func (*ListPaymentsRequest) ProtoMessage

func (*ListPaymentsRequest) ProtoMessage()

func (*ListPaymentsRequest) ProtoReflect

func (x *ListPaymentsRequest) ProtoReflect() protoreflect.Message

func (*ListPaymentsRequest) Reset

func (x *ListPaymentsRequest) Reset()

func (*ListPaymentsRequest) String

func (x *ListPaymentsRequest) String() string

type ListPaymentsResponse

type ListPaymentsResponse struct {
	Payments []*model.Payment `protobuf:"bytes,1,rep,name=payments,proto3" json:"payments,omitempty"`
	Total    int64            `protobuf:"varint,2,opt,name=total,proto3" json:"total,omitempty"`
	// contains filtered or unexported fields
}

func (*ListPaymentsResponse) Descriptor deprecated

func (*ListPaymentsResponse) Descriptor() ([]byte, []int)

Deprecated: Use ListPaymentsResponse.ProtoReflect.Descriptor instead.

func (*ListPaymentsResponse) GetPayments

func (x *ListPaymentsResponse) GetPayments() []*model.Payment

func (*ListPaymentsResponse) GetTotal

func (x *ListPaymentsResponse) GetTotal() int64

func (*ListPaymentsResponse) ProtoMessage

func (*ListPaymentsResponse) ProtoMessage()

func (*ListPaymentsResponse) ProtoReflect

func (x *ListPaymentsResponse) ProtoReflect() protoreflect.Message

func (*ListPaymentsResponse) Reset

func (x *ListPaymentsResponse) Reset()

func (*ListPaymentsResponse) String

func (x *ListPaymentsResponse) String() string

type MockPaymentServiceClient

type MockPaymentServiceClient struct {
	// contains filtered or unexported fields
}

MockPaymentServiceClient is a mock of PaymentServiceClient interface.

func NewMockPaymentServiceClient

func NewMockPaymentServiceClient(ctrl *gomock.Controller) *MockPaymentServiceClient

NewMockPaymentServiceClient creates a new mock instance.

func (*MockPaymentServiceClient) CreatePayment

CreatePayment mocks base method.

func (*MockPaymentServiceClient) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockPaymentServiceClient) GetPayment

GetPayment mocks base method.

func (*MockPaymentServiceClient) ListPayments

ListPayments mocks base method.

type MockPaymentServiceClientMockRecorder

type MockPaymentServiceClientMockRecorder struct {
	// contains filtered or unexported fields
}

MockPaymentServiceClientMockRecorder is the mock recorder for MockPaymentServiceClient.

func (*MockPaymentServiceClientMockRecorder) CreatePayment

func (mr *MockPaymentServiceClientMockRecorder) CreatePayment(ctx, in interface{}, opts ...interface{}) *gomock.Call

CreatePayment indicates an expected call of CreatePayment.

func (*MockPaymentServiceClientMockRecorder) GetPayment

func (mr *MockPaymentServiceClientMockRecorder) GetPayment(ctx, in interface{}, opts ...interface{}) *gomock.Call

GetPayment indicates an expected call of GetPayment.

func (*MockPaymentServiceClientMockRecorder) ListPayments

func (mr *MockPaymentServiceClientMockRecorder) ListPayments(ctx, in interface{}, opts ...interface{}) *gomock.Call

ListPayments indicates an expected call of ListPayments.

type MockPaymentServiceServer

type MockPaymentServiceServer struct {
	// contains filtered or unexported fields
}

MockPaymentServiceServer is a mock of PaymentServiceServer interface.

func NewMockPaymentServiceServer

func NewMockPaymentServiceServer(ctrl *gomock.Controller) *MockPaymentServiceServer

NewMockPaymentServiceServer creates a new mock instance.

func (*MockPaymentServiceServer) CreatePayment

CreatePayment mocks base method.

func (*MockPaymentServiceServer) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockPaymentServiceServer) GetPayment

GetPayment mocks base method.

func (*MockPaymentServiceServer) ListPayments

ListPayments mocks base method.

type MockPaymentServiceServerMockRecorder

type MockPaymentServiceServerMockRecorder struct {
	// contains filtered or unexported fields
}

MockPaymentServiceServerMockRecorder is the mock recorder for MockPaymentServiceServer.

func (*MockPaymentServiceServerMockRecorder) CreatePayment

func (mr *MockPaymentServiceServerMockRecorder) CreatePayment(ctx, in interface{}) *gomock.Call

CreatePayment indicates an expected call of CreatePayment.

func (*MockPaymentServiceServerMockRecorder) GetPayment

func (mr *MockPaymentServiceServerMockRecorder) GetPayment(ctx, in interface{}) *gomock.Call

GetPayment indicates an expected call of GetPayment.

func (*MockPaymentServiceServerMockRecorder) ListPayments

func (mr *MockPaymentServiceServerMockRecorder) ListPayments(ctx, in interface{}) *gomock.Call

ListPayments indicates an expected call of ListPayments.

type PaymentServiceClient

type PaymentServiceClient interface {
	CreatePayment(ctx context.Context, in *CreatePaymentRequest, opts ...grpc.CallOption) (*model.Payment, error)
	GetPayment(ctx context.Context, in *GetPaymentRequest, opts ...grpc.CallOption) (*model.Payment, error)
	ListPayments(ctx context.Context, in *ListPaymentsRequest, opts ...grpc.CallOption) (*ListPaymentsResponse, error)
}

PaymentServiceClient is the client API for PaymentService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type PaymentServiceServer

type PaymentServiceServer interface {
	CreatePayment(context.Context, *CreatePaymentRequest) (*model.Payment, error)
	GetPayment(context.Context, *GetPaymentRequest) (*model.Payment, error)
	ListPayments(context.Context, *ListPaymentsRequest) (*ListPaymentsResponse, error)
}

PaymentServiceServer is the server API for PaymentService service. All implementations should embed UnimplementedPaymentServiceServer for forward compatibility.

type UnimplementedPaymentServiceServer

type UnimplementedPaymentServiceServer struct{}

UnimplementedPaymentServiceServer should be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedPaymentServiceServer) CreatePayment

func (UnimplementedPaymentServiceServer) GetPayment

func (UnimplementedPaymentServiceServer) ListPayments

type UnsafePaymentServiceServer

type UnsafePaymentServiceServer interface {
	// contains filtered or unexported methods
}

UnsafePaymentServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PaymentServiceServer will result in compilation errors.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL