protos

package
v0.0.0-...-799f385 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterRPCServerServer

func RegisterRPCServerServer(s *grpc.Server, srv RPCServerServer)

Types

type Dummy

type Dummy struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Dummy) Descriptor

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

func (*Dummy) ProtoMessage

func (*Dummy) ProtoMessage()

func (*Dummy) Reset

func (m *Dummy) Reset()

func (*Dummy) String

func (m *Dummy) String() string

func (*Dummy) XXX_DiscardUnknown

func (m *Dummy) XXX_DiscardUnknown()

func (*Dummy) XXX_Marshal

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

func (*Dummy) XXX_Merge

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

func (*Dummy) XXX_Size

func (m *Dummy) XXX_Size() int

func (*Dummy) XXX_Unmarshal

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

type PullAckRequest

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

func (*PullAckRequest) Descriptor

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

func (*PullAckRequest) GetClientId

func (m *PullAckRequest) GetClientId() string

func (*PullAckRequest) ProtoMessage

func (*PullAckRequest) ProtoMessage()

func (*PullAckRequest) Reset

func (m *PullAckRequest) Reset()

func (*PullAckRequest) String

func (m *PullAckRequest) String() string

func (*PullAckRequest) XXX_DiscardUnknown

func (m *PullAckRequest) XXX_DiscardUnknown()

func (*PullAckRequest) XXX_Marshal

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

func (*PullAckRequest) XXX_Merge

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

func (*PullAckRequest) XXX_Size

func (m *PullAckRequest) XXX_Size() int

func (*PullAckRequest) XXX_Unmarshal

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

type RPCAck

type RPCAck struct {
	ReqId                uint32   `protobuf:"varint,1,opt,name=reqId,proto3" json:"reqId,omitempty"`
	Error                string   `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"`
	Message              string   `protobuf:"bytes,3,opt,name=message,proto3" json:"message,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*RPCAck) Descriptor

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

func (*RPCAck) GetError

func (m *RPCAck) GetError() string

func (*RPCAck) GetMessage

func (m *RPCAck) GetMessage() string

func (*RPCAck) GetReqId

func (m *RPCAck) GetReqId() uint32

func (*RPCAck) ProtoMessage

func (*RPCAck) ProtoMessage()

func (*RPCAck) Reset

func (m *RPCAck) Reset()

func (*RPCAck) String

func (m *RPCAck) String() string

func (*RPCAck) XXX_DiscardUnknown

func (m *RPCAck) XXX_DiscardUnknown()

func (*RPCAck) XXX_Marshal

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

func (*RPCAck) XXX_Merge

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

func (*RPCAck) XXX_Size

func (m *RPCAck) XXX_Size() int

func (*RPCAck) XXX_Unmarshal

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

type RPCAcks

type RPCAcks struct {
	Ack                  []*RPCAck `protobuf:"bytes,1,rep,name=ack,proto3" json:"ack,omitempty"`
	XXX_NoUnkeyedLiteral struct{}  `json:"-"`
	XXX_unrecognized     []byte    `json:"-"`
	XXX_sizecache        int32     `json:"-"`
}

func (*RPCAcks) Descriptor

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

func (*RPCAcks) GetAck

func (m *RPCAcks) GetAck() []*RPCAck

func (*RPCAcks) ProtoMessage

func (*RPCAcks) ProtoMessage()

func (*RPCAcks) Reset

func (m *RPCAcks) Reset()

func (*RPCAcks) String

func (m *RPCAcks) String() string

func (*RPCAcks) XXX_DiscardUnknown

func (m *RPCAcks) XXX_DiscardUnknown()

func (*RPCAcks) XXX_Marshal

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

func (*RPCAcks) XXX_Merge

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

func (*RPCAcks) XXX_Size

func (m *RPCAcks) XXX_Size() int

func (*RPCAcks) XXX_Unmarshal

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

type RPCReply

type RPCReply struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

The normal response message

func (*RPCReply) Descriptor

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

func (*RPCReply) ProtoMessage

func (*RPCReply) ProtoMessage()

func (*RPCReply) Reset

func (m *RPCReply) Reset()

func (*RPCReply) String

func (m *RPCReply) String() string

func (*RPCReply) XXX_DiscardUnknown

func (m *RPCReply) XXX_DiscardUnknown()

func (*RPCReply) XXX_Marshal

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

func (*RPCReply) XXX_Merge

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

func (*RPCReply) XXX_Size

func (m *RPCReply) XXX_Size() int

func (*RPCReply) XXX_Unmarshal

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

type RPCRequest

type RPCRequest struct {
	// 客户端id
	ReqId                uint32   `protobuf:"varint,1,opt,name=reqId,proto3" json:"reqId,omitempty"`
	ClientId             string   `protobuf:"bytes,2,opt,name=clientId,proto3" json:"clientId,omitempty"`
	Method               string   `protobuf:"bytes,3,opt,name=method,proto3" json:"method,omitempty"`
	Message              string   `protobuf:"bytes,4,opt,name=message,proto3" json:"message,omitempty"`
	NeedAck              bool     `protobuf:"varint,5,opt,name=needAck,proto3" json:"needAck,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

The request message containing the user's name.

func (*RPCRequest) Descriptor

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

func (*RPCRequest) GetClientId

func (m *RPCRequest) GetClientId() string

func (*RPCRequest) GetMessage

func (m *RPCRequest) GetMessage() string

func (*RPCRequest) GetMethod

func (m *RPCRequest) GetMethod() string

func (*RPCRequest) GetNeedAck

func (m *RPCRequest) GetNeedAck() bool

func (*RPCRequest) GetReqId

func (m *RPCRequest) GetReqId() uint32

func (*RPCRequest) ProtoMessage

func (*RPCRequest) ProtoMessage()

func (*RPCRequest) Reset

func (m *RPCRequest) Reset()

func (*RPCRequest) String

func (m *RPCRequest) String() string

func (*RPCRequest) XXX_DiscardUnknown

func (m *RPCRequest) XXX_DiscardUnknown()

func (*RPCRequest) XXX_Marshal

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

func (*RPCRequest) XXX_Merge

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

func (*RPCRequest) XXX_Size

func (m *RPCRequest) XXX_Size() int

func (*RPCRequest) XXX_Unmarshal

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

type RPCServerClient

type RPCServerClient interface {
	// Sends a greeting
	RPC(ctx context.Context, in *RPCRequest, opts ...grpc.CallOption) (*RPCReply, error)
	PullAcks(ctx context.Context, in *PullAckRequest, opts ...grpc.CallOption) (*RPCAcks, error)
}

RPCServerClient is the client API for RPCServer service.

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

func NewRPCServerClient

func NewRPCServerClient(cc *grpc.ClientConn) RPCServerClient

type RPCServerServer

type RPCServerServer interface {
	// Sends a greeting
	RPC(context.Context, *RPCRequest) (*RPCReply, error)
	PullAcks(context.Context, *PullAckRequest) (*RPCAcks, error)
}

RPCServerServer is the server API for RPCServer service.

type UnimplementedRPCServerServer

type UnimplementedRPCServerServer struct {
}

UnimplementedRPCServerServer can be embedded to have forward compatible implementations.

func (*UnimplementedRPCServerServer) PullAcks

func (*UnimplementedRPCServerServer) RPC

Directories

Path Synopsis
dfk.com

Jump to

Keyboard shortcuts

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