You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
312 lines
12 KiB
312 lines
12 KiB
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
|
|
// versions:
|
|
// - protoc-gen-go-grpc v1.4.0
|
|
// - protoc v5.27.1
|
|
// source: matchmaking/v1/share/shareIdn.proto
|
|
|
|
package v1
|
|
|
|
import (
|
|
context "context"
|
|
grpc "google.golang.org/grpc"
|
|
codes "google.golang.org/grpc/codes"
|
|
status "google.golang.org/grpc/status"
|
|
)
|
|
|
|
// This is a compile-time assertion to ensure that this generated file
|
|
// is compatible with the grpc package it is being compiled against.
|
|
// Requires gRPC-Go v1.62.0 or later.
|
|
const _ = grpc.SupportPackageIsVersion8
|
|
|
|
const (
|
|
ShareIdn_GetBotStockIdnTrade_FullMethodName = "/matchmaking.v1.ShareIdn/GetBotStockIdnTrade"
|
|
ShareIdn_ShareIdnPlaceOrder_FullMethodName = "/matchmaking.v1.ShareIdn/ShareIdnPlaceOrder"
|
|
ShareIdn_ShareIdnUpdateOrder_FullMethodName = "/matchmaking.v1.ShareIdn/ShareIdnUpdateOrder"
|
|
ShareIdn_ShareIdnPosition_FullMethodName = "/matchmaking.v1.ShareIdn/ShareIdnPosition"
|
|
ShareIdn_ShareIdnAllPosition_FullMethodName = "/matchmaking.v1.ShareIdn/ShareIdnAllPosition"
|
|
ShareIdn_ShareIdnCancel_FullMethodName = "/matchmaking.v1.ShareIdn/ShareIdnCancel"
|
|
)
|
|
|
|
// ShareIdnClient is the client API for ShareIdn 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 ShareIdnClient interface {
|
|
// GetBotStockIdnTrade 印尼股列表查询
|
|
GetBotStockIdnTrade(ctx context.Context, in *GetIdnBotStockTradeRequest, opts ...grpc.CallOption) (*GetBotStockIdnTradeReply, error)
|
|
// ShareIdnPlaceOrder 印尼股下单
|
|
ShareIdnPlaceOrder(ctx context.Context, in *ShareIdnOrderRequest, opts ...grpc.CallOption) (*IdnOrderReply, error)
|
|
// ShareIdnUpdateOrder 印尼股设置止盈止损
|
|
ShareIdnUpdateOrder(ctx context.Context, in *UpdateIdnOrderRequest, opts ...grpc.CallOption) (*IdnOrderReply, error)
|
|
// ShareIdnPosition 印尼股平仓
|
|
ShareIdnPosition(ctx context.Context, in *CancelIdnOrderRequest, opts ...grpc.CallOption) (*IdnOrderReply, error)
|
|
// ShareIdnAllPosition 印尼股一键平仓
|
|
ShareIdnAllPosition(ctx context.Context, in *AllIdnOrderRequest, opts ...grpc.CallOption) (*AllIdnOrderReply, error)
|
|
// ShareIdnCancel 印尼股撤单
|
|
ShareIdnCancel(ctx context.Context, in *CancelIdnOrderRequest, opts ...grpc.CallOption) (*IdnOrderReply, error)
|
|
}
|
|
|
|
type shareIdnClient struct {
|
|
cc grpc.ClientConnInterface
|
|
}
|
|
|
|
func NewShareIdnClient(cc grpc.ClientConnInterface) ShareIdnClient {
|
|
return &shareIdnClient{cc}
|
|
}
|
|
|
|
func (c *shareIdnClient) GetBotStockIdnTrade(ctx context.Context, in *GetIdnBotStockTradeRequest, opts ...grpc.CallOption) (*GetBotStockIdnTradeReply, error) {
|
|
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
|
out := new(GetBotStockIdnTradeReply)
|
|
err := c.cc.Invoke(ctx, ShareIdn_GetBotStockIdnTrade_FullMethodName, in, out, cOpts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *shareIdnClient) ShareIdnPlaceOrder(ctx context.Context, in *ShareIdnOrderRequest, opts ...grpc.CallOption) (*IdnOrderReply, error) {
|
|
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
|
out := new(IdnOrderReply)
|
|
err := c.cc.Invoke(ctx, ShareIdn_ShareIdnPlaceOrder_FullMethodName, in, out, cOpts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *shareIdnClient) ShareIdnUpdateOrder(ctx context.Context, in *UpdateIdnOrderRequest, opts ...grpc.CallOption) (*IdnOrderReply, error) {
|
|
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
|
out := new(IdnOrderReply)
|
|
err := c.cc.Invoke(ctx, ShareIdn_ShareIdnUpdateOrder_FullMethodName, in, out, cOpts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *shareIdnClient) ShareIdnPosition(ctx context.Context, in *CancelIdnOrderRequest, opts ...grpc.CallOption) (*IdnOrderReply, error) {
|
|
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
|
out := new(IdnOrderReply)
|
|
err := c.cc.Invoke(ctx, ShareIdn_ShareIdnPosition_FullMethodName, in, out, cOpts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *shareIdnClient) ShareIdnAllPosition(ctx context.Context, in *AllIdnOrderRequest, opts ...grpc.CallOption) (*AllIdnOrderReply, error) {
|
|
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
|
out := new(AllIdnOrderReply)
|
|
err := c.cc.Invoke(ctx, ShareIdn_ShareIdnAllPosition_FullMethodName, in, out, cOpts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *shareIdnClient) ShareIdnCancel(ctx context.Context, in *CancelIdnOrderRequest, opts ...grpc.CallOption) (*IdnOrderReply, error) {
|
|
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
|
out := new(IdnOrderReply)
|
|
err := c.cc.Invoke(ctx, ShareIdn_ShareIdnCancel_FullMethodName, in, out, cOpts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
// ShareIdnServer is the server API for ShareIdn service.
|
|
// All implementations must embed UnimplementedShareIdnServer
|
|
// for forward compatibility
|
|
type ShareIdnServer interface {
|
|
// GetBotStockIdnTrade 印尼股列表查询
|
|
GetBotStockIdnTrade(context.Context, *GetIdnBotStockTradeRequest) (*GetBotStockIdnTradeReply, error)
|
|
// ShareIdnPlaceOrder 印尼股下单
|
|
ShareIdnPlaceOrder(context.Context, *ShareIdnOrderRequest) (*IdnOrderReply, error)
|
|
// ShareIdnUpdateOrder 印尼股设置止盈止损
|
|
ShareIdnUpdateOrder(context.Context, *UpdateIdnOrderRequest) (*IdnOrderReply, error)
|
|
// ShareIdnPosition 印尼股平仓
|
|
ShareIdnPosition(context.Context, *CancelIdnOrderRequest) (*IdnOrderReply, error)
|
|
// ShareIdnAllPosition 印尼股一键平仓
|
|
ShareIdnAllPosition(context.Context, *AllIdnOrderRequest) (*AllIdnOrderReply, error)
|
|
// ShareIdnCancel 印尼股撤单
|
|
ShareIdnCancel(context.Context, *CancelIdnOrderRequest) (*IdnOrderReply, error)
|
|
mustEmbedUnimplementedShareIdnServer()
|
|
}
|
|
|
|
// UnimplementedShareIdnServer must be embedded to have forward compatible implementations.
|
|
type UnimplementedShareIdnServer struct {
|
|
}
|
|
|
|
func (UnimplementedShareIdnServer) GetBotStockIdnTrade(context.Context, *GetIdnBotStockTradeRequest) (*GetBotStockIdnTradeReply, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method GetBotStockIdnTrade not implemented")
|
|
}
|
|
func (UnimplementedShareIdnServer) ShareIdnPlaceOrder(context.Context, *ShareIdnOrderRequest) (*IdnOrderReply, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method ShareIdnPlaceOrder not implemented")
|
|
}
|
|
func (UnimplementedShareIdnServer) ShareIdnUpdateOrder(context.Context, *UpdateIdnOrderRequest) (*IdnOrderReply, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method ShareIdnUpdateOrder not implemented")
|
|
}
|
|
func (UnimplementedShareIdnServer) ShareIdnPosition(context.Context, *CancelIdnOrderRequest) (*IdnOrderReply, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method ShareIdnPosition not implemented")
|
|
}
|
|
func (UnimplementedShareIdnServer) ShareIdnAllPosition(context.Context, *AllIdnOrderRequest) (*AllIdnOrderReply, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method ShareIdnAllPosition not implemented")
|
|
}
|
|
func (UnimplementedShareIdnServer) ShareIdnCancel(context.Context, *CancelIdnOrderRequest) (*IdnOrderReply, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method ShareIdnCancel not implemented")
|
|
}
|
|
func (UnimplementedShareIdnServer) mustEmbedUnimplementedShareIdnServer() {}
|
|
|
|
// UnsafeShareIdnServer may be embedded to opt out of forward compatibility for this service.
|
|
// Use of this interface is not recommended, as added methods to ShareIdnServer will
|
|
// result in compilation errors.
|
|
type UnsafeShareIdnServer interface {
|
|
mustEmbedUnimplementedShareIdnServer()
|
|
}
|
|
|
|
func RegisterShareIdnServer(s grpc.ServiceRegistrar, srv ShareIdnServer) {
|
|
s.RegisterService(&ShareIdn_ServiceDesc, srv)
|
|
}
|
|
|
|
func _ShareIdn_GetBotStockIdnTrade_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(GetIdnBotStockTradeRequest)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(ShareIdnServer).GetBotStockIdnTrade(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: ShareIdn_GetBotStockIdnTrade_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(ShareIdnServer).GetBotStockIdnTrade(ctx, req.(*GetIdnBotStockTradeRequest))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _ShareIdn_ShareIdnPlaceOrder_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(ShareIdnOrderRequest)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(ShareIdnServer).ShareIdnPlaceOrder(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: ShareIdn_ShareIdnPlaceOrder_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(ShareIdnServer).ShareIdnPlaceOrder(ctx, req.(*ShareIdnOrderRequest))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _ShareIdn_ShareIdnUpdateOrder_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(UpdateIdnOrderRequest)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(ShareIdnServer).ShareIdnUpdateOrder(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: ShareIdn_ShareIdnUpdateOrder_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(ShareIdnServer).ShareIdnUpdateOrder(ctx, req.(*UpdateIdnOrderRequest))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _ShareIdn_ShareIdnPosition_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(CancelIdnOrderRequest)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(ShareIdnServer).ShareIdnPosition(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: ShareIdn_ShareIdnPosition_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(ShareIdnServer).ShareIdnPosition(ctx, req.(*CancelIdnOrderRequest))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _ShareIdn_ShareIdnAllPosition_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(AllIdnOrderRequest)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(ShareIdnServer).ShareIdnAllPosition(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: ShareIdn_ShareIdnAllPosition_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(ShareIdnServer).ShareIdnAllPosition(ctx, req.(*AllIdnOrderRequest))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _ShareIdn_ShareIdnCancel_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(CancelIdnOrderRequest)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(ShareIdnServer).ShareIdnCancel(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: ShareIdn_ShareIdnCancel_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(ShareIdnServer).ShareIdnCancel(ctx, req.(*CancelIdnOrderRequest))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
// ShareIdn_ServiceDesc is the grpc.ServiceDesc for ShareIdn service.
|
|
// It's only intended for direct use with grpc.RegisterService,
|
|
// and not to be introspected or modified (even as a copy)
|
|
var ShareIdn_ServiceDesc = grpc.ServiceDesc{
|
|
ServiceName: "matchmaking.v1.ShareIdn",
|
|
HandlerType: (*ShareIdnServer)(nil),
|
|
Methods: []grpc.MethodDesc{
|
|
{
|
|
MethodName: "GetBotStockIdnTrade",
|
|
Handler: _ShareIdn_GetBotStockIdnTrade_Handler,
|
|
},
|
|
{
|
|
MethodName: "ShareIdnPlaceOrder",
|
|
Handler: _ShareIdn_ShareIdnPlaceOrder_Handler,
|
|
},
|
|
{
|
|
MethodName: "ShareIdnUpdateOrder",
|
|
Handler: _ShareIdn_ShareIdnUpdateOrder_Handler,
|
|
},
|
|
{
|
|
MethodName: "ShareIdnPosition",
|
|
Handler: _ShareIdn_ShareIdnPosition_Handler,
|
|
},
|
|
{
|
|
MethodName: "ShareIdnAllPosition",
|
|
Handler: _ShareIdn_ShareIdnAllPosition_Handler,
|
|
},
|
|
{
|
|
MethodName: "ShareIdnCancel",
|
|
Handler: _ShareIdn_ShareIdnCancel_Handler,
|
|
},
|
|
},
|
|
Streams: []grpc.StreamDesc{},
|
|
Metadata: "matchmaking/v1/share/shareIdn.proto",
|
|
}
|
|
|