pb

package
v0.0.0-...-d11ffb8 Latest Latest
Warning

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

Go to latest
Published: Jan 2, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	StoreReply_ReplyType_name = map[int32]string{
		0: "Success",
		1: "Fail",
	}
	StoreReply_ReplyType_value = map[string]int32{
		"Success": 0,
		"Fail":    1,
	}
)

Enum value maps for StoreReply_ReplyType.

View Source
var (
	UpdateReply_ReplyType_name = map[int32]string{
		0: "Success",
		1: "Fail",
	}
	UpdateReply_ReplyType_value = map[string]int32{
		"Success": 0,
		"Fail":    1,
	}
)

Enum value maps for UpdateReply_ReplyType.

View Source
var (
	ListReply_ReplyType_name = map[int32]string{
		0: "Success",
		1: "Fail",
	}
	ListReply_ReplyType_value = map[string]int32{
		"Success": 0,
		"Fail":    1,
	}
)

Enum value maps for ListReply_ReplyType.

View Source
var File_comments_proto protoreflect.FileDescriptor

Functions

func RegisterCommentsServer

func RegisterCommentsServer(s *grpc.Server, srv CommentsServer)

Types

type Comment

type Comment struct {
	PostID string `protobuf:"bytes,1,opt,name=postID,proto3" json:"postID,omitempty"`
	UserID string `protobuf:"bytes,2,opt,name=userID,proto3" json:"userID,omitempty"`
	Title  string `protobuf:"bytes,3,opt,name=title,proto3" json:"title,omitempty"`
	Body   string `protobuf:"bytes,4,opt,name=body,proto3" json:"body,omitempty"`
	// Types that are assignable to Username:
	//	*Comment_Name
	Username isComment_Username `protobuf_oneof:"username"`
	// Types that are assignable to Useremail:
	//	*Comment_Email
	Useremail isComment_Useremail `protobuf_oneof:"useremail"`
	// contains filtered or unexported fields
}

func (*Comment) Descriptor deprecated

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

Deprecated: Use Comment.ProtoReflect.Descriptor instead.

func (*Comment) GetBody

func (x *Comment) GetBody() string

func (*Comment) GetEmail

func (x *Comment) GetEmail() string

func (*Comment) GetName

func (x *Comment) GetName() string

func (*Comment) GetPostID

func (x *Comment) GetPostID() string

func (*Comment) GetTitle

func (x *Comment) GetTitle() string

func (*Comment) GetUserID

func (x *Comment) GetUserID() string

func (*Comment) GetUseremail

func (m *Comment) GetUseremail() isComment_Useremail

func (*Comment) GetUsername

func (m *Comment) GetUsername() isComment_Username

func (*Comment) ProtoMessage

func (*Comment) ProtoMessage()

func (*Comment) ProtoReflect

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

func (*Comment) Reset

func (x *Comment) Reset()

func (*Comment) String

func (x *Comment) String() string

type Comment_Email

type Comment_Email struct {
	Email string `protobuf:"bytes,6,opt,name=email,proto3,oneof"`
}

type Comment_Name

type Comment_Name struct {
	Name string `protobuf:"bytes,5,opt,name=name,proto3,oneof"`
}

type CommentsClient

type CommentsClient interface {
	Store(ctx context.Context, in *StoreRequest, opts ...grpc.CallOption) (*StoreReply, error)
	Update(ctx context.Context, in *UpdateRequest, opts ...grpc.CallOption) (*UpdateReply, error)
	List(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ListReply, error)
}

CommentsClient is the client API for Comments service.

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

func NewCommentsClient

func NewCommentsClient(cc grpc.ClientConnInterface) CommentsClient

type CommentsServer

type CommentsServer interface {
	Store(context.Context, *StoreRequest) (*StoreReply, error)
	Update(context.Context, *UpdateRequest) (*UpdateReply, error)
	List(context.Context, *ListRequest) (*ListReply, error)
}

CommentsServer is the server API for Comments service.

