hi

package
v0.0.0-...-fa9b265 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2017 License: GPL-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package hi is a generated protocol buffer package.

It is generated from these files:

hi.proto

It has these top-level messages:

HiRequest
HiResponse

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterHiServer

func RegisterHiServer(srv HiServer, cfg *config.BaseCfg)

RegisterHiServer register HiServer with etcd info

Types

type HiRequest

type HiRequest struct {
	Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty" xml:"name,omitempty"`
}

HelloRequest 请求结构

func (*HiRequest) Descriptor

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

func (*HiRequest) GetName

func (m *HiRequest) GetName() string

func (*HiRequest) ProtoMessage

func (*HiRequest) ProtoMessage()

func (*HiRequest) Reset

func (m *HiRequest) Reset()

func (*HiRequest) String

func (m *HiRequest) String() string

type HiResponse

type HiResponse struct {
	Message string `protobuf:"bytes,1,opt,name=message" json:"message,omitempty" xml:"message,omitempty"`
}

HelloResponse 响应结构

func SayHi

func SayHi(ctx context.Context, in *HiRequest) (*HiResponse, error)

SayHi 定义SayHello方法

func (*HiResponse) Descriptor

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

func (*HiResponse) GetMessage

func (m *HiResponse) GetMessage() string

func (*HiResponse) ProtoMessage

func (*HiResponse) ProtoMessage()

func (*HiResponse) Reset

func (m *HiResponse) Reset()

func (*HiResponse) String

func (m *HiResponse) String() string

type HiServer

type HiServer interface {
	SayHi(ctx context.Context, in *HiRequest) (*HiResponse, error)
}

HiServer Server API for Hello service

Jump to

Keyboard shortcuts

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