server

package
v0.9.5 Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2021 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const SupportPackageIsVersion1 = 1

Variables

This section is empty.

Functions

func LocalIp

func LocalIp() (string, error)

Types

type Options

type Options func(*option)

func BuffSize

func BuffSize(buffSize int) Options

func Codec

func Codec(cc codec.Codec) Options

func E

func Error

func Error(err parcel.ErrorPackager) Options

func Exit

func Exit(exit ...func()) Options

func Id

func Id(id string) Options

func Namespace

func Namespace(name string) Options

func Port

func Port(port [2]int) Options

func Registry

func Registry(registry registry.Registry) Options

func Signal

func Signal(signal ...os.Signal) Options

func TCPAddress

func TCPAddress(address string) Options

func Transport

func Transport(transport transport.Server) Options

func Version

func Version(version string) Options

func Wrapper

func Wrapper(wrappers ...parcel.Wrapper) Options

func WssAddress

func WssAddress(address, path string) Options

type RocServer

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

func NewRocServer

func NewRocServer(opts ...Options) *RocServer

func (*RocServer) Close

func (r *RocServer) Close()

func (*RocServer) Codec

func (r *RocServer) Codec() codec.Codec

func (*RocServer) E

func (r *RocServer) E() *endpoint.Endpoint

func (*RocServer) Id

func (r *RocServer) Id() string

func (*RocServer) Name

func (r *RocServer) Name() string

func (*RocServer) Register

func (r *RocServer) Register() registry.Registry

func (*RocServer) RegisterChannelHandler

func (r *RocServer) RegisterChannelHandler(method string, rs parcel.ChannelHandler)

func (*RocServer) RegisterHandler

func (r *RocServer) RegisterHandler(method string, rr parcel.Handler)

func (*RocServer) RegisterStreamHandler

func (r *RocServer) RegisterStreamHandler(method string, rs parcel.StreamHandler)

func (*RocServer) Run

func (r *RocServer) Run() error

func (*RocServer) TCPAddress

func (r *RocServer) TCPAddress() string

func (*RocServer) Transport

func (r *RocServer) Transport() transport.Server

func (*RocServer) Version

func (r *RocServer) Version() string

func (*RocServer) WssAddress

func (r *RocServer) WssAddress() string

func (*RocServer) WssPath

func (r *RocServer) WssPath() string

Jump to

Keyboard shortcuts

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