rpc

package
v0.0.0-...-1369677 Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterActivityRPCServer

func RegisterActivityRPCServer(s *grpc.Server, srv ActivityRPCServer)

Types

type Activity

type Activity struct {
	Id                   int32    `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	TopicId              int32    `protobuf:"varint,2,opt,name=topic_id,json=topicId,proto3" json:"topic_id,omitempty"`
	StartTime            int64    `protobuf:"varint,3,opt,name=start_time,json=startTime,proto3" json:"start_time,omitempty"`
	EndTime              int64    `protobuf:"varint,4,opt,name=end_time,json=endTime,proto3" json:"end_time,omitempty"`
	Limit                int32    `protobuf:"varint,5,opt,name=limit,proto3" json:"limit,omitempty"`
	GoodsList            []*Goods `protobuf:"bytes,6,rep,name=goods_list,json=goodsList,proto3" json:"goods_list,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Activity) Descriptor

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

func (*Activity) GetEndTime

func (m *Activity) GetEndTime() int64

func (*Activity) GetGoodsList

func (m *Activity) GetGoodsList() []*Goods

func (*Activity) GetId

func (m *Activity) GetId() int32

func (*Activity) GetLimit

func (m *Activity) GetLimit() int32

func (*Activity) GetStartTime

func (m *Activity) GetStartTime() int64

func (*Activity) GetTopicId

func (m *Activity) GetTopicId() int32

func (*Activity) ProtoMessage

func (*Activity) ProtoMessage()

func (*Activity) Reset

func (m *Activity) Reset()

func (*Activity) String

func (m *Activity) String() string

func (*Activity) XXX_DiscardUnknown

func (m *Activity) XXX_DiscardUnknown()

func (*Activity) XXX_Marshal

func (m *Activity) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Activity) XXX_Merge

func (m *Activity) XXX_Merge(src proto.Message)

func (*Activity) XXX_Size

func (m *Activity) XXX_Size() int

func (*Activity) XXX_Unmarshal

func (m *Activity) XXX_Unmarshal(b []byte) error

type ActivityRPCClient

type ActivityRPCClient interface {
	ActivityOnline(ctx context.Context, in *Activity, opts ...grpc.CallOption) (*Response, error)
	ActivityOffline(ctx context.Context, in *Activity, opts ...grpc.CallOption) (*Response, error)
	TopicOnline(ctx context.Context, in *Topic, opts ...grpc.CallOption) (*Response, error)
	TopicOffline(ctx context.Context, in *Topic, opts ...grpc.CallOption) (*Response, error)
}

ActivityRPCClient is the client API for ActivityRPC service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewActivityRPCClient

func NewActivityRPCClient(cc *grpc.ClientConn) ActivityRPCClient

type ActivityRPCServer

type ActivityRPCServer interface {
	ActivityOnline(context.Context, *Activity) (*Response, error)
	ActivityOffline(context.Context, *Activity) (*Response, error)
	TopicOnline(context.Context, *Topic) (*Response, error)
	TopicOffline(context.Context, *Topic) (*Response, error)
}

ActivityRPCServer is the server API for ActivityRPC service.

type Goods

type Goods struct {
	Id                   int32    `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Desc                 string   `protobuf:"bytes,2,opt,name=desc,proto3" json:"desc,omitempty"`
	Img                  string   `protobuf:"bytes,3,opt,name=img,proto3" json:"img,omitempty"`
	Price                string   `protobuf:"bytes,4,opt,name=price,proto3" json:"price,omitempty"`
	ActivityPrice        string   `protobuf:"bytes,5,opt,name=activity_price,json=activityPrice,proto3" json:"activity_price,omitempty"`
	ActivityStock        int32    `protobuf:"varint,6,opt,name=activity_stock,json=activityStock,proto3" json:"activity_stock,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Goods) Descriptor

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

func (*Goods) GetActivityPrice

func (m *Goods) GetActivityPrice() string

func (*Goods) GetActivityStock

func (m *Goods) GetActivityStock() int32

func (*Goods) GetDesc

func (m *Goods) GetDesc() string

func (*Goods) GetId

func (m *Goods) GetId() int32

func (*Goods) GetImg

func (m *Goods) GetImg() string

func (*Goods) GetPrice

func (m *Goods) GetPrice() string

func (*Goods) ProtoMessage

func (*Goods) ProtoMessage()

func (*Goods) Reset

func (m *Goods) Reset()

func (*Goods) String

func (m *Goods) String() string

func (*Goods) XXX_DiscardUnknown

func (m *Goods) XXX_DiscardUnknown()

func (*Goods) XXX_Marshal

func (m *Goods) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Goods) XXX_Merge

