stream

package
v0.0.0-...-65297ff Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2017 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package stream is a generated protocol buffer package.

It is generated from these files:

github.com/micro/examples/stream/server/proto/stream.proto

It has these top-level messages:

Request
Response

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterStreamerHandler

func RegisterStreamerHandler(s server.Server, hdlr StreamerHandler, opts ...server.HandlerOption)

Types

type Request

type Request struct {
	Count int64 `protobuf:"varint,1,opt,name=count" json:"count,omitempty"`
}

func (*Request) Descriptor

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

func (*Request) GetCount

func (m *Request) GetCount() int64

func (*Request) ProtoMessage

func (*Request) ProtoMessage()

func (*Request) Reset

func (m *Request) Reset()

func (*Request) String

func (m *Request) String() string

type Response

type Response struct {
	Count int64 `protobuf:"varint,1,opt,name=count" json:"count,omitempty"`
}

func (*Response) Descriptor

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

func (*Response) GetCount

func (m *Response) GetCount() int64

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) Reset

func (m *Response) Reset()

func (*Response) String

func (m *Response) String() string

type Streamer

type Streamer struct {
	StreamerHandler
}

func (*Streamer) ServerStream

func (h *Streamer) ServerStream(ctx context.Context, stream server.Streamer) error

func (*Streamer) Stream

func (h *Streamer) Stream(ctx context.Context, stream server.Streamer) error

type StreamerClient

type StreamerClient interface {
	Stream(ctx context.Context, opts ...client.CallOption) (Streamer_StreamClient, error)
	ServerStream(ctx context.Context, in *Request, opts ...client.CallOption) (Streamer_ServerStreamClient, error)
}

func NewStreamerClient

func NewStreamerClient(serviceName string, c client.Client) StreamerClient

type StreamerHandler

type StreamerHandler interface {
	Stream(context.Context, Streamer_StreamStream) error
	ServerStream(context.Context, *Request, Streamer_ServerStreamStream) error
}

type Streamer_ServerStreamClient

type Streamer_ServerStreamClient interface {
	SendMsg(interface{}) error
	RecvMsg(interface{}) error
	Close() error
	Recv() (*Response, error)
}

type Streamer_ServerStreamStream

type Streamer_ServerStreamStream interface {
	SendMsg(interface{}) error
	RecvMsg(interface{}) error
	Close() error
	Send(*Response) error
}

type Streamer_StreamClient

type Streamer_StreamClient interface {
	SendMsg(interface{}) error
	RecvMsg(interface{}) error
	Close() error
	Send(*Request) error
	Recv() (*Response, error)
}

type Streamer_StreamStream

type Streamer_StreamStream interface {
	SendMsg(interface{}) error
	RecvMsg(interface{}) error
	Close() error
	Send(*Response) error
	Recv() (*Request, error)
}

Jump to

Keyboard shortcuts

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