pb

package
v0.0.0-...-aafc065 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterServiceServer

func RegisterServiceServer(s *grpc.Server, srv ServiceServer)

Types

type Req

type Req struct {
	Msg                  string   `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Req) Descriptor

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

func (*Req) GetMsg

func (m *Req) GetMsg() string

func (*Req) ProtoMessage

func (*Req) ProtoMessage()

func (*Req) Reset

func (m *Req) Reset()

func (*Req) String

func (m *Req) String() string

func (*Req) XXX_DiscardUnknown

func (m *Req) XXX_DiscardUnknown()

func (*Req) XXX_Marshal

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

func (*Req) XXX_Merge

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

func (*Req) XXX_Size

func (m *Req) XXX_Size() int

func (*Req) XXX_Unmarshal

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

type Resp

type Resp struct {
	Msg string `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
	// Types that are valid to be assigned to Resp:
	//	*Resp_RespOk
	//	*Resp_RespError
	Resp                 isResp_Resp `protobuf_oneof:"Resp"`
	XXX_NoUnkeyedLiteral struct{}    `json:"-"`
	XXX_unrecognized     []byte      `json:"-"`
	XXX_sizecache        int32       `json:"-"`
}

func (*Resp) Descriptor

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

func (*Resp) GetMsg

func (m *Resp) GetMsg() string

func (*Resp) GetResp

func (m *Resp) GetResp() isResp_Resp

func (*Resp) GetRespError

func (m *Resp) GetRespError() *RespError

func (*Resp) GetRespOk

func (m *Resp) GetRespOk() *RespOk

func (*Resp) ProtoMessage

func (*Resp) ProtoMessage()

func (*Resp) Reset

func (m *Resp) Reset()

func (*Resp) String

func (m *Resp) String() string

func (*Resp) XXX_DiscardUnknown

func (m *Resp) XXX_DiscardUnknown()

func (*Resp) XXX_Marshal

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

func (*Resp) XXX_Merge

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

func (*Resp) XXX_OneofWrappers

func (*Resp) XXX_OneofWrappers() []interface{}

XXX_OneofWrappers is for the internal use of the proto package.

func (*Resp) XXX_Size

func (m *Resp) XXX_Size() int

func (*Resp) XXX_Unmarshal

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

type RespError

type RespError struct {
	ErrorId              int32    `protobuf:"varint,1,opt,name=error_id,json=errorId,proto3" json:"error_id,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*RespError) Descriptor

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

func (*RespError) GetErrorId

func (m *RespError) GetErrorId() int32

func (*RespError) ProtoMessage

func (*RespError) ProtoMessage()

func (*RespError) Reset

func (m *RespError) Reset()

func (*RespError) String

func (m *RespError) String() string

func (*RespError) XXX_DiscardUnknown

func (m *RespError) XXX_DiscardUnknown()

func (*RespError) XXX_Marshal

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

func (*RespError) XXX_Merge

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

func (*RespError) XXX_Size

func (m *RespError) XXX_Size() int

func (*RespError) XXX_Unmarshal

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

type RespOk

type RespOk struct {
	SuccessId            int32    `protobuf:"varint,1,opt,name=success_id,json=successId,proto3" json:"success_id,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*RespOk) Descriptor

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

func (*RespOk) GetSuccessId

func (m *RespOk) GetSuccessId() int32

func (*RespOk) ProtoMessage

func (*RespOk) ProtoMessage()

func (*RespOk) Reset

func (m *RespOk) Reset()

func (*RespOk) String

func (m *RespOk) String() string

func (*RespOk) XXX_DiscardUnknown

func (m *RespOk) XXX_DiscardUnknown()

func (*RespOk) XXX_Marshal

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

func (*RespOk) XXX_Merge

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

func (*RespOk) XXX_Size

func (m *RespOk) XXX_Size() int

func (*RespOk) XXX_Unmarshal

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

type Resp_RespError

type Resp_RespError struct {
	RespError *RespError `protobuf:"bytes,3,opt,name=RespError,proto3,oneof"`
}

type Resp_RespOk

type Resp_RespOk struct {
	RespOk *RespOk `protobuf:"bytes,2,opt,name=RespOk,proto3,oneof"`
}

type ServiceClient

type ServiceClient interface {
	Run1(ctx context.Context, in *Req, opts ...grpc.CallOption) (*Resp, error)
	Run2(ctx context.Context, in *Req, opts ...grpc.CallOption) (Service_Run2Client, error)
	Run3(ctx context.Context, opts ...grpc.CallOption) (Service_Run3Client, error)
	Run4(ctx context.Context, opts ...grpc.CallOption) (Service_Run4Client, error)
}

ServiceClient is the client API for Service service.

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

func NewServiceClient

func NewServiceClient(cc *grpc.ClientConn) ServiceClient

type ServiceServer

type ServiceServer interface {
	Run1(context.Context, *Req) (*Resp, error)
	Run2(*Req, Service_Run2Server) error
	Run3(Service_Run3Server) error
	Run4(Service_Run4Server) error
}

ServiceServer is the server API for Service service.

type Service_Run2Client

type Service_Run2Client interface {
	Recv() (*Resp, error)
	grpc.ClientStream
}

type Service_Run2Server

type Service_Run2Server interface {
	Send(*Resp) error
	grpc.ServerStream
}

type Service_Run3Client

type Service_Run3Client interface {
	Send(*Req) error
	CloseAndRecv() (*Resp, error)
	grpc.ClientStream
}

type Service_Run3Server

type Service_Run3Server interface {
	SendAndClose(*Resp) error
	Recv() (*Req, error)
	grpc.ServerStream
}

type Service_Run4Client

type Service_Run4Client interface {
	Send(*Req) error
	Recv() (*Resp, error)
	grpc.ClientStream
}

type Service_Run4Server

type Service_Run4Server interface {
	Send(*Resp) error
	Recv() (*Req, error)
	grpc.ServerStream
}

type UnimplementedServiceServer

type UnimplementedServiceServer struct {
}

UnimplementedServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedServiceServer) Run1

func (*UnimplementedServiceServer) Run1(ctx context.Context, req *Req) (*Resp, error)

func (*UnimplementedServiceServer) Run2

func (*UnimplementedServiceServer) Run3

func (*UnimplementedServiceServer) Run4

Jump to

Keyboard shortcuts

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