func (m *Goods) XXX_Merge(src proto.Message)

func (*Goods) XXX_Size

func (m *Goods) XXX_Size() int

func (*Goods) XXX_Unmarshal

func (m *Goods) XXX_Unmarshal(b []byte) error

type Response

type Response struct {
	// 返回
	Code                 int32    `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
	Msg                  string   `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Response) Descriptor

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

func (*Response) GetCode

func (m *Response) GetCode() int32

func (*Response) GetMsg

func (m *Response) GetMsg() string

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) Reset

func (m *Response) Reset()

func (*Response) String

func (m *Response) String() string

func (*Response) XXX_DiscardUnknown

func (m *Response) XXX_DiscardUnknown()

func (*Response) XXX_Marshal

func (m *Response) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Response) XXX_Merge

func (m *Response) XXX_Merge(src proto.Message)

func (*Response) XXX_Size

func (m *Response) XXX_Size() int

func (*Response) XXX_Unmarshal

func (m *Response) XXX_Unmarshal(b []byte) error

type Topic

type Topic struct {
	//
	Id                   int32    `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Title                string   `protobuf:"bytes,2,opt,name=title,proto3" json:"title,omitempty"`
	Desc                 string   `protobuf:"bytes,3,opt,name=desc,proto3" json:"desc,omitempty"`
	Banner               string   `protobuf:"bytes,4,opt,name=banner,proto3" json:"banner,omitempty"`
	StartTime            int64    `protobuf:"varint,5,opt,name=start_time,json=startTime,proto3" json:"start_time,omitempty"`
	EndTime              int64    `protobuf:"varint,6,opt,name=end_time,json=endTime,proto3" json:"end_time,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Topic) Descriptor

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

func (*Topic) GetBanner

func (m *Topic) GetBanner() string

func (*Topic) GetDesc

func (m *Topic) GetDesc() string

func (*Topic) GetEndTime

func (m *Topic) GetEndTime() int64

func (*Topic) GetId

func (m *Topic) GetId() int32

func (*Topic) GetStartTime

func (m *Topic) GetStartTime() int64

func (*Topic) GetTitle

func (m *Topic) GetTitle() string

func (*Topic) ProtoMessage

func (*Topic) ProtoMessage()

func (*Topic) Reset

func (m *Topic) Reset()

func (*Topic) String

func (m *Topic) String() string

func (*Topic) XXX_DiscardUnknown

func (m *Topic) XXX_DiscardUnknown()

func (*Topic) XXX_Marshal

func (m *Topic) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Topic) XXX_Merge

func (m *Topic) XXX_Merge(src proto.Message)

func (*Topic) XXX_Size

func (m *Topic) XXX_Size() int

func (*Topic) XXX_Unmarshal

func (m *Topic) XXX_Unmarshal(b []byte) error

type UnimplementedActivityRPCServer

type UnimplementedActivityRPCServer struct {
}

UnimplementedActivityRPCServer can be embedded to have forward compatible implementations.

func (*UnimplementedActivityRPCServer) ActivityOffline

func (*UnimplementedActivityRPCServer) ActivityOffline(ctx context.Context, req *Activity) (*Response, error)

func (*UnimplementedActivityRPCServer) ActivityOnline

func (*UnimplementedActivityRPCServer) ActivityOnline(ctx context.Context, req *Activity) (*Response, error)

func (*UnimplementedActivityRPCServer) TopicOffline

func (*UnimplementedActivityRPCServer) TopicOffline(ctx context.Context, req *Topic) (*Response, error)

func (*UnimplementedActivityRPCServer) TopicOnline

func (*UnimplementedActivityRPCServer) TopicOnline(ctx context.Context, req *Topic) (*Response, error)

Jump to

Keyboard shortcuts

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