type ListReply

type ListReply struct {
	Comments []*Comment `protobuf:"bytes,1,rep,name=comments,proto3" json:"comments,omitempty"`
	Status   string     `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"`
	// contains filtered or unexported fields
}

func (*ListReply) Descriptor deprecated

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

Deprecated: Use ListReply.ProtoReflect.Descriptor instead.

func (*ListReply) GetComments

func (x *ListReply) GetComments() []*Comment

func (*ListReply) GetStatus

func (x *ListReply) GetStatus() string

func (*ListReply) ProtoMessage

func (*ListReply) ProtoMessage()

func (*ListReply) ProtoReflect

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

func (*ListReply) Reset

func (x *ListReply) Reset()

func (*ListReply) String

func (x *ListReply) String() string

type ListReply_ReplyType

type ListReply_ReplyType int32
const (
	ListReply_Success ListReply_ReplyType = 0
	ListReply_Fail    ListReply_ReplyType = 1
)

func (ListReply_ReplyType) Descriptor

func (ListReply_ReplyType) Enum

func (ListReply_ReplyType) EnumDescriptor deprecated

func (ListReply_ReplyType) EnumDescriptor() ([]byte, []int)

Deprecated: Use ListReply_ReplyType.Descriptor instead.

func (ListReply_ReplyType) Number

func (ListReply_ReplyType) String

func (x ListReply_ReplyType) String() string

func (ListReply_ReplyType) Type

type ListRequest

type ListRequest struct {
	PostID string `protobuf:"bytes,1,opt,name=postID,proto3" json:"postID,omitempty"`
	// contains filtered or unexported fields
}

func (*ListRequest) Descriptor deprecated

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

Deprecated: Use ListRequest.ProtoReflect.Descriptor instead.

func (*ListRequest) GetPostID

func (x *ListRequest) GetPostID() string

func (*ListRequest) ProtoMessage

func (*ListRequest) ProtoMessage()

func (*ListRequest) ProtoReflect

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

func (*ListRequest) Reset

func (x *ListRequest) Reset()

func (*ListRequest) String

func (x *ListRequest) String() string

type StoreReply

type StoreReply struct {
	Id     string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Status string `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"`
	// contains filtered or unexported fields
}

func (*StoreReply) Descriptor deprecated

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

Deprecated: Use StoreReply.ProtoReflect.Descriptor instead.

func (*StoreReply) GetId

func (x *StoreReply) GetId() string

func (*StoreReply) GetStatus

func (x *StoreReply) GetStatus() string

func (*StoreReply) ProtoMessage

func (*StoreReply) ProtoMessage()

func (*StoreReply) ProtoReflect

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

func (*StoreReply) Reset

func (x *StoreReply) Reset()

func (*StoreReply) String

func (x *StoreReply) String() string

type StoreReply_ReplyType

type StoreReply_ReplyType int32
const (
	StoreReply_Success StoreReply_ReplyType = 0
	StoreReply_Fail    StoreReply_ReplyType = 1
)

func (StoreReply_ReplyType) Descriptor

func (StoreReply_ReplyType) Enum

func (StoreReply_ReplyType) EnumDescriptor deprecated

func (StoreReply_ReplyType) EnumDescriptor() ([]byte, []int)

Deprecated: Use StoreReply_ReplyType.Descriptor instead.

func (StoreReply_ReplyType) Number

func (StoreReply_ReplyType) String

func (x StoreReply_ReplyType) String() string

func (StoreReply_ReplyType) Type

type StoreRequest

type StoreRequest struct {
	PostID string `protobuf:"bytes,1,opt,name=postID,proto3" json:"postID,omitempty"`
	UserID string `protobuf:"bytes,2,opt,name=userID,proto3" json:"userID,omitempty"`
	Title  string `protobuf:"bytes,3,opt,name=title,proto3" json:"title,omitempty"`
	Body   string `protobuf:"bytes,4,opt,name=body,proto3" json:"body,omitempty"`
	// contains filtered or unexported fields
}

