transport

package
v0.2.22 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2019 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClientStreamTransport

type ClientStreamTransport interface {
	Send(ctx context.Context, body io.Reader) error
	Receive(ctx context.Context) (io.ReadCloser, error)

	// CloseSend sends a close signal to the server.
	CloseSend() error

	// Close closes the connection.
	Close() error
}

func NewClientStream

func NewClientStream(host, endpoint string) (ClientStreamTransport, error)

type ConnectOptions

type ConnectOptions struct {
	Insecure bool
	Headers  http.Header
}

type UnaryTransport

type UnaryTransport interface {
	Send(ctx context.Context, endpoint, contentType string, body io.Reader) (io.ReadCloser, error)
	Close() error
}

func NewUnary

func NewUnary(host string, opts *ConnectOptions) UnaryTransport

Jump to

Keyboard shortcuts

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