hello_pb

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2020 License: BSD-3-Clause Imports: 13 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HelloServiceGrpcHandler added in v1.2.0

func HelloServiceGrpcHandler(
	ctx context.Context, svc HelloServiceGrpcInterface,
	fnAnnotateContext func(ctx context.Context, req *net_http.Request, methodName string) (context.Context, error),
) net_http.Handler

func HelloServiceHandler

func HelloServiceHandler(svc HelloServiceInterface) net_http.Handler

func RegisterHelloService

func RegisterHelloService(srv *net_rpc.Server, x HelloServiceInterface) error

Types

type HelloServiceClient

type HelloServiceClient struct {
	*net_rpc.Client
}

func DialHelloService

func DialHelloService(network, address string) (*HelloServiceClient, error)

func (*HelloServiceClient) AsyncEcho added in v1.1.0

func (p *HelloServiceClient) AsyncEcho(in *Message, out *Message, done chan *net_rpc.Call) *net_rpc.Call

func (*HelloServiceClient) AsyncHello added in v1.1.0

func (p *HelloServiceClient) AsyncHello(in *String, out *String, done chan *net_rpc.Call) *net_rpc.Call

func (*HelloServiceClient) AsyncStatic added in v1.1.0

func (p *HelloServiceClient) AsyncStatic(in *String, out *StaticFile, done chan *net_rpc.Call) *net_rpc.Call

func (*HelloServiceClient) Echo

func (p *HelloServiceClient) Echo(in *Message) (*Message, error)

func (*HelloServiceClient) Hello

func (p *HelloServiceClient) Hello(in *String) (*String, error)

func (*HelloServiceClient) Static

func (p *HelloServiceClient) Static(in *String) (*StaticFile, error)

type HelloServiceGrpcInterface added in v1.2.0

type HelloServiceGrpcInterface interface {
	Hello(ctx context.Context, in *String) (out *String, err error)
	Echo(ctx context.Context, in *Message) (out *Message, err error)
	Static(ctx context.Context, in *String) (out *StaticFile, err error)
}

type HelloServiceHttpClient added in v1.4.0

type HelloServiceHttpClient struct {
	// contains filtered or unexported fields
}

func NewHelloServiceHttpClient added in v1.4.0

func NewHelloServiceHttpClient(baseurl string, c ...*net_http.Client) *HelloServiceHttpClient

func (*HelloServiceHttpClient) Echo added in v1.4.0

func (p *HelloServiceHttpClient) Echo(in *Message, method ...string) (out *Message, err error)

func (*HelloServiceHttpClient) Hello added in v1.4.0

func (p *HelloServiceHttpClient) Hello(in *String, method ...string) (out *String, err error)

func (*HelloServiceHttpClient) Static added in v1.4.0

func (p *HelloServiceHttpClient) Static(in *String, method ...string) (out *StaticFile, err error)

type HelloServiceInterface

type HelloServiceInterface interface {
	Hello(in *String, out *String) error
	Echo(in *Message, out *Message) error
	Static(in *String, out *StaticFile) error
}

type HelloServiceValidator added in v1.1.0

type HelloServiceValidator struct {
	HelloServiceInterface
}

func (*HelloServiceValidator) Echo added in v1.1.0

func (p *HelloServiceValidator) Echo(in *Message, out *Message) error

func (*HelloServiceValidator) Hello added in v1.1.0

func (p *HelloServiceValidator) Hello(in *String, out *String) error

func (*HelloServiceValidator) Static added in v1.1.0

func (p *HelloServiceValidator) Static(in *String, out *StaticFile) error

type Message

type Message struct {
	Value                string            `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
	Array                []int32           `protobuf:"varint,2,rep,packed,name=array,proto3" json:"array,omitempty"`
	Dict                 map[string]string `` /* 149-byte string literal not displayed */
	Subfiled             *String           `protobuf:"bytes,4,opt,name=subfiled,proto3" json:"subfiled,omitempty"`
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*Message) Descriptor

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

func (*Message) GetArray

func (m *Message) GetArray() []int32

func (*Message) GetDict

func (m *Message) GetDict() map[string]string

func (*Message) GetSubfiled

func (m *Message) GetSubfiled() *String

func (*Message) GetValue

func (m *Message) GetValue() string

func (*Message) ProtoMessage

func (*Message) ProtoMessage()

func (*Message) Reset

func (m *Message) Reset()

func (*Message) String

func (m *Message) String() string

func (*Message) XXX_DiscardUnknown

func (m *Message) XXX_DiscardUnknown()

func (*Message) XXX_Marshal

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

func (*Message) XXX_Merge

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

func (*Message) XXX_Size

func (m *Message) XXX_Size() int

func (*Message) XXX_Unmarshal

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

type StaticFile

type StaticFile struct {
	ContentType          string   `protobuf:"bytes,1,opt,name=content_type,json=contentType,proto3" json:"content_type,omitempty"`
	ContentBody          []byte   `protobuf:"bytes,2,opt,name=content_body,json=contentBody,proto3" json:"content_body,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*StaticFile) Descriptor

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

func (*StaticFile) GetContentBody

func (m *StaticFile) GetContentBody() []byte

func (*StaticFile) GetContentType

func (m *StaticFile) GetContentType() string

func (*StaticFile) ProtoMessage

func (*StaticFile) ProtoMessage()

func (*StaticFile) Reset

func (m *StaticFile) Reset()

func (*StaticFile) String

func (m *StaticFile) String() string

func (*StaticFile) XXX_DiscardUnknown

func (m *StaticFile) XXX_DiscardUnknown()

func (*StaticFile) XXX_Marshal

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

func (*StaticFile) XXX_Merge

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

func (*StaticFile) XXX_Size

func (m *StaticFile) XXX_Size() int

func (*StaticFile) XXX_Unmarshal

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

type String

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

func (*String) Descriptor

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

func (*String) GetValue

func (m *String) GetValue() string

func (*String) ProtoMessage

func (*String) ProtoMessage()

func (*String) Reset

func (m *String) Reset()

func (*String) String

func (m *String) String() string

func (*String) XXX_DiscardUnknown

func (m *String) XXX_DiscardUnknown()

func (*String) XXX_Marshal

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

func (*String) XXX_Merge

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

func (*String) XXX_Size

func (m *String) XXX_Size() int

func (*String) XXX_Unmarshal

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

Jump to

Keyboard shortcuts

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