func (*StoreRequest) Descriptor deprecated

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

Deprecated: Use StoreRequest.ProtoReflect.Descriptor instead.

func (*StoreRequest) GetBody

func (x *StoreRequest) GetBody() string

func (*StoreRequest) GetPostID

func (x *StoreRequest) GetPostID() string

func (*StoreRequest) GetTitle

func (x *StoreRequest) GetTitle() string

func (*StoreRequest) GetUserID

func (x *StoreRequest) GetUserID() string

func (*StoreRequest) ProtoMessage

func (*StoreRequest) ProtoMessage()

func (*StoreRequest) ProtoReflect

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

func (*StoreRequest) Reset

func (x *StoreRequest) Reset()

func (*StoreRequest) String

func (x *StoreRequest) String() string

type UnimplementedCommentsServer

type UnimplementedCommentsServer struct {
}

UnimplementedCommentsServer can be embedded to have forward compatible implementations.

func (*UnimplementedCommentsServer) List

func (*UnimplementedCommentsServer) Store

func (*UnimplementedCommentsServer) Update

type UpdateReply

type UpdateReply struct {
	Id     string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Status string `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateReply) Descriptor deprecated

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

Deprecated: Use UpdateReply.ProtoReflect.Descriptor instead.

func (*UpdateReply) GetId

func (x *UpdateReply) GetId() string

func (*UpdateReply) GetStatus

func (x *UpdateReply) GetStatus() string

func (*UpdateReply) ProtoMessage

func (*UpdateReply) ProtoMessage()

func (*UpdateReply) ProtoReflect

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

func (*UpdateReply) Reset

func (x *UpdateReply) Reset()

func (*UpdateReply) String

func (x *UpdateReply) String() string

type UpdateReply_ReplyType

type UpdateReply_ReplyType int32
const (
	UpdateReply_Success UpdateReply_ReplyType = 0
	UpdateReply_Fail    UpdateReply_ReplyType = 1
)

func (UpdateReply_ReplyType) Descriptor

func (UpdateReply_ReplyType) Enum

func (UpdateReply_ReplyType) EnumDescriptor deprecated

func (UpdateReply_ReplyType) EnumDescriptor() ([]byte, []int)

Deprecated: Use UpdateReply_ReplyType.Descriptor instead.

func (UpdateReply_ReplyType) Number

func (UpdateReply_ReplyType) String

func (x UpdateReply_ReplyType) String() string

func (UpdateReply_ReplyType) Type

type UpdateRequest

type UpdateRequest struct {
	PostID string `protobuf:"bytes,1,opt,name=postID,proto3" json:"postID,omitempty"`
	UserID string `protobuf:"bytes,2,opt,name=userID,proto3" json:"userID,omitempty"`
	Title  string `protobuf:"bytes,3,opt,name=title,proto3" json:"title,omitempty"`
	Body   string `protobuf:"bytes,4,opt,name=body,proto3" json:"body,omitempty"`
	Id     string `protobuf:"bytes,5,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateRequest) Descriptor deprecated

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

Deprecated: Use UpdateRequest.ProtoReflect.Descriptor instead.

func (*UpdateRequest) GetBody

func (x *UpdateRequest) GetBody() string

func (*UpdateRequest) GetId

func (x *UpdateRequest) GetId() string

func (*UpdateRequest) GetPostID

func (x *UpdateRequest) GetPostID() string

func (*UpdateRequest) GetTitle

func (x *UpdateRequest) GetTitle() string

func (*UpdateRequest) GetUserID

func (x *UpdateRequest) GetUserID() string

func (*UpdateRequest) ProtoMessage

func (*UpdateRequest) ProtoMessage()

func (*UpdateRequest) ProtoReflect

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

func (*UpdateRequest) Reset

func (x *UpdateRequest) Reset()

func (*UpdateRequest) String

func (x *UpdateRequest) String() string

Jump to

Keyboard shortcuts

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